Skip to content

Remove support for nonzero unitless values for MathML lengths #24

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
fred-wang opened this issue Feb 22, 2019 · 5 comments
Closed

Remove support for nonzero unitless values for MathML lengths #24

fred-wang opened this issue Feb 22, 2019 · 5 comments
Labels
compatibility Issues affecting backward compatibility css / html5 Issues related to CSS or HTML5 interoperability MathML Core Issues affecting the MathML Core specification MathML 4 Issues affecting the MathML 4 specification need polyfill Issues requiring implementation changes need specification update Issues requiring specification changes

Comments

@fred-wang
Copy link

From https://mathml-refresh.github.io/mathml/chapter2.html#fund.units

"A number without a unit is intepreted as a multiple of the reference value. This form is primarily for backward compatibility and should be avoided, prefering explicit units for clarity. "

Converting unitless to percentage adds some complexity to the code. Moreover it is not very intuitive for users except maybe "0". I wonder if we can somewhat simplify this now.

cc @rwlbuis

@fred-wang fred-wang added MathML Core Issues affecting the MathML Core specification MathML 4 Issues affecting the MathML 4 specification css / html5 Issues related to CSS or HTML5 interoperability labels Feb 22, 2019
@physikerwelt
Copy link
Member

discussed in the telco on 2019-02-25:

  • consensus here?

@fred-wang
Copy link
Author

fred-wang commented Mar 14, 2019

cc @rwlbuis, @emilio

I removed the reference to nonzero unitless values w3c/mathml-core@6e821b2 ; @davidcarlisle can you please check whether the RelaxNG change is correct?

I'm leaving this open because it still remains to:

  • Remove WPT tests if any (probably convert them to check "0").
  • Send intent-to-remove to mozilla/webkit-dev mailing lists (maybe old Math WG too?).
  • Remove browser implementation.
  • Decide what to do for the full MathML spec (they are already deprecated, should we remove them?)
  • Add polyfill to https://github.com/mathml-refresh/mathml-polyfills (e.g. convert nonzero "NUMBER" lengths to (NUMBER/100)%").

