A number of stylistic changes have been made to the specification to make it more readable. These include the following:
A change towards using styling similar to contemporary CSS specifications.
Annotations have been added to the specification to reflect features that the Working Group
has resolved on including and for which a member of the group has committed to drive that feature.
Changes to highlight that SVG can be used in HTML as well as in XML.
Merged the metadata chapter with the document structure chapter.
In additional to the editorial changes listed above, the following substantial additions, changes and removals
have been made.
L.2.1. Across the whole document (owner: liam)
References to the SVG DTD have been removed.
IDL has been updated to use Web IDL syntax.
Added "length" attribute and indexed property access to all list interfaces.
Remove definition of <angle> type and reference CSS3-values.
Change all coordinate types to <length> in preparation for referencing css3-values..
Add the ‘script’ element to the content model of all elements.
Changed the initialize, appendItem, replaceItem and insertItemBefore methods
on list objects to make a copy of any list item being inserted that is already
in another list.
The ‘image’ and ‘script’ elements have gained a crossorigin attribute,
for use with the CORS-enabled fetch algorithm.
Removed getStrokeBBox from SVGGraphicsElement and extended getBBox with a dictionary argument that controls which parts of the element are included in the returned bounding box.
Defined event handler content attributes and IDL attributes on the root ‘svg’ element to be for events fired at the Window, like HTML's event handler content attributes and IDL attribute on body.
Rewrite ‘desc’ and ‘title’ description
to reflect ARIA and accessibility mapping.
Remove recommendation on how to structure metadata elements
within the SVG document.
Remove requirement for SVGDocument property on the Document interface object.
Descendent elements of ‘switch’ that have
the ‘systemLanguage’ attribute should be reordered according to the
definition of the SMIL 'allowReorder' attribute.
Update section on element roles to conform to latest SVG Accessibility API Mappings specification.
Soften recommendation to put pre-defined content in a defs element even if not required.
Change display behavior of defs, title, desc, metadata, and symbol elements to be defined using user agent styles.
Allow x, y, width, and height presentation attributes on a symbol, with the same effect on a rendered instance as on a nested svg element.
Specify a backwards-compatible default behavior for ‘refX’ and ‘refY’ on a symbol (which will be different from marker); clarify that keywords have same behavior as marker.
Re-define use-element shadow trees to be consistent with the shadow DOM spec,
to integrate better with other SVG 2 changes,
and to clarify much related behavior, including:
x/y/width/height are presentation attributes, albeit ones with a unique effect on final layout
zero values for width and height are only significant through their impact on the used value of a cloned svg/symbol; negative values are parse errors
Allow use elements to reference any element that can be a valid child of an SVG container, rather than only graphics elements
Define the SVGUseElementShadowRoot interface as an extension of the ShadowRoot interface, and require it to be used for use-element shadow trees
Define a number of terms related to shadow DOM and use elements, referencing the DOM standard where applicable
Clarify that use-element shadow trees are generated even if the element is in a conditional processing failed branch (consistent with previous guidance re display:none)
Element instances in the shadow tree must appear to be regular Element nodes, except they are read-only.
Properties formerly defined on the SVGElementInstance object are now defined as a mixin interface extending SVGElement
Clarify that URL references in cloned content are made absolute relative to the source file.
Clarify that the shadow tree is discarded if the cross-references change, including due to declarative animation (the original and animated shadow trees are not preserved in parallel).
Clarify that circular references only block the rendering of the use-element that would connect the circle, and not it's own host.
Added warning about x/y behaving as a transformation on the use element, and the impact on userSpaceOnUse graphical effects.
Redefine the way width/height on use elements impact svg/symbol to be consistent with geometry properties and auto values.
Clarify that for other re-used graphics (not svg/symbol), the shadow elements are laid out in the use element's coordinate system, including for the resolution of percentage lengths.
Redefine style cloning in shadow trees to be consistent with style scoping in shadow DOM, including by requiring style sheets to be cloned into the shadow DOM's scope.
Add warning and example regarding the cases where this results in different styles than an SVG 1.1-conforming user agent.
Add example regarding the inherited behavior of the visibility property.
Require multimedia in use-element copies to be synchronized with all other instances of the same original element.
Clarify that the shadow tree shares the document timeline for animations with its host document.
Define a ShadowAnimation interface to represent the cloning of Web Animations API animations
Prohibit WAAPI animations from being directly applied to element instances in the use-element shadow tree.
Define the propagation of SMIL-style animations through the cloning of animation elements; require that animations elements affecting the referenced graphic be cloned into the shadow tree, even if they are not descendents of the referenced element.
Define how event-based animation element triggers and animation element href attributes behave when there are multiple elements with the same ‘id’ in different node trees.
Require event handling in use-element shadow trees to follow the event retargetting rules from the Shadow DOM spec.
Clarify that the copying of event listeners from referenced graphics to their element instances applies to listeners added by script as well as by event attributes.
Prohibit event listeners from being directly added to elements in the use-element shadow tree.
Make use elements and symbols map to the graphics-object role by default, so the shadow content will be accessible.
Make the SVGSymbolElement interface extend from SVGGraphicsElement, so that rendered symbol element instances have all the behavior of graphics elements (e.g., getBBox)
Restore the (animated)instanceRoot properties on the SVGUseElement interface.
Change role mapping for the ‘a’ element to depend on whether it is actually a valid link.
Mark ARIA state and property attributes as animatable.
Update requirements for ‘id’ values to harmonize with HTML, with extra warning about requirements for validity in an XML document.
Updated user agent style sheet - inner svg elements and foreignObject elements are no longer set as overflow:hidden.
Added hatch to list of elements with overflow:hidden in User Agent style sheet.
Set the default value of transform-origin to '0 0' for all elements except root svg elements and svg elements that are the child of a foreignObject element.
Substantially rewrote the chapter to be more concise.
Defined that HTML ‘link’ elements
must load external style sheets.
Specified the exact set of properties
that have presentation attributes, their names (when the presentation
attribute name does not match the property name), and on which elements
they are allowed.
Added a list of properties defined in other
specifications that conforming SVG 2 user agents must support.
Added User Agent style sheet rule to map the
deprecated ‘xml:space’ attribute to the
white-space property.
Required that @font-face rules and
::first-letter & ::first-line pseudo-elements on ‘text’
elements must be supported.
Required that all SVG and HTML
style sheets in an HTML document with inline SVG content must
apply to all content in the document.
Allow presentation attributes on any svg namespaced element.
Change display behavior of style element to be defined using user agent styles.
Add !important user agent style rules controlling never-rendered elements,
with a note explaining their impact.
Require interactive user agents to include :focus and ::selection styles.
Clean-up presentation attributes table to be consistent with other sections of the spec:
remove ‘mask’ from elements that treat x/y/width/height attributes as presentation attributes,
add ‘use’ and ‘symbol’;
exclude animation elements from those that treat fill as a presentation attribute;
remove d as a presentation attribute for ‘textPath’;
merge the discussion of gradientTransform and patternTransform into the main table.
Animations do not run in documents processed
as resource documents.
Made the appendix a chapter.
Integrate content on processing modes from the SVG Integration specification.
Define required processing modes for different types of SVG cross-references,
with suggested processing modes for similar references from HTML/CSS.
(Replaces the "referencing modes" section from SVG Integration.)
Update and re-organize all the conformance classes,
to be consistent with changes to other parts of this specification
and changes to other specifications.
Make clear that a SVG viewer for conformance purposes
is the user agent / SVG user agent mentioned everywhere else in the spec;
move the corresponding definitions from the Document structure chapter to here.
Move the non-normative section on suggested methods for generating
high-precision graphics to the Implementation Requirements appendix.
Changed getComputedTextLength() to not include
‘dx’ and ‘dy’ values.
Moved the discussion of width
and height properties to the Geometry Properties chapter.
Require support for ::selection in interactive user agents.
Require that text in non-rendered elements are not included in addressable characters
and therefore are not counted when assigning positioning attributes
and in the getNumberOfChars methods.
Require that Unknown elements within text render as unpositioned spans,
but that known-but-invalidly-positioned elements do not.
Clarify that when text is positioned along a transformed path,
offset distances should be measured in the text element's coordinate system,
not the path element's.
Specify DOMPointInit as argument type for getCharNumAtPosition() instead of
DOMPoint.
Added this chapter, which includes new
‘video’, ‘audio’, ‘iframe’, ‘canvas’,
‘source’ and ‘track’
elements that behave almost identically
to the equivalent HTML elements.
Removed the SVG copies of
HTML's embedded content elements and instead allowed those
elements to be used in the HTML namespace within SVG
container elements.
Removed the requirement to
ignore clip and overflow on an SVG document
when referenced by an ‘image’ element.
Allow image height and width to be "auto", determined from intrinsic dimensions or aspect ratio of the image file.
Clarify image and foreignObject sizing to be consistent with CSS and with geometry properties;
allow embedded HTML elements to be positioned using x, y, width, and height geometric properties.
Clarify that object-fit and object-position properties
apply to embedded HTML elements;
add warning note that they are not defined for ‘image’.
Moved the "Foreign namespaces and private data" section to the Document Structure chapter.
Updated the reference to the (abandoned) Resource Priorities spec to instead refer to the (working draft) Resource Hints spec.
L.2.14. Painting chapter (owner: BogdanBrinza)
Added more detail to the descriptions of the stroke properties and added algorithms
defining the exact shape a stroke must have.
Added the ‘solidcolor’ element and its two properties solid-color
and solid-opacity, ported over from SVG Tiny 1.2. (Renamed 'solidColor' to
'solidcolor'.)
Added an ‘fr’ attribute to the ‘radialGradient’ element,
which allows specifying the radius of the focal circle.
Added a section for mesh gradients, defining the ‘mesh’, ‘meshrow’
and ‘meshpatch’ elements. (Renamed 'meshGradient' to 'mesh', 'meshRow' to 'meshrow',
and 'meshPatch' to 'meshpatch'.)
Added a section for hatches, defining the ‘hatch’ and ‘hatchpath’ elements.
(Renamed 'hatchPath' to 'hatchpath'.)
Renamed ‘gradientTransform’ on the ‘mesh’ element
and ‘hatchTransform’ on the ‘hatch’ element to ‘transform’.
Change display behavior of paint server elements to be defined using user agent styles.
Define common handling of paint server template cross-references,
allowing external file references,
using a use-element shadow DOM model for cloned child content,
defining consistent behavior for whether title and desc affect child cloning,
and explicitly defining which attributes are derived from the template for each element.
Add notes warning about attributes that look like presentation attributes, but aren't.
Removed this chapter and the SVG Fonts
feature it contained, including the
‘font’,
‘glyph’,
‘missing-glyph’,
‘hkern’,
‘vkern’,
‘font-face’,
‘font-face-src’,
‘font-face-uri’,
‘font-face-format’ and
‘font-face-name’ elements
and their corresponding IDL interfaces.