Proposals/Shorthand presentation attribute

From SVG

This is a proposal for ISSUE-2430.

It can be confusing for authors why this will work:

<path d="..." style="marker: url(#m)"/>

while this won't:

<path d="..." marker="url(#m)"/>

and instead it must be written as:

<path d="..." marker-start="url(#m)" marker-mid="url(#m)" marker-end="url(#m)"/>

Also, if we ever want to turn some properties into shorthands (such as overflow into overflow-x and overflow-y) then we'll want to allow shorthands to be specified as presentation attributes.

The reason this has been disallowed so far, presumably, is because we then need to define the order in which the shorthands and any component properties are placed into the corresponding style sheet, and that we cannot take this from the ordering of the attributes in the markup. For example with:

<path d="..." marker="url(#m1)" marker-mid="url(#m2)"/>

we would need to decide whether the corresponding style sheet is:

 marker: url(#m1);
 marker-mid: url(#m2);

or:

 marker-mid: url(#m2);
 marker: url(#m1);

Proposal: we allow shorthand properties to be specified as presentation attributes, and they are considered to appear before any component properties in the corresponding style sheet. This allows for components of the shorthand to be overridden.