Another simple change extracted from bug 152244. boundsForGlyph, heightForGlyph and advanceForGlyph are really just some convenient wrapper around GlyphData functions and RenderMathMLOperator is not involved. We can just implement them as inline static functions in the C++ source. They will just be moved to MathOperator.cpp in bug 152244. Manuel also suggested renaming advanceForGlyph to advanceWidthForGlyph.
Created attachment 276382 [details] Patch
Created attachment 276383 [details] Patch
Comment on attachment 276383 [details] Patch LGTM. Not a strong opinion regarding the change in computePreferredLogicalWidths() if it should be done now or later, but I'm fine with it.
Comment on attachment 276383 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=276383&action=review > Source/WebCore/ChangeLog:18 > + (WebCore::RenderMathMLOperator::findStretchyData): Renamed to advanceWidthForGlyph. I read the function was renamed in the comment, maybe explain you are replacing the call. > Source/WebCore/rendering/mathml/RenderMathMLOperator.cpp:293 > - float glyphWidth = advanceForGlyph(data); > + float glyphWidth = data.isValid() ? data.font->widthForGlyph(data.glyph) : 0; Should we add it to the API then of the new file because we need to use it?
Created attachment 276388 [details] Patch
Committed r199547: <http://trac.webkit.org/changeset/199547>