Fix was already approved for checkin on the branch, now updating trunk as well. b=56194, r=karnaze a=buster (for RTM bug 40340)

This commit is contained in:
attinasi%netscape.com 2000-10-26 00:34:08 +00:00
Родитель d2df084113
Коммит 99ce6eef2c
5 изменённых файлов: 61 добавлений и 64 удалений

Просмотреть файл

@ -262,27 +262,21 @@ MapFontAttributesInto(const nsIHTMLMappedAttributes* aAttributes,
// find the correct font if we are usingDocumentFonts OR we are overriding for XUL
// MJA: bug 31816
if ((chromeOverride || useDocumentFonts) &&
NS_OK == dc->FirstExistingFont(font->mFont, face)) {
if (face.EqualsIgnoreCase("-moz-fixed")) {
font->mFlags |= NS_STYLE_FONT_USE_FIXED;
} else {
font->mFlags &= ~NS_STYLE_FONT_USE_FIXED;
}
/* bug 12737
else {
nsCompatibility mode;
aPresContext->GetCompatibilityMode(&mode);
if (eCompatibility_NavQuirks == mode) {
font->mFixedFont.name = familyList;
}
}
*/
PRBool fontFaceOK = PR_TRUE;
PRBool isMozFixed = font->mFont.name.EqualsIgnoreCase("-moz-fixed");
if ((chromeOverride || useDocumentFonts)) {
fontFaceOK = (NS_OK == dc->FirstExistingFont(font->mFont, face));
}
else {
if (!fontFaceOK || !(chromeOverride || useDocumentFonts)) {
// now set to defaults
font->mFont.name = defaultFont.name;
font->mFixedFont.name= defaultFixedFont.name;
}
// set to monospace if using moz-fixed
if (isMozFixed) {
font->mFlags |= NS_STYLE_FONT_USE_FIXED;
} else {
font->mFlags &= ~NS_STYLE_FONT_USE_FIXED; }
font->mFlags |= NS_STYLE_FONT_FACE_EXPLICIT;
}
}

Просмотреть файл

@ -1644,18 +1644,21 @@ MapDeclarationFontInto(nsICSSDeclaration* aDeclaration,
// find the correct font if we are usingDocumentFonts OR we are overriding for XUL
// MJA: bug 31816
if ((chromeOverride || useDocumentFonts) &&
(NS_OK == dc->FirstExistingFont(font->mFont, face))) {
if (face.EqualsIgnoreCase("-moz-fixed")) {
font->mFlags |= NS_STYLE_FONT_USE_FIXED;
}
else {
font->mFlags &= ~NS_STYLE_FONT_USE_FIXED;
}
PRBool fontFaceOK = PR_TRUE;
PRBool isMozFixed = font->mFont.name.EqualsIgnoreCase("-moz-fixed");
if ((chromeOverride || useDocumentFonts)) {
fontFaceOK = (NS_OK == dc->FirstExistingFont(font->mFont, face));
}
else {
if (!fontFaceOK || !(chromeOverride || useDocumentFonts)) {
// now set to defaults
font->mFont.name = defaultFont.name;
font->mFixedFont.name = defaultFixedFont.name;
font->mFixedFont.name= defaultFixedFont.name;
}
// set to monospace if using moz-fixed
if (isMozFixed) {
font->mFlags |= NS_STYLE_FONT_USE_FIXED;
} else {
font->mFlags &= ~NS_STYLE_FONT_USE_FIXED;
}
font->mFlags |= NS_STYLE_FONT_FACE_EXPLICIT;
}

Просмотреть файл

@ -262,27 +262,21 @@ MapFontAttributesInto(const nsIHTMLMappedAttributes* aAttributes,
// find the correct font if we are usingDocumentFonts OR we are overriding for XUL
// MJA: bug 31816
if ((chromeOverride || useDocumentFonts) &&
NS_OK == dc->FirstExistingFont(font->mFont, face)) {
if (face.EqualsIgnoreCase("-moz-fixed")) {
font->mFlags |= NS_STYLE_FONT_USE_FIXED;
} else {
font->mFlags &= ~NS_STYLE_FONT_USE_FIXED;
}
/* bug 12737
else {
nsCompatibility mode;
aPresContext->GetCompatibilityMode(&mode);
if (eCompatibility_NavQuirks == mode) {
font->mFixedFont.name = familyList;
}
}
*/
PRBool fontFaceOK = PR_TRUE;
PRBool isMozFixed = font->mFont.name.EqualsIgnoreCase("-moz-fixed");
if ((chromeOverride || useDocumentFonts)) {
fontFaceOK = (NS_OK == dc->FirstExistingFont(font->mFont, face));
}
else {
if (!fontFaceOK || !(chromeOverride || useDocumentFonts)) {
// now set to defaults
font->mFont.name = defaultFont.name;
font->mFixedFont.name= defaultFixedFont.name;
}
// set to monospace if using moz-fixed
if (isMozFixed) {
font->mFlags |= NS_STYLE_FONT_USE_FIXED;
} else {
font->mFlags &= ~NS_STYLE_FONT_USE_FIXED; }
font->mFlags |= NS_STYLE_FONT_FACE_EXPLICIT;
}
}

Просмотреть файл

@ -1644,18 +1644,21 @@ MapDeclarationFontInto(nsICSSDeclaration* aDeclaration,
// find the correct font if we are usingDocumentFonts OR we are overriding for XUL
// MJA: bug 31816
if ((chromeOverride || useDocumentFonts) &&
(NS_OK == dc->FirstExistingFont(font->mFont, face))) {
if (face.EqualsIgnoreCase("-moz-fixed")) {
font->mFlags |= NS_STYLE_FONT_USE_FIXED;
}
else {
font->mFlags &= ~NS_STYLE_FONT_USE_FIXED;
}
PRBool fontFaceOK = PR_TRUE;
PRBool isMozFixed = font->mFont.name.EqualsIgnoreCase("-moz-fixed");
if ((chromeOverride || useDocumentFonts)) {
fontFaceOK = (NS_OK == dc->FirstExistingFont(font->mFont, face));
}
else {
if (!fontFaceOK || !(chromeOverride || useDocumentFonts)) {
// now set to defaults
font->mFont.name = defaultFont.name;
font->mFixedFont.name = defaultFixedFont.name;
font->mFixedFont.name= defaultFixedFont.name;
}
// set to monospace if using moz-fixed
if (isMozFixed) {
font->mFlags |= NS_STYLE_FONT_USE_FIXED;
} else {
font->mFlags &= ~NS_STYLE_FONT_USE_FIXED;
}
font->mFlags |= NS_STYLE_FONT_FACE_EXPLICIT;
}

Просмотреть файл

@ -1644,18 +1644,21 @@ MapDeclarationFontInto(nsICSSDeclaration* aDeclaration,
// find the correct font if we are usingDocumentFonts OR we are overriding for XUL
// MJA: bug 31816
if ((chromeOverride || useDocumentFonts) &&
(NS_OK == dc->FirstExistingFont(font->mFont, face))) {
if (face.EqualsIgnoreCase("-moz-fixed")) {
font->mFlags |= NS_STYLE_FONT_USE_FIXED;
}
else {
font->mFlags &= ~NS_STYLE_FONT_USE_FIXED;
}
PRBool fontFaceOK = PR_TRUE;
PRBool isMozFixed = font->mFont.name.EqualsIgnoreCase("-moz-fixed");
if ((chromeOverride || useDocumentFonts)) {
fontFaceOK = (NS_OK == dc->FirstExistingFont(font->mFont, face));
}
else {
if (!fontFaceOK || !(chromeOverride || useDocumentFonts)) {
// now set to defaults
font->mFont.name = defaultFont.name;
font->mFixedFont.name = defaultFixedFont.name;
font->mFixedFont.name= defaultFixedFont.name;
}
// set to monospace if using moz-fixed
if (isMozFixed) {
font->mFlags |= NS_STYLE_FONT_USE_FIXED;
} else {
font->mFlags &= ~NS_STYLE_FONT_USE_FIXED;
}
font->mFlags |= NS_STYLE_FONT_FACE_EXPLICIT;
}