The WebCore/css/mathml.css stylesheet contains the following comment: /* FIXME: For a RenderMathMLOperator's margin-start and margin-end, or for a MathML "embellished operator", check the operator's lspace and rspace attributes, and the MathML operator dictionary. */ math > mo, mrow > mo, msqrt > mo, mtd > mo { -webkit-margin-start: 0.2em; -webkit-margin-end: 0.2em; } basically, we always add .2em before and after the <mo> element. We should use the default lspace/rspace values given in MathML operator dictionary instead: http://www.w3.org/TR/MathML/appendixc.html#oper-dict.entries-table which are multiple of 1/18em: http://www.w3.org/TR/MathML/appendixc.html#oper-dict.space Also, the we could use the lspace/rspace attribute valus when specified: http://www.w3.org/TR/MathML/chapter3.html#presm.mo.attrs In theory, the spacing should be added to around the whole embellished operators not necessarily to the core mo, but I'm not sure how much Webkit implements about the embellished operator hierarchy.
This should be fixed for mfenced too (bug 118843).
Important: remember to take the tests from attachment 217787 [details] that were not included in the final patch of bug 99620.
Created attachment 224871 [details] Patch The following tests are still failing: mathml/presentation/mo-form-minus-plus.html mathml/presentation/mo-form.html mathml/presentation/mo-lspace-rspace.html
Created attachment 224915 [details] Patch This fixes the remaining test failures and adds new tests to verify dynamic changes.
*** Bug 118843 has been marked as a duplicate of this bug. ***
Created attachment 225995 [details] Patch Refreshing the patch and fixing a style error.
Created attachment 226395 [details] Patch
Comment on attachment 226395 [details] Patch Attachment 226395 [details] did not pass mac-wk2-ews (mac-wk2): Output: http://webkit-queues.appspot.com/results/5620794474364928 New failing tests: mathml/presentation/mo-stretch.html
Created attachment 226398 [details] Archive of layout-test-results from webkit-ews-16 for mac-mountainlion-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: webkit-ews-16 Port: mac-mountainlion-wk2 Platform: Mac OS X 10.8.5
Created attachment 226400 [details] Patch Updating the mac reference of op-stretch.html
Comment on attachment 226400 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=226400&action=review > Source/WebCore/rendering/mathml/RenderMathMLRow.cpp:62 > + auto renderOperator = toRenderMathMLBlock(child)->unembellishedOperator(); this can be inside the if block if (auto renderOperator = toRenderMathMLBlock(child)->unembellishedOperator())
Committed r165461: <http://trac.webkit.org/changeset/165461>