why don't we just read the pref directly from the pref service instead of using this localized unichar preference routine. I don't think this pref is a localized pref.
I haven't looked at the mime part yet, I'll try to get to that soon! thanks for taking a look at this.
Comment on attachment 260269
Updated patch that addresses TT special case
some minor nits:
+ nsXPIDLString font_face;
font_face should be a nsString
This:
+ if(NS_LITERAL_ STRING( "tt").Equals( font_face) )
should be EqualsLiteral( "tt")
font_face.
and does it need to be a case insensitive compare?
Can this:
aText.Append( NS_LITERAL_ STRING( "</TT>" ));
be aText.AppendLit eral(.. .)?
Use a nsString here:
+ nsXPIDLString font_size;
could this be a simple switch statement?
+ if(NS_LITERAL_ STRING( "x-small" ).Equals( font_size) ) Assign( NS_LITERAL_ STRING( "-2")); STRING( "small" ).Equals( font_size) ) Assign( NS_LITERAL_ STRING( "-1")); STRING( "large" ).Equals( font_size) ) Assign( NS_LITERAL_ STRING( "+1")); STRING( "x-large" ).Equals( font_size) ) Assign( NS_LITERAL_ STRING( "+2")); STRING( "xx-large" ).Equals( font_size) ) Assign( NS_LITERAL_ STRING( "+3")); Assign( NS_LITERAL_ STRING( ""));
+ font_size.
+ else if(NS_LITERAL_
+ font_size.
+ else if(NS_LITERAL_
+ font_size.
+ else if(NS_LITERAL_
+ font_size.
+ else if(NS_LITERAL_
+ font_size.
+ else
+ font_size.
if not, the comparison statements should be of the form:
if (font_size. EqualsLiteral( "xx-large" ))
* NS_GetLocalized UnicharPreferen ceWithDefault( prefBranch, "msgcompose. font_size" , NS_LITERAL_ STRING( ""), font_size);
why don't we just read the pref directly from the pref service instead of using this localized unichar preference routine. I don't think this pref is a localized pref.
I haven't looked at the mime part yet, I'll try to get to that soon! thanks for taking a look at this.