[Webkit-unassigned] [Bug 99618] [MathML] Implement the mmultiscripts tag

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Jul 7 00:58:40 PDT 2013


https://bugs.webkit.org/show_bug.cgi?id=99618





--- Comment #3 from Frédéric Wang <fred.wang at free.fr>  2013-07-07 01:00:40 PST ---
This is typically the example where the flexboxes+anonymous boxes+padding approach is very inconvenient.

In Gecko, the DOM structure is generally exactly the same as the rendering tree structure (so Javascript and CSS apply normally). When one layouts a MathML frame, the layout is first called on its children (so you get their sizes) and then the child coordinates inside the MathML frame are computed. So here, that's just positioning frames from left to right by browsing the list of prescript pairs, then the base and finally the postscript pairs. With WebKit's current approach, one should for example do (there are other possibilities):

- create an anonymous boxes for the prescripts and postscripts that are horizontally oriented flexbox. You get something like [PRE] BASE [POST]

- for each script pairs in [PRE], create a vertically oriented anonymous flexbox where you put the subscript/sup. Same for [POST].

- tweak the padding of boxes so that the scripts are positioned correctly (ideally, according to TeX heuristics or supscriptshift/subscriptshift)

- each time the child list is changed (e.g. children removed/added via Javascript) you have to remove/add the child at the right place and ensure that the rendering tree structure with all these anonymous boxes is preserved

- when some CSS style is applied to the children, you must propagate it to the correct anonymous boxes.

Without necessarily a complete rewrite as suggested elsewhere, at least having something like in Gecko would be much better.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the webkit-unassigned mailing list