# HG changeset patch # User Frédéric Wang # Date 1252436633 -7200 # Node ID 399e21c119b4a43c6c8be71e83ee9710d59a044c # Parent d4cc018f1924294aeacc8c0b9fd620b4c843dad2 le patch scale_stretchy.diff a été importé diff --git a/layout/mathml/mathfont.properties b/layout/mathml/mathfont.properties --- a/layout/mathml/mathfont.properties +++ b/layout/mathml/mathfont.properties @@ -335,55 +335,55 @@ operator.\u227F.infix = lspace:5 rspace: operator.\u2AB4.infix = lspace:5 rspace:5 # ⪴ operator.\u2AB8.infix = lspace:5 rspace:5 # ⪸ operator.\u223C.infix = lspace:5 rspace:5 # ∼ operator.\u2243.infix = lspace:5 rspace:5 # ≃ operator.\u2245.infix = lspace:5 rspace:5 # ≅ operator.\u2248.infix = lspace:5 rspace:5 # ≈ operator.\u22A5.infix = lspace:5 rspace:5 # ⊥ operator.\u2223.infix = direction:vertical stretchy lspace:5 rspace:5 # ∣ -operator.\u2294.infix = direction:vertical stretchy lspace:4 rspace:4 # ⊔ +operator.\u2294.infix = direction:vertical largeop lspace:4 rspace:4 # ⊔ operator.\u22C3.infix = direction:vertical stretchy lspace:4 rspace:4 # ⋃ operator.\u228E.infix = direction:vertical stretchy lspace:4 rspace:4 # ⊎ operator.\u002D.infix = lspace:4 rspace:4 # - operator.\u002B.infix = lspace:4 rspace:4 # + operator.\u22C2.infix = direction:vertical stretchy lspace:4 rspace:4 # ⋂ operator.\u2213.infix = lspace:4 rspace:4 # ∓ operator.\u00B1.infix = lspace:4 rspace:4 # ± operator.\u2293.infix = direction:vertical stretchy lspace:4 rspace:4 # ⊓ -operator.\u22C1.prefix = direction:vertical stretchy largeop symmetric movablelimits lspace:0 rspace:3 # ⋁ +operator.\u22C1.prefix = direction:vertical largeop symmetric movablelimits lspace:0 rspace:3 # ⋁ operator.\u2296.prefix = largeop movablelimits symmetric lspace:0 rspace:3 # ⊖ operator.\u2295.prefix = largeop movablelimits symmetric lspace:0 rspace:3 # ⊕ operator.\u2A01.prefix = largeop movablelimits symmetric lspace:0 rspace:3 # ⨁ -operator.\u2211.prefix = direction:vertical stretchy largeop movablelimits symmetric lspace:0 rspace:3 # ∑ -operator.\u22C3.prefix = direction:vertical stretchy largeop movablelimits symmetric lspace:0 rspace:3 # ⋃ -operator.\u228E.prefix = direction:vertical stretchy largeop movablelimits symmetric lspace:0 rspace:3 # ⊎ -operator.\u2A04.prefix = direction:vertical stretchy largeop movablelimits symmetric lspace:0 rspace:3 # ⨄ -operator.\u2A06.prefix = direction:vertical stretchy largeop movablelimits symmetric lspace:0 rspace:3 # ⨆ +operator.\u2211.prefix = direction:vertical largeop movablelimits symmetric lspace:0 rspace:3 # ∑ +operator.\u22C3.prefix = direction:vertical largeop movablelimits symmetric lspace:0 rspace:3 # ⋃ +operator.\u228E.prefix = direction:vertical largeop movablelimits symmetric lspace:0 rspace:3 # ⊎ +operator.\u2A04.prefix = direction:vertical largeop movablelimits symmetric lspace:0 rspace:3 # ⨄ +operator.\u2A06.prefix = direction:vertical largeop movablelimits symmetric lspace:0 rspace:3 # ⨆ operator.\u006C\u0069\u006D.prefix = movablelimits lspace:0 rspace:3 # lim operator.\u006D\u0061\u0078.prefix = movablelimits lspace:0 rspace:3 # max operator.\u006D\u0069\u006E.prefix = movablelimits lspace:0 rspace:3 # min operator.\u2212.infix = lspace:4 rspace:4 # official Unicode minus sign operator.\u2212.prefix = lspace:0 rspace:1 # official Unicode minus sign operator.\u2296.infix = lspace:3 rspace:3 # ⊖ operator.\u2295.infix = lspace:3 rspace:3 # ⊕ -operator.\u2232.prefix = direction:vertical stretchy largeop symmetric lspace:0 rspace:0 # ∲ -operator.\u222E.prefix = direction:vertical stretchy largeop symmetric lspace:0 rspace:0 # ∮ -operator.\u2233.prefix = direction:vertical stretchy largeop symmetric lspace:0 rspace:0 # ∳ -operator.\u222F.prefix = direction:vertical stretchy largeop symmetric lspace:0 rspace:0 # ∯ -operator.\u222B.prefix = direction:vertical stretchy largeop symmetric lspace:0 rspace:0 # ∫ +operator.\u2232.prefix = direction:vertical largeop symmetric lspace:0 rspace:0 # ∲ +operator.\u222E.prefix = direction:vertical largeop symmetric lspace:0 rspace:0 # ∮ +operator.\u2233.prefix = direction:vertical largeop symmetric lspace:0 rspace:0 # ∳ +operator.\u222F.prefix = direction:vertical largeop symmetric lspace:0 rspace:0 # ∯ +operator.\u222B.prefix = direction:vertical largeop symmetric lspace:0 rspace:0 # ∫ operator.\u22D3.infix = lspace:3 rspace:3 # ⋓ operator.\u22D2.infix = lspace:3 rspace:3 # ⋒ operator.\u2240.infix = lspace:3 rspace:3 # ≀ -operator.\u22C0.prefix = direction:vertical stretchy largeop movablelimits symmetric lspace:0 rspace:3 # ⋀ +operator.\u22C0.prefix = direction:vertical largeop movablelimits symmetric lspace:0 rspace:3 # ⋀ operator.\u2297.prefix = largeop movablelimits symmetric lspace:0 rspace:3 # ⊗ operator.\u2A02.prefix = largeop movablelimits symmetric lspace:0 rspace:3 # ⨂ -operator.\u2210.prefix = direction:vertical stretchy largeop movablelimits symmetric lspace:0 rspace:3 # ∐ -operator.\u220F.prefix = direction:vertical stretchy largeop movablelimits symmetric lspace:0 rspace:3 # ∏ -operator.\u22C2.prefix = direction:vertical stretchy largeop movablelimits symmetric lspace:0 rspace:3 # ⋂ +operator.\u2210.prefix = direction:vertical largeop movablelimits symmetric lspace:0 rspace:3 # ∐ +operator.\u220F.prefix = direction:vertical largeop movablelimits symmetric lspace:0 rspace:3 # ∏ +operator.\u22C2.prefix = direction:vertical largeop movablelimits symmetric lspace:0 rspace:3 # ⋂ operator.\u2210.infix = lspace:3 rspace:3 # ∐ operator.\u2606.infix = lspace:3 rspace:3 # ☆ operator.\u22C6.infix = lspace:3 rspace:3 # ⋆ operator.\u2299.prefix = largeop movablelimits symmetric lspace:0 rspace:3 # ⊙ operator.\u2A00.prefix = largeop movablelimits symmetric lspace:0 rspace:3 # ⨀ operator.\u002A.infix = lspace:3 rspace:3 # * operator.\u2062.infix = lspace:0 rspace:0 # ⁢ operator.\u00B7.infix = lspace:3 rspace:3 # · diff --git a/layout/mathml/nsMathMLChar.cpp b/layout/mathml/nsMathMLChar.cpp --- a/layout/mathml/nsMathMLChar.cpp +++ b/layout/mathml/nsMathMLChar.cpp @@ -882,23 +882,16 @@ nsMathMLChar::SetData(nsPresContext* aPr mGlyphTable = nsnull; // check if stretching is applicable ... if (gGlyphTableList && (1 == mData.Length())) { mOperator = nsMathMLOperators::FindOperator(mData[0]); if (mOperator) { mDirection = mOperator->GetStretchDirection(); // default tentative table (not the one that is necessarily going to be used) mGlyphTable = gGlyphTableList->GetGlyphTableFor(aPresContext, this); - // commom case: we won't bother with the stretching if there is - // no glyph table for us... - if (!mGlyphTable) { // TODO: consider scaling the base char - // never try to stretch this operator again - mDirection = NS_STRETCH_DIRECTION_UNSUPPORTED; - mOperator = nsnull; - } } } } // ----------------------------------------------------------------------------------- /* The Stretch: @param aContainerSize - suggested size for the stretched char @@ -971,23 +964,24 @@ nsMathMLChar::SetData(nsPresContext* aPr 4) If a match was not found in that glyph table, repeat from 2 to search the ordered list of stretchy fonts for the first font with a glyph table that provides a fit to the container size. If no fit is found, the closest fit is used. Of note: When the pipeline completes successfully, the desired size of the - stretched char can actually be slighthly larger or smaller than + stretched char can actually be slightly larger or smaller than aContainerSize. But it is the responsibility of the caller to account for the spacing when setting aContainerSize, and to leave any extra margin when placing the stretched char. */ // ----------------------------------------------------------------------------------- +#define NS_MATHML_LARGEOP_FACTOR 2 // plain TeX settings (TeXbook p.152) #define NS_MATHML_DELIMITER_FACTOR 0.901f #define NS_MATHML_DELIMITER_SHORTFALL_POINTS 5.0f static PRBool IsSizeOK(nsPresContext* aPresContext, nscoord a, nscoord b, PRUint32 aHint) { @@ -1589,40 +1583,42 @@ nsMathMLChar::StretchInternal(nsPresCont NS_WARNING("GetBoundingMetrics failed"); return rv; } //////////////////////////////////////////////////////////////////////////////////// // 1. Check the common situations where stretching is not actually needed //////////////////////////////////////////////////////////////////////////////////// - // quick return if there is nothing special about this char - if (!mGlyphTable || - (aStretchDirection != direction && - aStretchDirection != NS_STRETCH_DIRECTION_DEFAULT) || - (aStretchHint & ~NS_STRETCH_MAXWIDTH) == NS_STRETCH_NONE) { - return NS_OK; - } - - // if no specified direction, attempt to stretch in our preferred direction - if (aStretchDirection == NS_STRETCH_DIRECTION_DEFAULT) { - aStretchDirection = direction; - } - // see if this is a particular largeop or largeopOnly request PRBool largeop = (NS_STRETCH_LARGEOP & aStretchHint) != 0; PRBool stretchy = (NS_STRETCH_VARIABLE_MASK & aStretchHint) != 0; PRBool largeopOnly = largeop && !stretchy; PRBool isVertical = (direction == NS_STRETCH_DIRECTION_VERTICAL); nscoord targetSize = isVertical ? aContainerSize.ascent + aContainerSize.descent : aContainerSize.rightBearing - aContainerSize.leftBearing; + mScaleY = mScaleX = 1.0; + mTrueAscent = aDesiredStretchSize.ascent; + + // quick return if there is nothing special about this char + if ((aStretchDirection != direction && + aStretchDirection != NS_STRETCH_DIRECTION_DEFAULT) || + (aStretchHint & ~NS_STRETCH_MAXWIDTH) == NS_STRETCH_NONE) { + return NS_OK; + } + + // if no specified direction, attempt to stretch in our preferred direction + if (aStretchDirection == NS_STRETCH_DIRECTION_DEFAULT) { + aStretchDirection = direction; + } + if (maxWidth) { // See if it is only necessary to consider glyphs up to some maximum size. // Set the current height to the maximum size, and set aStretchHint to // NS_STRETCH_SMALLER if the size is variable, so that only smaller sizes // are considered. targetSize from GetMaxWidth() is 0. if (stretchy) { // variable size stretch - consider all sizes < maxsize aStretchHint = @@ -1651,42 +1647,52 @@ nsMathMLChar::StretchInternal(nsPresCont aDesiredStretchSize.ascent = NSToCoordRound(scale * aDesiredStretchSize.ascent); aDesiredStretchSize.descent = NSToCoordRound(scale * aDesiredStretchSize.descent); } } } - if (!maxWidth && !largeop) { + nsBoundingMetrics initialSize = aDesiredStretchSize; + nscoord charSize = + isVertical ? initialSize.ascent + initialSize.descent + : initialSize.rightBearing - initialSize.leftBearing; + + if (largeop && (targetSize < NS_MATHML_LARGEOP_FACTOR * charSize)) { + targetSize = NS_MATHML_LARGEOP_FACTOR * charSize; + } + + PRBool done = (mGlyphTable ? PR_FALSE : PR_TRUE); + + if (!done && !maxWidth && !largeop) { // Doing Stretch() not GetMaxWidth(), - // and not a largeop in display mode; return if size fits - nscoord charSize = - isVertical ? aDesiredStretchSize.ascent + aDesiredStretchSize.descent - : aDesiredStretchSize.rightBearing - aDesiredStretchSize.leftBearing; - + // and not a largeop in display mode; we're done if size fits if ((targetSize <= 0) || ((isVertical && charSize >= targetSize) || - IsSizeOK(aPresContext, charSize, targetSize, aStretchHint))) - return NS_OK; + IsSizeOK(aPresContext, charSize, targetSize, aStretchHint))) { + mTrueAscent = aDesiredStretchSize.ascent; + done = PR_TRUE; + } } //////////////////////////////////////////////////////////////////////////////////// // 2/3. Search for a glyph or set of part glyphs of appropriate size //////////////////////////////////////////////////////////////////////////////////// - font = mStyleContext->GetStyleFont()->mFont; nsAutoString cssFamilies; - cssFamilies = font.name; - PRBool done = PR_FALSE; + if (!done) { + font = mStyleContext->GetStyleFont()->mFont; + cssFamilies = font.name; + } // See if there are preferred fonts for the variants of this char - if (GetFontExtensionPref(prefBranch, mData[0], eExtension_variants, - families)) { + if (!done && GetFontExtensionPref(prefBranch, mData[0], eExtension_variants, + families)) { font.name = families; StretchEnumContext enumData(this, aPresContext, aRenderingContext, aStretchDirection, targetSize, aStretchHint, aDesiredStretchSize, font.name); enumData.mTryParts = PR_FALSE; done = !font.EnumerateFamilies(StretchEnumContext::EnumCallback, &enumData); @@ -1722,16 +1728,70 @@ nsMathMLChar::StretchInternal(nsPresCont StretchEnumContext enumData(this, aPresContext, aRenderingContext, aStretchDirection, targetSize, aStretchHint, aDesiredStretchSize, font.name); enumData.mTryParts = !largeopOnly; font.EnumerateFamilies(StretchEnumContext::EnumCallback, &enumData); } + // Update scaling parameter and bounding metrics + mTrueAscent = aDesiredStretchSize.ascent; + + if (largeop) { + float scale; + if ((aDesiredStretchSize.ascent + aDesiredStretchSize.descent) < + NS_MATHML_LARGEOP_FACTOR * + (initialSize.ascent + initialSize.descent)) { + scale = float(NS_MATHML_LARGEOP_FACTOR * + (initialSize.ascent + initialSize.descent)) / + (aDesiredStretchSize.ascent + aDesiredStretchSize.descent); + mScaleY *= scale; + aDesiredStretchSize.ascent *= scale; + aDesiredStretchSize.descent *= scale; + } + + if ((aDesiredStretchSize.rightBearing - aDesiredStretchSize.leftBearing) < + NS_MATHML_LARGEOP_FACTOR * + (initialSize.rightBearing - initialSize.leftBearing)) { + scale = float(NS_MATHML_LARGEOP_FACTOR * + (initialSize.rightBearing - initialSize.leftBearing)) / + (aDesiredStretchSize.rightBearing - aDesiredStretchSize.leftBearing); + mScaleX *= scale; + aDesiredStretchSize.leftBearing *= scale; + aDesiredStretchSize.rightBearing *= scale; + aDesiredStretchSize.width *= scale; + } + } + + if (stretchy) { + if (isVertical) { + float scale = + float(aContainerSize.ascent + aContainerSize.descent) / + (aDesiredStretchSize.ascent + aDesiredStretchSize.descent); + + if (!largeop || scale > 1.0) { + mScaleY *= scale; + aDesiredStretchSize.ascent = aContainerSize.ascent; + aDesiredStretchSize.descent = aContainerSize.descent; + } + } else { + float scale = + float(aContainerSize.rightBearing - aContainerSize.leftBearing) / + (aDesiredStretchSize.rightBearing - aDesiredStretchSize.leftBearing); + + if (!largeop || scale > 1.0) { + mScaleX *= scale; + aDesiredStretchSize.leftBearing *= scale; + aDesiredStretchSize.rightBearing *= scale; + aDesiredStretchSize.width *= scale; + } + } + } + return NS_OK; } nsresult nsMathMLChar::Stretch(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsStretchDirection aStretchDirection, const nsBoundingMetrics& aContainerSize, @@ -2059,16 +2119,38 @@ nsMathMLChar::Display(nsDisplayListBuild #endif } return aLists.Content()->AppendNewToTop(new (aBuilder) nsDisplayMathMLCharForeground(aForFrame, this, aSelectedRect && !aSelectedRect->IsEmpty())); } void +nsMathMLChar::ApplyTransforms(nsIRenderingContext& aRenderingContext, nsRect &r) +{ + nscoord dx = r.width / 2; + nscoord dy = r.height / 2; + + // move the origin to the center of the rectangle + aRenderingContext.Translate(r.x + dx, r.y + dy); + + // scale char + aRenderingContext.Scale(mScaleX, mScaleY); + dx /= mScaleX; dy /= mScaleY; + + // move to the top left corner of the rectangle + aRenderingContext.Translate(-dx, -dy); + + // update the bounding rectangle + r.x = r.y = 0; + r.width = 2 * dx; + r.height = 2 * dy; +} + +void nsMathMLChar::PaintForeground(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsPoint aPt, PRBool aIsSelected) { nsStyleContext* parentContext = mStyleContext->GetParent(); nsStyleContext* styleContext = mStyleContext; @@ -2094,47 +2176,60 @@ nsMathMLChar::PaintForeground(nsPresCont aRenderingContext.SetFont(theFont, nsnull, aPresContext->GetUserFontSet()); if (NS_STRETCH_DIRECTION_UNSUPPORTED == mDirection) { // normal drawing if there is nothing special about this char ... // Grab some metrics to adjust the placements ... PRUint32 len = PRUint32(mData.Length()); //printf("Painting %04X like a normal char\n", mData[0]); //aRenderingContext.SetColor(NS_RGB(255,0,0)); - aRenderingContext.DrawString(mData.get(), len, mRect.x + aPt.x, - mRect.y + aPt.y + mBoundingMetrics.ascent); + aRenderingContext.PushState(); + nsRect r = mRect + aPt; + ApplyTransforms(aRenderingContext, r); + aRenderingContext.DrawString(mData.get(), len, 0, mTrueAscent); + aRenderingContext.PopState(); } else { // Grab some metrics to adjust the placements ... // if there is a glyph of appropriate size, paint that glyph if (mGlyph.Exists()) { //printf("Painting %04X with a glyph of appropriate size\n", mData[0]); //aRenderingContext.SetColor(NS_RGB(0,0,255)); - aRenderingContext.DrawString(&mGlyph.code, 1, mRect.x + aPt.x, - mRect.y + aPt.y + mBoundingMetrics.ascent); + aRenderingContext.PushState(); + nsRect r = mRect + aPt; + ApplyTransforms(aRenderingContext, r); + aRenderingContext.DrawString(&mGlyph.code, 1, 0, mTrueAscent); + aRenderingContext.PopState(); } else { // paint by parts // see if this is a composite char and let children paint themselves if (!mParent && mSibling) { // only a "root" having child chars can enter here + aRenderingContext.PushState(); + nsRect r(aPt.x, aPt.y, mRect.width, mRect.height); + ApplyTransforms(aRenderingContext, r); for (nsMathMLChar* child = mSibling; child; child = child->mSibling) { //if (!mStyleContext->Equals(child->mStyleContext)) // printf("char contexts are out of sync\n"); child->PaintForeground(aPresContext, aRenderingContext, aPt, aIsSelected); } + aRenderingContext.PopState(); return; // that's all folks - } + } //aRenderingContext.SetColor(NS_RGB(0,255,0)); + aRenderingContext.PushState(); nsRect r = mRect + aPt; + ApplyTransforms(aRenderingContext, r); if (NS_STRETCH_DIRECTION_VERTICAL == mDirection) PaintVertically(aPresContext, aRenderingContext, theFont, styleContext, mGlyphTable, r); else if (NS_STRETCH_DIRECTION_HORIZONTAL == mDirection) PaintHorizontally(aPresContext, aRenderingContext, theFont, styleContext, mGlyphTable, r); + aRenderingContext.PopState(); } } } /* ================================================================================= And now the helper routines that actually do the job of painting the char by parts */ diff --git a/layout/mathml/nsMathMLChar.h b/layout/mathml/nsMathMLChar.h --- a/layout/mathml/nsMathMLChar.h +++ b/layout/mathml/nsMathMLChar.h @@ -100,16 +100,18 @@ class nsMathMLChar { public: // constructor and destructor nsMathMLChar(nsMathMLChar* aParent = nsnull) { MOZ_COUNT_CTOR(nsMathMLChar); mStyleContext = nsnull; mSibling = nsnull; mParent = aParent; + mTrueAscent = 0; + mScaleX = mScaleY = 1.0; } ~nsMathMLChar() { // not a virtual destructor: this class is not intended to be subclassed MOZ_COUNT_DTOR(nsMathMLChar); // there is only one style context owned by the "root" char // and it may be used by child chars as well if (!mParent && mStyleContext) { // only the "root" need to release it mStyleContext->Release(); @@ -242,16 +244,20 @@ private: nsBoundingMetrics mBoundingMetrics; nsStyleContext* mStyleContext; nsGlyphTable* mGlyphTable; nsGlyphCode mGlyph; // mFamily is non-empty when the family for the current size is different // from the family in the nsStyleContext. nsString mFamily; + // These variables are used to draw a scaled char + float mScaleX, mScaleY; + nscoord mTrueAscent; + class StretchEnumContext; friend class StretchEnumContext; // helper methods nsresult StretchInternal(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsStretchDirection& aStretchDirection, @@ -279,11 +285,14 @@ private: nsresult PaintHorizontally(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsFont& aFont, nsStyleContext* aStyleContext, nsGlyphTable* aGlyphTable, nsRect& aRect); + + void + ApplyTransforms(nsIRenderingContext& aRenderingContext, nsRect &r); }; #endif /* nsMathMLChar_h___ */ diff --git a/layout/mathml/nsMathMLmoFrame.cpp b/layout/mathml/nsMathMLmoFrame.cpp --- a/layout/mathml/nsMathMLmoFrame.cpp +++ b/layout/mathml/nsMathMLmoFrame.cpp @@ -473,34 +473,36 @@ nsMathMLmoFrame::ProcessOperatorData() // XXX If an attribute can be forced to be true when it is false in the // dictionary, then the following code has to change... // For each attribute overriden by the user, turn off its bit flag. // symmetric|movablelimits|separator|largeop|accent|fence|stretchy|form // special: accent and movablelimits are handled above, // don't process them here - if (NS_MATHML_OPERATOR_IS_STRETCHY(mFlags)) { - GetAttribute(mContent, mPresentationData.mstyle, - nsGkAtoms::stretchy_, value); - if (value.EqualsLiteral("false")) - mFlags &= ~NS_MATHML_OPERATOR_STRETCHY; - } + GetAttribute(mContent, mPresentationData.mstyle, + nsGkAtoms::stretchy_, value); + if (value.EqualsLiteral("false")) + mFlags &= ~NS_MATHML_OPERATOR_STRETCHY; + else if (value.EqualsLiteral("true")) + mFlags |= NS_MATHML_OPERATOR_STRETCHY; + + GetAttribute(mContent, mPresentationData.mstyle, + nsGkAtoms::largeop_, value); + if (value.EqualsLiteral("false")) + mFlags &= ~NS_MATHML_OPERATOR_LARGEOP; + else if (value.EqualsLiteral("true")) + mFlags |= NS_MATHML_OPERATOR_LARGEOP; + if (NS_MATHML_OPERATOR_IS_FENCE(mFlags)) { GetAttribute(mContent, mPresentationData.mstyle, nsGkAtoms::fence_, value); if (value.EqualsLiteral("false")) mFlags &= ~NS_MATHML_OPERATOR_FENCE; } - if (NS_MATHML_OPERATOR_IS_LARGEOP(mFlags)) { - GetAttribute(mContent, mPresentationData.mstyle, - nsGkAtoms::largeop_, value); - if (value.EqualsLiteral("false")) - mFlags &= ~NS_MATHML_OPERATOR_LARGEOP; - } if (NS_MATHML_OPERATOR_IS_SEPARATOR(mFlags)) { GetAttribute(mContent, mPresentationData.mstyle, nsGkAtoms::separator_, value); if (value.EqualsLiteral("false")) mFlags &= ~NS_MATHML_OPERATOR_SEPARATOR; } GetAttribute(mContent, mPresentationData.mstyle, nsGkAtoms::symmetric_, value);