Closed Bug 334203 Opened 16 years ago Closed 12 years ago

line underneath inline mathml isn't shifted down resulting in text overlap


(Core :: MathML, defect)

Windows XP
Not set





(Reporter: chris.chiasson, Assigned: rbs)





(1 file)

1.64 KB, application/xhtml+xml
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20060308 Firefox/
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20060308 Firefox/

Find the paragraph that begins:
The objective function is minimized at

After that text is a MathML equation. Back when I made this page a month ago, that MathML rendered correctly. Now, there is a problem with the line below it not being shifted down, so the text overlaps. This problem is not present on other pages on my site, like this one:

Anyway, has something changed about the MathML rendering in recent FF updates? Am I just loony? :-/

Reproducible: Always

Steps to Reproduce:
1. Load
2. Find "The objective function is minimized at" and look at the equation after it.
3. The equation overlaps the text below.

Actual Results:  
The equation overlaps the text below it.

Expected Results:  
The equation should cause a shift in the line height of the line below it, adjusting the text so it doesn't overlap.

^^ doesn't have this problem but I don't know why.
Assignee: nobody → rbs
Component: General → MathML
Product: Firefox → Core
QA Contact: general → ian
Version: unspecified → Trunk

*** This bug has been marked as a duplicate of 324857 ***
Closed: 16 years ago
Resolution: --- → DUPLICATE
Can't be Cairo, since both the reporter and I see it with Firefox (this is probably where I get yelled at for choosing Trunk while moving out of Firefox, but then, either choice gets me yelled at).
Resolution: DUPLICATE → ---
Ah, good, trunk: it works in a 20051231 trunk build, and fails in a 20060128 build.
(In reply to comment #2)
> Can't be Cairo, since both the reporter and I see it with Firefox 

I can't see it with
I'd blame fonts, but I see the same thing on a Mac where I just installed the Mathematica 4.1 fonts and on Windows where I've had a full load of working math fonts for years.
In reply to comment #4, make sure you loaded the correct page - I gave an example of a page where the bug did not appear and an example of a page where the bug did appear.
Phil, are you using Mathematica or another program that generates <semantics> elements? I just noticed a formatting problem, where a table border was overlapping MathML, that went away when I used some XSLT to remove the <semantics> elements.
QA Contact: ian → mathml
The link is currently broken. Can someone gives a testcase that demonstrates the bug?
I think the correct URL is now However, I may have changed the page in the intervening time, as the text I pointed out doesn't appear verbatim. The part of the page I think I was referring to now occurrs in the paragraph following 
Table 4.5. P 4-4 Canonical Form of Initial Tableau. It has a vector solution to an optimization problem in the middle of the paragraph, so Firefox has to adjust the line heights. I think I may have worked around the problem back then by removing the semantics tag, since I don't see it anymore. BTW, perhaps the status of this bug should have been "confirmed" based on others comments above.

I'm not able to reproduce this bug. According to comment 2, this bug happens before the switch to Cairo, so it may have been fixed. How did you generate the <semantics/> tag?
Attached file Testcase
If you have Mathematica, you can create markup similar to what I originally had using the following command:

ExportString[{{Subscript[X, 1]}, {Subscript[X, 2]}} == {{2/3}, {2/3}},
   "MathML", {"Semantics" -> True, 
   "NamespacePrefixes" -> {"" -> 
      "ns303"}, "ElementFormatting" -> None}] /. 
 x_String :> StringReplace[x, "&#63449;" -> ""]

It produces the following output, which still doesn't break the current Firefox.

<ns303:math xmlns:ns303='' \
mrow><ns303:mrow><ns303:mo>(</ns303:mo><ns303:mtable rowspacing='1ex' \
columnspacing='1em' rowalign='baseline' \
mo>(</ns303:mo><ns303:mtable rowspacing='1ex' columnspacing='1em' \
rowalign='baseline' \
mo>)</ns303:mo></ns303:mrow></ns303:mrow><ns303:annotation-xml \
encoding='MathML-Content'><ns303:apply><ns303:eq \
ns303:ci>X</ns303:ci><ns303:cn \
ns303:cn type='integer'>2</ns303:cn></ns303:apply></ns303:list></\
ns303:list><ns303:list><ns303:list><ns303:cn \
type='rational'>2<ns303:sep \
/>3</ns303:cn></ns303:list><ns303:list><ns303:cn \
type='rational'>2<ns303:sep \

Maybe I am misremembering the example, but it just appears like Firefox is handling this correctly now.
BTW, that stringreplace rule is supposed to say "&#63449;" -> "=". It is replacing a character that most computers won't be able to display with a regular equal sign.
Thanks for these informations. I haven't got Mathematica. I copy your code inside an XHTML paragraph, but I still can't see the bug. I guess the bug has been fixed since your initial report.
Closed: 16 years ago12 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.