[Webkit-unassigned] [Bug 160547] Overflow of formulas is hidden for display mathematics
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Sun Jan 28 09:57:00 PST 2018
https://bugs.webkit.org/show_bug.cgi?id=160547
--- Comment #8 from Minsheng Liu <lambda at liu.ms> ---
(In reply to Frédéric Wang (:fredw) from comment #7)
> Comment on attachment 332481 [details]
> patch
>
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=332481&action=review
>
> > LayoutTests/mathml/presentation/display-math-horizontal-overflow.html:14
> > + assert_equals(inline.clientWidth, block.clientWidth);
>
> I think this test is a bit weak (it assumes inline math already have the
> correct width). I would instead try the 4 combinations between inline/block
> math and 100px/200px mspace content and check that the math has the expected
> width: 100px (for inline/100px), 200px (for block/100px) or 400px (for
> inline/400px and block/400px). You could even test centering inside the
> 200px container in the case block/100px, by checking the position of the
> mspace.
I will do two tests, one for width when overflowed, and one for centering.
>
> > Source/WebCore/ChangeLog:8
> > + Previously, <math> with display="block" uses its preferred width as logical width.
>
> Is that true? I don't remember but I believe it takes the *container* width
> at the end? I think at some point it would be nice to check what RenderBox
> is doing and whether we can better handle MathML (what I had tried with the
> experimental patch). But I guess that would be more complex and I'm not sure
> I can review the RenderBox code.
Oops! I got the concept wrong. I thought preferred width is just the container’s width. So, may I ask what is preferred width and when is used?
>
> > Source/WebCore/rendering/mathml/RenderMathMLRow.cpp:185
> > + if (width > logicalWidth())
>
> I would do
>
> if (width < logicalWidth) {
> // DO THE CENTERING
> } else
> setLogicalWidth(width);
>
> I think we can then just do centerBlockOffset = (logicalWidth() - width) / 2;
>
> We also need to update the comment to explain the two cases.
I think it is complicated that it is worthy having a layoutBlock() in RenderMathMLMath.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20180128/f69332c6/attachment.html>
More information about the webkit-unassigned
mailing list