Intent to Deprecate and Remove: SVGElement.xmlbase/xmlspace/xmllang

65 views
Skip to first unread message

Philip Jägenstedt

unread,
May 7, 2015, 3:38:59 PM5/7/15
to blink-dev

Primary eng (and PM) emails

phi...@opera.com


Summary

Remove the SVGElement.xmlbase/xmlspace/xmllang IDL attributes, which reflect the xml:base, xml:space and xml:lang content attributes.


Motivation

These have been removed from the SVG spec:

https://github.com/w3c/svgwg/commit/b8f12424b25d5bc132460738e0a1ed9626b4a4a8

https://svgwg.org/svg2-draft/single-page.html#types-InterfaceSVGElement


My main reason for poking at this is xml:base, which Anne (DOM spec editor) wants to get rid of. It looks very ripe for deprecation and removal once its use as a reflected IDL attribute is gone. See https://code.google.com/p/chromium/issues/detail?id=341854


Compatibility Risk

These IDL attributes were added to WebKit in 2005 and 2006:

https://trac.webkit.org/changeset/10577

https://trac.webkit.org/changeset/16337


Gecko doesn't have xmlbase or xmllang, but does have SVGStyleElement.xmlspace with the comment "Spec claims this should be on SVGElement" (which is no longer true).

IE11 has all three attributes.

Alternative implementation suggestion for web developers

Use getAttributeNS and setAttributeNS. However, xml:base may be going away, so use <base href=""> instead if at all possible.


Usage information from UseCounter

https://www.chromestatus.com/metrics/feature/timeline/popularity/681

https://www.chromestatus.com/metrics/feature/timeline/popularity/682

https://www.chromestatus.com/metrics/feature/timeline/popularity/683


These reached stable with M42, but are still rounding to 0%, i.e. virtually unused.


Entry on chromestatus.com, crbug.com, or MDN

https://code.google.com/p/chromium/issues/detail?id=485676


Requesting approval to remove too?

Yes. The low usage makes removal likely safe, and a deprecation message has a very low chance of being seen for the same reason.

Philip Rogers

unread,
May 7, 2015, 8:54:40 PM5/7/15
to Philip Jägenstedt, blink-dev
LGTM, this will also let us clean up some cruft in the code (XMLNames.h, special handling in v8, etc).

Philip Jägenstedt

unread,
May 8, 2015, 7:32:03 AM5/8/15
to Philip Rogers, blink-dev, hyunju...@samsung.com
To clarify, XMLNames.h will be left after this removal, as all three
attributes are still used internally. If the xml:base removal (next
step) works out, that would remove base from xmlattrs.in. I have no
plans to mess with xml:lang or xml:space, but I have added use
counters for xml:space in case we want to:
https://www.chromestatus.com/metrics/feature/timeline/popularity/679
https://www.chromestatus.com/metrics/feature/timeline/popularity/680

A slight simplifications of the bindings generator should be possible
though, see https://codereview.chromium.org/1137593002/ where Hyunjune
has started working on this.

Philip
> To unsubscribe from this group and stop receiving emails from it, send an
> email to blink-dev+...@chromium.org.

Chris Harrelson

unread,
May 8, 2015, 12:17:52 PM5/8/15
to Philip Jägenstedt, Philip Rogers, blink-dev, hyunju...@samsung.com
LGTM

Dimitri Glazkov

unread,
May 12, 2015, 7:39:55 PM5/12/15
to Chris Harrelson, Philip Jägenstedt, Philip Rogers, blink-dev, hyunju...@samsung.com
LGTM2.

Jochen Eisinger

unread,
May 12, 2015, 7:59:58 PM5/12/15
to Dimitri Glazkov, Chris Harrelson, Philip Jägenstedt, Philip Rogers, blink-dev, hyunju...@samsung.com
lgtm3
Reply all
Reply to author
Forward
0 new messages