Last Comment Bug 454085 - MathML does not render properly with text-align:indent
: MathML does not render properly with text-align:indent
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: MathML (show other bugs)
: Trunk
: All All
: -- normal (vote)
: mozilla1.9.1b1
Assigned To: Frédéric Wang (:fredw)
:
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2008-09-07 10:58 PDT by Frédéric Wang (:fredw)
Modified: 2008-09-16 05:53 PDT (History)
2 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
testcase (3.10 KB, application/xml)
2008-09-07 10:59 PDT, Frédéric Wang (:fredw)
no flags Details
Add a text-indent:0 in mtable to prevent unexpected spaces. [Checkin: Comment 12] (595 bytes, patch)
2008-09-08 06:18 PDT, Frédéric Wang (:fredw)
roc: review+
roc: superreview+
Details | Diff | Splinter Review
Bug when <math> is in an SVG foreignObject (5.02 KB, application/xml)
2008-09-09 03:21 PDT, Frédéric Wang (:fredw)
no flags Details
Add a text-indent:0 to prevent the shift [Checkin: Comment 12] (326 bytes, patch)
2008-09-09 06:53 PDT, Frédéric Wang (:fredw)
roc: review+
roc: superreview+
Details | Diff | Splinter Review

Description Frédéric Wang (:fredw) 2008-09-07 10:58:23 PDT
User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.1) Gecko/2008071618 Iceweasel/3.0.1 (Debian-3.0.1-1)
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.1) Gecko/2008071618 Iceweasel/3.0.1 (Debian-3.0.1-1)

Unexpected spaces appear in formulae when one uses text-align:indent

Reproducible: Always

Steps to Reproduce:
1.
2.
3.
Comment 1 Frédéric Wang (:fredw) 2008-09-07 10:59:38 PDT
Created attachment 337307 [details]
testcase
Comment 2 Frédéric Wang (:fredw) 2008-09-08 06:18:25 PDT
Created attachment 337434 [details] [diff] [review]
Add a text-indent:0 in mtable to prevent unexpected spaces.
[Checkin: Comment 12]
Comment 3 Karl Tomlinson (:karlt) 2008-09-08 14:43:09 PDT
Comment on attachment 337434 [details] [diff] [review]
Add a text-indent:0 in mtable to prevent unexpected spaces.
[Checkin: Comment 12]

Thanks, Frédéric.
I'm just trying to think whether maybe we should be doing this on the mtd or even on the anonymous nsMathMLmtdInnerFrame block frame.  It only makes a difference though if someone is going to set text-indent on an mtable, mtr, or mtd.  What do you think, Rob?
Comment 4 Robert O'Callahan (:roc) (email my personal email if necessary) 2008-09-09 01:37:02 PDT
Comment on attachment 337434 [details] [diff] [review]
Add a text-indent:0 in mtable to prevent unexpected spaces.
[Checkin: Comment 12]

Let's do it on <mtable>, since the equivalent rule in html.css is on <table>.
Comment 5 Frédéric Wang (:fredw) 2008-09-09 03:21:18 PDT
Created attachment 337632 [details]
Bug when <math> is in an SVG foreignObject
Comment 6 Frédéric Wang (:fredw) 2008-09-09 06:51:03 PDT
The previous attachment show the bug of text-indent when the <math> is inside a foreignObject: the formulae are shift to the right. Here again, it is fixable by attaching a text-indent:0 to -moz-svg-foreign-content
Comment 7 Frédéric Wang (:fredw) 2008-09-09 06:53:58 PDT
Created attachment 337654 [details] [diff] [review]
Add a text-indent:0 to prevent the shift
[Checkin: Comment 12]
Comment 8 Karl Tomlinson (:karlt) 2008-09-09 14:03:26 PDT
One thing to consider here is whether html within a foreignObject should inherit text-indent.

It looks like the issue in attachment 337632 [details] might be due to the <foreignObject> creating a block context for the inline <math>.  Maybe it needs to do that...
Comment 9 Robert O'Callahan (:roc) (email my personal email if necessary) 2008-09-09 16:33:09 PDT
Comment on attachment 337654 [details] [diff] [review]
Add a text-indent:0 to prevent the shift
[Checkin: Comment 12]

It does need to use a block. I think this is right; <svg> should behave like <table> here.
Comment 10 Frédéric Wang (:fredw) 2008-09-11 09:36:59 PDT
Can someone commit my two patches, please?
Comment 11 Robert O'Callahan (:roc) (email my personal email if necessary) 2008-09-11 16:43:16 PDT
It's marked checkin-needed so that should happen reasonably soon.
Comment 12 Karl Tomlinson (:karlt) 2008-09-15 15:45:03 PDT
Checked these in, thank you:

http://hg.mozilla.org/mozilla-central/rev/2eef7a07820a
http://hg.mozilla.org/mozilla-central/rev/1b64769375b2

Note You need to log in before you can comment on or make changes to this bug.