[Webkit-unassigned] [Bug 160547] Overflow of formulas is hidden for display mathematics
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Thu Aug 4 08:11:42 PDT 2016
https://bugs.webkit.org/show_bug.cgi?id=160547
--- Comment #2 from FrÃ©dÃ©ric Wang (:fredw) <fred.wang at free.fr> ---
Created attachment 285326
--> https://bugs.webkit.org/attachment.cgi?id=285326&action=review
Experimental Patch
Some first thoughts: In general, because the preferred width of operators is overestimated (see https://bug-130326-attachments.webkit.org/attachment.cgi?id=283599). Hence all the MathML layoutBlock functions must set the correct logical width rather than relying on the preferred width. Then the RenderBox code use this logical width rather than filling the all available width.
There is an exception for <math display="block">: this must be rendered as a formula centered in the available space. Hence RenderMathMLRow::layoutBlock does not set the its logicalWidth to the width of the math content so that the centering done is this function is correct (http://tests.mathml-association.org/mathml/relations/html5-tree/display-1.html). I guess something in RenderBox also make it also occupy the whole available width. But when the available width is less than the width of the math content, the <math> tag is too narrow.
I'm attaching a hack that just injects the preferredLogicalWidth to force a minimal width but the ideal would be for RenderMathMLRow to expose the width of the math content and let RenderBox calculate the logical width by taking the maximum of the available width and of the width of the math content. Maybe rego or jfernandez have suggestions about how to do that.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20160804/897d23e4/attachment.html>
More information about the webkit-unassigned
mailing list