Closed Bug 1274796 Opened 10 years ago Closed 10 years ago

spacing around namedspaces is not accepted for MathML lengths

Categories

(Core :: MathML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla49
Tracking Status
firefox49 --- fixed

People

(Reporter: fwang, Assigned: jkitch)

References

()

Details

Attachments

(1 file, 1 obsolete file)

The RelaxNG syntax for MathML lengths is pattern = '\s*((-?[0-9]*([0-9]\.?|\.[0-9])[0-9]*(e[mx]|in|cm|mm|p[xtc]|%)?)|(negative)?((very){0,2}thi(n|ck)|medium)mathspace)\s*' It seems that we do not support spacing around namedspaces e.g. <mspace width=" thickmathspace "/> See http://tests.mathml-association.org/mathml/relations/css-styling/lengths-3.html
Attached patch patch.diff (obsolete) — Splinter Review
nsMathMLElement::ParseNumericValue parses numeric values using a copy of the string with whitespace removed, but then uses the original string for the named spaces. The attached patch parses numeric and named spaces using the same white-space suppressed string.
Assignee: nobody → jkitch.bug
Status: NEW → ASSIGNED
Attachment #8755160 - Flags: review?(fred.wang)
Comment on attachment 8755160 [details] [diff] [review] patch.diff Review of attachment 8755160 [details] [diff] [review]: ----------------------------------------------------------------- OK, that one was easy. Thanks!
Attachment #8755160 - Flags: review?(fred.wang) → review+
08:55:24 INFO - 105 INFO TEST-START | layout/mathml/imptests/test_lengths-3.html 08:55:24 INFO - 106 INFO TEST-UNEXPECTED-FAIL | layout/mathml/imptests/test_lengths-3.html | Units - Units: assert_approx_equals: ex expected 500 +/- 1 but got 501.66668701171875 08:55:24 INFO - 107 INFO TEST-UNEXPECTED-FAIL | layout/mathml/imptests/test_lengths-3.html | Trimming of space - Trimming of space: assert_approx_equals: ex expected 500 +/- 1 but got 501.66668701171875
I think increasing the tolerance is fine.
My first thought is to bump the tolerance up to 2. If not, this isn't something that I can debug.
Flags: needinfo?(jkitch.bug)
Attached patch patch.diffSplinter Review
Attachment #8755160 - Attachment is obsolete: true
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla49
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: