1// Copyright (C) 2023 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
5 \page svgextensions.html
6 \title Extended Features
7 \brief Extended Features (relative to 1.2 Tiny) of the Qt SVG module
9 The Qt SVG module supports the \l{SVG 1.2 Tiny Static Features}
10 {static features} of \l{http://www.w3.org/TR/SVGMobile12}{SVG 1.2 Tiny}.
12 The module also supports a few extra features which might be useful.
13 The \l QSvgRenderer parses all features (including the extra feature
14 set) by default. You can instruct the render to ignore these extra
15 features by passing the QtSvg::Tiny12FeaturesOnly flag in
16 \l QSvgRenderer::setOptions().
19 \section1 Extended features
21 Qt supports the following extended elements and related attributes as of
26 \l{https://www.w3.org/TR/SVG11/masking.html#MaskElement}{SVG 1.1}
28 \l{https://www.w3.org/TR/SVG11/struct.html#SymbolElement}{SVG 1.1} and
29 \l{https://www.w3.org/TR/SVG2/struct.html#SymbolElement}{SVG 2}
31 \l{https://www.w3.org/TR/SVG11/painting.html#MarkerElement}{SVG 1.1}
33 \l{https://www.w3.org/TR/SVG11/pservers.html#PatternElement}{SVG 1.1}
35 \l{https://www.w3.org/TR/SVG11/filters.html#FilterElement}{SVG 1.1}
37 \l{https://www.w3.org/TR/SVG11/filters.html#feColorMatrixElement}
40 \l{https://www.w3.org/TR/SVG11/filters.html#feCompositeElement}
43 \l{https://www.w3.org/TR/SVG11/filters.html#feFloodElement}{SVG 1.1}
45 \l{https://www.w3.org/TR/SVG11/filters.html#feGaussianBlurElement}
48 \l{https://www.w3.org/TR/SVG11/filters.html#feOffsetElement}{SVG 1.1}
50 \l{https://www.w3.org/TR/SVG11/filters.html#feMergeElement}{SVG 1.1}
56 Masking is supported in the form of the \c{<mask>} element and the mask
59 \note <clipPath> is not supported.
63 The following attributes of the \c{<mask>} element are supported:
71 \li \c{maskContentUnits}
74 The \c{mask} attribute is supported for all graphical and structural SVG
78 \section1 Symbols, Markers and Patterns
82 The following attributes of the \c{<symbol>} element are supported:
85 \li \c{x} (from SVG 2)
86 \li \c{y} (from SVG 2)
87 \li \c{width} (from SVG 2)
88 \li \c{height} (from SVG 2)
89 \li \c{preserveAspectRatio}
96 The following attributes of the \c{<marker>} element are supported:
105 \li \c{preserveAspectRatio}
117 are supported for \c{<path>}, \c{<line>}, \c{<polyline>} and \c{<polygon>}.
122 The following attributes are supported:
129 \li \c{patternContentUnits}
130 \li \c{patternTransform}
134 The following attributes are not supported:
136 \li \c{preserveAspectRatio}
143 Filters in SVG documents apply graphic effects on an element, parts of an
144 element, or the background below the element. Qt supports filter effects
145 applied to the whole element.
146 Qt does not support applying filters on only the element's fill or stroke
147 (\c FillPaint and \c StrokePaint), or its background (\c BackgroundImage
148 and \c BackgroundAlpha).
152 The following attributes of the \c{<filter>} element are supported:
160 \li \c{primitiveUnits}
163 The following attributes of the \c{<filter>} element are not supported:
170 The \c{filter} attribute is supported for all graphical and structural SVG
174 \section2 Filter primitives
176 The filter element contains various filter primitives. Qt supports the most
177 important filter primitives (see below).
179 All filter primitives share common set of attributes. The following are
187 \li \c{in} (Supported are \c{SourceGraphic}, \c{SourceAlpha}, and all
188 references to filters)
192 The following attributes are not supported:
195 \li \c{in} (Not supported are \c{BackgroundImage}, \c{BackgroundAlpha},
196 \c{FillPaint}, and \c{StrokePaint})
199 \section2 <feColorMatrix>
201 The following attributes are supported:
208 \section2 <feGaussianBlur>
210 The following attributes are supported:
216 The following attributes are not supported:
219 \li \c{edgeMode} (the implementation matches \c{none})
224 The following attributes are supported:
231 \section2 <feMerge> and <feMergeNode>
233 No additional attributes.
235 \section2 <feComposite>
237 The following attributes are supported:
249 The following attributes are supported:
253 \li \c{flood-opacity}