Also, despite that "0" has a unique interpretation we might maybe be more explicit about how it is interpreted. CSS suggests it is interpreted as a number (https://drafts.csswg.org/css-values-3/#lengths) so it should be relative ("0%") per the old unitless intepretation. However, an absolute value (e.g. "0px") might be better for implementation since we don't need to bother with the default values. In any case this is an implementation details, it shouldn't affect the result.

@fred-wang fred-wang added the compatibility Issues affecting backward compatibility label Mar 20, 2019
@fred-wang
Copy link
Author

Consensus from https://lists.w3.org/Archives/Public/public-mathml4/2019Mar/0026.html is to deprecate from MathML full.

@fred-wang fred-wang added need resolution Issues needing resolution at MathML Refresh CG meeting need implementation update need polyfill Issues requiring implementation changes need specification update Issues requiring specification changes need tests Issues related to writing WPT tests and removed need resolution Issues needing resolution at MathML Refresh CG meeting labels May 16, 2019
@fred-wang fred-wang removed the need specification update Issues requiring specification changes label Jun 5, 2019
@fred-wang
Copy link
Author

fred-wang commented Jun 5, 2019

Core spec now uses <length-percentage> from CSS which does not allow nonzero unitless values.

fred-wang added a commit to web-platform-tests/wpt that referenced this issue Jul 18, 2019
…core.

Basically things like "7.em", "-7.em" or "5" are now invalid.

w3c/mathml#24
w3c/mathml#23
jgraham pushed a commit to web-platform-tests/wpt that referenced this issue Jul 18, 2019
…core.

Basically things like "7.em", "-7.em" or "5" are now invalid.

w3c/mathml#24
w3c/mathml#23
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this issue Jul 24, 2019
… some numbers are invalid in …, a=testonly

Automatic update from web-platform-tests
Update MathML tests for lengths now that some numbers are invalid in core.

Basically things like "7.em", "-7.em" or "5" are now invalid.

w3c/mathml#24
w3c/mathml#23

--

wpt-commits: a7bec3cae6324dfadbc93705eb8b119d550e094a
wpt-pr: 17908
xeonchen pushed a commit to xeonchen/gecko that referenced this issue Jul 25, 2019
… some numbers are invalid in …, a=testonly

Automatic update from web-platform-tests
Update MathML tests for lengths now that some numbers are invalid in core.

Basically things like "7.em", "-7.em" or "5" are now invalid.

w3c/mathml#24
w3c/mathml#23

--

wpt-commits: a7bec3cae6324dfadbc93705eb8b119d550e094a
wpt-pr: 17908
@fred-wang fred-wang removed the need tests Issues related to writing WPT tests label Jul 30, 2019
@fred-wang
Copy link
Author

This is tested by https://w3c-test.org/mathml/relations/css-styling/lengths-1.html
The rest of the work is about native/polyfill implementation updates, so we can close this.

moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this issue Aug 17, 2019
…@linethickness. r=emilio

See w3c/mathml#4
and https://groups.google.com/forum/#!topic/mozilla.dev.platform/G91-vBeC3Rw

This commit introduces a new preference option
mathml.mfrac_linethickness_names.disabled to disable linethickness names. For
now, these names are only disabled in Nightly builds. Announcements and actual
disabling of this and other MathML features will be considered later.

* test_bug553917.html is updated to check that these values now cause an error
  message to be logged into the console.
* mstyle-1.xhtml is updated to use a numeric linethickness since the point of
  the test is just to check that the attribute is not supported on mstyle, not
  about the actual attribute value.
* Other fractions tests relying on linethickness names are executed with the
  proper preference adjustment.
* mathml/presentation-markup/fractions/frac-linethickness-001.html is now
  closer to its expectation ; however the test still fails because nonzero
  unitless values are not removed yet. See
  w3c/mathml#24

Differential Revision: https://phabricator.services.mozilla.com/D42323

--HG--
extra : moz-landing-system : lando
xeonchen pushed a commit to xeonchen/gecko that referenced this issue Aug 17, 2019
…@linethickness. r=emilio

See w3c/mathml#4
and https://groups.google.com/forum/#!topic/mozilla.dev.platform/G91-vBeC3Rw

This commit introduces a new preference option
mathml.mfrac_linethickness_names.disabled to disable linethickness names. For
now, these names are only disabled in Nightly builds. Announcements and actual
disabling of this and other MathML features will be considered later.

* test_bug553917.html is updated to check that these values now cause an error
  message to be logged into the console.
* mstyle-1.xhtml is updated to use a numeric linethickness since the point of
  the test is just to check that the attribute is not supported on mstyle, not
  about the actual attribute value.
* Other fractions tests relying on linethickness names are executed with the
  proper preference adjustment.
* mathml/presentation-markup/fractions/frac-linethickness-001.html is now
  closer to its expectation ; however the test still fails because nonzero
  unitless values are not removed yet. See
  w3c/mathml#24

Differential Revision: https://phabricator.services.mozilla.com/D42323
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this issue Aug 20, 2019
See w3c/mathml#24
and https://groups.google.com/forum/#!topic/mozilla.dev.platform/-yV6wb3klSA

This commit introduces a new preference option
mathml.nonzero_unitless_lengths.disabled to disable MathML nonzero unitless
values like "5" for 500%. MathML nonzero unitless are now disabled by default
but it could be easily enabled again later if we decide otherwise.

* test_bug553917.html is updated to check that these values now cause an error
  message to be logged into the console rather than a deprecated warning
  when nonzero unitless lengths are disabled.
  Additionally, the test checking invalid double dots "2..0" is updated not
  to use unitless syntax.
* The old test 355548-3.xml checks support for mathsize names and also uses
  several features that are going to be deprecated. So it is just run with
  the proper preference adjustment.
* mfrac-linethickness-2.xhtml and number-size-1.xhtml check support for
  unitless lengths so they are now run with that support enabled.
* WPT tests frac-linethickness-001.html and lengths-1.html are executed with
  the some MathML features disabled in order to make them pass.
  We get more assertion passing for the "Legacy numbers" test of
  lengths-2.html ; however there are still some issues to address
  (see bug 1574751).

Differential Revision: https://phabricator.services.mozilla.com/D42427

--HG--
extra : moz-landing-system : lando
xeonchen pushed a commit to xeonchen/gecko that referenced this issue Aug 20, 2019
See w3c/mathml#24
and https://groups.google.com/forum/#!topic/mozilla.dev.platform/-yV6wb3klSA

This commit introduces a new preference option
mathml.nonzero_unitless_lengths.disabled to disable MathML nonzero unitless
values like "5" for 500%. MathML nonzero unitless are now disabled by default
but it could be easily enabled again later if we decide otherwise.

* test_bug553917.html is updated to check that these values now cause an error
  message to be logged into the console rather than a deprecated warning
  when nonzero unitless lengths are disabled.
  Additionally, the test checking invalid double dots "2..0" is updated not
  to use unitless syntax.
* The old test 355548-3.xml checks support for mathsize names and also uses
  several features that are going to be deprecated. So it is just run with
  the proper preference adjustment.
* mfrac-linethickness-2.xhtml and number-size-1.xhtml check support for
  unitless lengths so they are now run with that support enabled.
* WPT tests frac-linethickness-001.html and lengths-1.html are executed with
  the some MathML features disabled in order to make them pass.
  We get more assertion passing for the "Legacy numbers" test of
  lengths-2.html ; however there are still some issues to address
  (see bug 1574751).

Differential Revision: https://phabricator.services.mozilla.com/D42427
natechapin pushed a commit to natechapin/wpt that referenced this issue Aug 23, 2019
…core.

Basically things like "7.em", "-7.em" or "5" are now invalid.

w3c/mathml#24
w3c/mathml#23
@fred-wang fred-wang added the need specification update Issues requiring specification changes label Sep 16, 2019
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this issue Oct 4, 2019
… some numbers are invalid in …, a=testonly

Automatic update from web-platform-tests
Update MathML tests for lengths now that some numbers are invalid in core.

Basically things like "7.em", "-7.em" or "5" are now invalid.

w3c/mathml#24
w3c/mathml#23

--

wpt-commits: a7bec3cae6324dfadbc93705eb8b119d550e094a
wpt-pr: 17908

UltraBlame original commit: ac0176e866080ef838ca94c26e556216aefcecfa
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this issue Oct 4, 2019
…linethickness. r=emilio

See w3c/mathml#4
and https://groups.google.com/forum/#!topic/mozilla.dev.platform/G91-vBeC3Rw

This commit introduces a new preference option
mathml.mfrac_linethickness_names.disabled to disable linethickness names. For
now, these names are only disabled in Nightly builds. Announcements and actual
disabling of this and other MathML features will be considered later.

* test_bug553917.html is updated to check that these values now cause an error
  message to be logged into the console.
* mstyle-1.xhtml is updated to use a numeric linethickness since the point of
  the test is just to check that the attribute is not supported on mstyle, not
  about the actual attribute value.
* Other fractions tests relying on linethickness names are executed with the
  proper preference adjustment.
* mathml/presentation-markup/fractions/frac-linethickness-001.html is now
  closer to its expectation ; however the test still fails because nonzero
  unitless values are not removed yet. See
  w3c/mathml#24

Differential Revision: https://phabricator.services.mozilla.com/D42323

UltraBlame original commit: 0692436a2b33c134bf50654ce466e4bd5ddb05cf
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this issue Oct 4, 2019
See w3c/mathml#24
and https://groups.google.com/forum/#!topic/mozilla.dev.platform/-yV6wb3klSA

This commit introduces a new preference option
mathml.nonzero_unitless_lengths.disabled to disable MathML nonzero unitless
values like "5" for 500%. MathML nonzero unitless are now disabled by default
but it could be easily enabled again later if we decide otherwise.

* test_bug553917.html is updated to check that these values now cause an error
  message to be logged into the console rather than a deprecated warning
  when nonzero unitless lengths are disabled.
  Additionally, the test checking invalid double dots "2..0" is updated not
  to use unitless syntax.
* The old test 355548-3.xml checks support for mathsize names and also uses
  several features that are going to be deprecated. So it is just run with
  the proper preference adjustment.
* mfrac-linethickness-2.xhtml and number-size-1.xhtml check support for
  unitless lengths so they are now run with that support enabled.
* WPT tests frac-linethickness-001.html and lengths-1.html are executed with
  the some MathML features disabled in order to make them pass.
  We get more assertion passing for the "Legacy numbers" test of
  lengths-2.html ; however there are still some issues to address
  (see bug 1574751).

Differential Revision: https://phabricator.services.mozilla.com/D42427

UltraBlame original commit: e45398b513298e1c015c8bce85a5cae6cf16151f
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this issue Oct 4, 2019
… some numbers are invalid in …, a=testonly

Automatic update from web-platform-tests
Update MathML tests for lengths now that some numbers are invalid in core.

Basically things like "7.em", "-7.em" or "5" are now invalid.

w3c/mathml#24
w3c/mathml#23

--

wpt-commits: a7bec3cae6324dfadbc93705eb8b119d550e094a
wpt-pr: 17908

UltraBlame original commit: ac0176e866080ef838ca94c26e556216aefcecfa
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this issue Oct 4, 2019
… some numbers are invalid in …, a=testonly

Automatic update from web-platform-tests
Update MathML tests for lengths now that some numbers are invalid in core.

Basically things like "7.em", "-7.em" or "5" are now invalid.

w3c/mathml#24
w3c/mathml#23

--

wpt-commits: a7bec3cae6324dfadbc93705eb8b119d550e094a
wpt-pr: 17908

UltraBlame original commit: ac0176e866080ef838ca94c26e556216aefcecfa
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this issue Oct 4, 2019
…linethickness. r=emilio

See w3c/mathml#4
and https://groups.google.com/forum/#!topic/mozilla.dev.platform/G91-vBeC3Rw

This commit introduces a new preference option
mathml.mfrac_linethickness_names.disabled to disable linethickness names. For
now, these names are only disabled in Nightly builds. Announcements and actual
disabling of this and other MathML features will be considered later.

* test_bug553917.html is updated to check that these values now cause an error
  message to be logged into the console.
* mstyle-1.xhtml is updated to use a numeric linethickness since the point of
  the test is just to check that the attribute is not supported on mstyle, not
  about the actual attribute value.
* Other fractions tests relying on linethickness names are executed with the
  proper preference adjustment.
* mathml/presentation-markup/fractions/frac-linethickness-001.html is now
  closer to its expectation ; however the test still fails because nonzero
  unitless values are not removed yet. See
  w3c/mathml#24

Differential Revision: https://phabricator.services.mozilla.com/D42323

UltraBlame original commit: 0692436a2b33c134bf50654ce466e4bd5ddb05cf
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this issue Oct 4, 2019
…linethickness. r=emilio

See w3c/mathml#4
and https://groups.google.com/forum/#!topic/mozilla.dev.platform/G91-vBeC3Rw

This commit introduces a new preference option
mathml.mfrac_linethickness_names.disabled to disable linethickness names. For
now, these names are only disabled in Nightly builds. Announcements and actual
disabling of this and other MathML features will be considered later.

* test_bug553917.html is updated to check that these values now cause an error
  message to be logged into the console.
* mstyle-1.xhtml is updated to use a numeric linethickness since the point of
  the test is just to check that the attribute is not supported on mstyle, not
  about the actual attribute value.
* Other fractions tests relying on linethickness names are executed with the
  proper preference adjustment.
* mathml/presentation-markup/fractions/frac-linethickness-001.html is now
  closer to its expectation ; however the test still fails because nonzero
  unitless values are not removed yet. See
  w3c/mathml#24

Differential Revision: https://phabricator.services.mozilla.com/D42323

UltraBlame original commit: 0692436a2b33c134bf50654ce466e4bd5ddb05cf
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this issue Oct 4, 2019
See w3c/mathml#24
and https://groups.google.com/forum/#!topic/mozilla.dev.platform/-yV6wb3klSA

This commit introduces a new preference option
mathml.nonzero_unitless_lengths.disabled to disable MathML nonzero unitless
values like "5" for 500%. MathML nonzero unitless are now disabled by default
but it could be easily enabled again later if we decide otherwise.

* test_bug553917.html is updated to check that these values now cause an error
  message to be logged into the console rather than a deprecated warning
  when nonzero unitless lengths are disabled.
  Additionally, the test checking invalid double dots "2..0" is updated not
  to use unitless syntax.
* The old test 355548-3.xml checks support for mathsize names and also uses
  several features that are going to be deprecated. So it is just run with
  the proper preference adjustment.
* mfrac-linethickness-2.xhtml and number-size-1.xhtml check support for
  unitless lengths so they are now run with that support enabled.
* WPT tests frac-linethickness-001.html and lengths-1.html are executed with
  the some MathML features disabled in order to make them pass.
  We get more assertion passing for the "Legacy numbers" test of
  lengths-2.html ; however there are still some issues to address
  (see bug 1574751).

Differential Revision: https://phabricator.services.mozilla.com/D42427

UltraBlame original commit: e45398b513298e1c015c8bce85a5cae6cf16151f
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this issue Oct 4, 2019
See w3c/mathml#24
and https://groups.google.com/forum/#!topic/mozilla.dev.platform/-yV6wb3klSA

This commit introduces a new preference option
mathml.nonzero_unitless_lengths.disabled to disable MathML nonzero unitless
values like "5" for 500%. MathML nonzero unitless are now disabled by default
but it could be easily enabled again later if we decide otherwise.

* test_bug553917.html is updated to check that these values now cause an error
  message to be logged into the console rather than a deprecated warning
  when nonzero unitless lengths are disabled.
  Additionally, the test checking invalid double dots "2..0" is updated not
  to use unitless syntax.
* The old test 355548-3.xml checks support for mathsize names and also uses
  several features that are going to be deprecated. So it is just run with
  the proper preference adjustment.
* mfrac-linethickness-2.xhtml and number-size-1.xhtml check support for
  unitless lengths so they are now run with that support enabled.
* WPT tests frac-linethickness-001.html and lengths-1.html are executed with
  the some MathML features disabled in order to make them pass.
  We get more assertion passing for the "Legacy numbers" test of
  lengths-2.html ; however there are still some issues to address
  (see bug 1574751).

Differential Revision: https://phabricator.services.mozilla.com/D42427

UltraBlame original commit: e45398b513298e1c015c8bce85a5cae6cf16151f
bhearsum pushed a commit to mozilla-releng/staging-firefox that referenced this issue May 1, 2025
… some numbers are invalid in …, a=testonly

Automatic update from web-platform-tests
Update MathML tests for lengths now that some numbers are invalid in core.

Basically things like "7.em", "-7.em" or "5" are now invalid.

w3c/mathml#24
w3c/mathml#23

--

wpt-commits: a7bec3cae6324dfadbc93705eb8b119d550e094a
wpt-pr: 17908
bhearsum pushed a commit to mozilla-releng/staging-firefox that referenced this issue May 1, 2025
…@linethickness. r=emilio

See w3c/mathml#4
and https://groups.google.com/forum/#!topic/mozilla.dev.platform/G91-vBeC3Rw

This commit introduces a new preference option
mathml.mfrac_linethickness_names.disabled to disable linethickness names. For
now, these names are only disabled in Nightly builds. Announcements and actual
disabling of this and other MathML features will be considered later.

* test_bug553917.html is updated to check that these values now cause an error
  message to be logged into the console.
* mstyle-1.xhtml is updated to use a numeric linethickness since the point of
  the test is just to check that the attribute is not supported on mstyle, not
  about the actual attribute value.
* Other fractions tests relying on linethickness names are executed with the
  proper preference adjustment.
* mathml/presentation-markup/fractions/frac-linethickness-001.html is now
  closer to its expectation ; however the test still fails because nonzero
  unitless values are not removed yet. See
  w3c/mathml#24

Differential Revision: https://phabricator.services.mozilla.com/D42323
bhearsum pushed a commit to mozilla-releng/staging-firefox that referenced this issue May 1, 2025
See w3c/mathml#24
and https://groups.google.com/forum/#!topic/mozilla.dev.platform/-yV6wb3klSA

This commit introduces a new preference option
mathml.nonzero_unitless_lengths.disabled to disable MathML nonzero unitless
values like "5" for 500%. MathML nonzero unitless are now disabled by default
but it could be easily enabled again later if we decide otherwise.

* test_bug553917.html is updated to check that these values now cause an error
  message to be logged into the console rather than a deprecated warning
  when nonzero unitless lengths are disabled.
  Additionally, the test checking invalid double dots "2..0" is updated not
  to use unitless syntax.
* The old test 355548-3.xml checks support for mathsize names and also uses
  several features that are going to be deprecated. So it is just run with
  the proper preference adjustment.
* mfrac-linethickness-2.xhtml and number-size-1.xhtml check support for
  unitless lengths so they are now run with that support enabled.
* WPT tests frac-linethickness-001.html and lengths-1.html are executed with
  the some MathML features disabled in order to make them pass.
  We get more assertion passing for the "Legacy numbers" test of
  lengths-2.html ; however there are still some issues to address
  (see bug 1574751).

Differential Revision: https://phabricator.services.mozilla.com/D42427
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
compatibility Issues affecting backward compatibility css / html5 Issues related to CSS or HTML5 interoperability MathML Core Issues affecting the MathML Core specification MathML 4 Issues affecting the MathML 4 specification need polyfill Issues requiring implementation changes need specification update Issues requiring specification changes
Projects
None yet
Development

No branches or pull requests

2 participants