WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
40986
Change to Vertical Alignment of MathML Constructs to Use the Baseline
https://bugs.webkit.org/show_bug.cgi?id=40986
Summary
Change to Vertical Alignment of MathML Constructs to Use the Baseline
Alex Milowski
Reported
2010-06-22 08:31:12 PDT
Created
attachment 59371
[details]
Patch to change to baseline alignment. This patch changes the way all MathML elements are rendered so the align against a calculated baseline. This fixes a number of layout bugs and cleans up the implementation. The patch is large because all the tests had to have their results reset. The actual code changes are relatively small.
Attachments
Patch to change to baseline alignment.
(856.93 KB, patch)
2010-06-22 08:31 PDT
,
Alex Milowski
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Kenneth Rohde Christiansen
Comment 1
2010-06-22 14:58:11 PDT
Comment on
attachment 59371
[details]
Patch to change to baseline alignment. LGTM. 165 int heightDiff = (m_scripts->offsetHeight() - maxHeight) / 2; 166 if (heightDiff < 0) 167 heightDiff = 0; maybe add a comment to when this can happen?
Kenneth Rohde Christiansen
Comment 2
2010-06-22 14:59:39 PDT
Comment on
attachment 59371
[details]
Patch to change to baseline alignment. LGTM. 165 int heightDiff = (m_scripts->offsetHeight() - maxHeight) / 2; 166 if (heightDiff < 0) 167 heightDiff = 0; maybe add a comment to when this can happen? WebCore/mathml/RenderMathMLUnderOver.cpp:255 + baseline += static_cast<int>((zoomFactor > 1.25 ? 2 : 3) * zoomFactor); ieck :-) good that you added a FIXME at least.
Alex Milowski
Comment 3
2010-06-23 02:42:10 PDT
(In reply to
comment #1
)
> (From update of
attachment 59371
[details]
) > LGTM. > > 165 int heightDiff = (m_scripts->offsetHeight() - maxHeight) / 2; > 166 if (heightDiff < 0) > 167 heightDiff = 0; > > maybe add a comment to when this can happen?
Only if the base is bigger than the scripts. That shouldn't happen unless you are in the process of row height calculation. I should add a comment to that effect.
Alex Milowski
Comment 4
2010-06-23 02:43:10 PDT
(In reply to
comment #2
)
> (From update of
attachment 59371
[details]
) > LGTM. > > 165 int heightDiff = (m_scripts->offsetHeight() - maxHeight) / 2; > 166 if (heightDiff < 0) > 167 heightDiff = 0; > > maybe add a comment to when this can happen? > > WebCore/mathml/RenderMathMLUnderOver.cpp:255 > + baseline += static_cast<int>((zoomFactor > 1.25 ? 2 : 3) * zoomFactor); > ieck :-) good that you added a FIXME at least.
There is some padding or margin that is expanding and I can't quite figure it out. Very icky indeed.
WebKit Commit Bot
Comment 5
2010-06-25 06:55:56 PDT
Comment on
attachment 59371
[details]
Patch to change to baseline alignment. Clearing flags on attachment: 59371 Committed
r61861
: <
http://trac.webkit.org/changeset/61861
>
WebKit Commit Bot
Comment 6
2010-06-25 06:56:01 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug