SVG Implementation specs

Version 2.2

Known limitations

  • On FMX, OsX, Android, iOS, measurement of glyphs is mostly just an approximation
  • On FMX gradient functionality is limited, no spreadmethod, no focusradius
  • On FMX dashed lines are not rendered correctly in Direct2D because the butt linecap is not implemented
  • There is no check on recursion on parsing an SVG document
  • CSS is case sensitive at the moment
  • See remarks on following tables on further limitations

 

Table of implemented SVG elements

Any elements that are not on the list are not supported.

SVG Element Implemented Interface
or class
Remarks
<a> Yes ISVGGroup Converted to a group element
<altGlyph> No
<altGlyphDef> No
<altGlyphItem> No
<animate> No
<animateMotion> No
<animateTransform> No
<circle> Yes ISVGCircle
<color-profile> No
<cursor> No
<clipPath> Yes ISVGClipPath
<defs> Yes ISVGDefs
<desc> No
<ellipse> Yes ISVGEllipse
<feBlend> Yes  ISVGFilterBlend
<feColorMatrix> Yes  ISVGFilterColorMatrix
<feComposite> Yes  ISVGFilterComposite
<feConvolveMatrix> Yes ISVGFilterConvolveMatrix
<feDiffuseLighting> Yes ISVGFilterDiffuseLighting
<feDisplacementMap> Yes ISVGFilterDisplacementMap
<feDistantLight> Yes  ISVGFilterDistantLight
<feFlood> Yes  ISVGFilterFlood
<feFuncA> Yes ISVGFilterFunc
<feFuncB> Yes ISVGFilterFunc
<feFuncG> Yes ISVGFilterFunc
<feFuncR> Yes ISVGFilterFunc
<feGaussianBlur> Yes ISVGFilterGuassianBlur
<feImage> Yes  ISVGFilterImage
<feMerge> Yes  ISVGFilterMerge
<feMergeNode> Yes ISVGFilterMergeNode
<feMorphology> Yes  ISVGFilterMorphology
<feOffset> Yes  ISVGFilterOffset
<fePointLight> Yes  ISVGFilterPointLight
<feSpecularLighting> Yes ISVGFilterSpecularLighting
<feSpotLight> Yes ISVGFilterSpotlight
<feTile> Yes ISVGFilterTile
<feTurbulence> Yes  ISVGFilterTurbulence
<filter> Yes ISVGFilter
<font> Yes  ISVGFont
<font-face> Yes  ISVGFontFace
<font-face-format> No
<font-face-name> Yes  Processed in the parser
<font-face-src> Yes  Processed in the parser
<font-face-uri> Yes  Processed in the parser
<foreignObject> No
<g> Yes ISVGGroup
<glyph> Yes  ISVGGlyph
<glyphRef> No
<image> Yes ISVGImage
<line> Yes ISVGLine
<linearGradient> Yes ISVGLinearGradient
<marker> Yes ISVGMarker
<mask> Yes ISVGMask
<metadata> No
<path> Yes ISVGPath
<pattern> Yes ISVGPattern
<polygon> Yes ISVGPolygon
<polyline> Yes ISVGPolyline
<radialGradient> Yes ISVGRadialGradient With limitations depending underlying graphics library
<rect> Yes ISVGRect
<script> No
<set> No
<solidColor> No
<stop> Yes TSVGGradientPoint
<style> Yes
<svg> Yes ISVG
<switch> Yes ISVGSwitch
<symbol> Yes ISVGSymbol
<text> Yes ISVGText
<textPath> Yes ISVGTextPath
<title> No
<tref> Yes ISVGTextRef
<tspan> Yes ISVGSpan
<use> Yes ISVGUse
<view> No

Table of implemented attributes.

This list is not complete, any attributes that are not on the list are not supported.

Attribute Implemented Interface
or class
Remarks
clip Yes TSVGAttrClip
clip-path Yes  TSVGAttrClipPath
clip-rule No
color Yes TSVGAttrColor
color-interpolation-filters Yes TSVGAttrColorInterpolationFilters
display Yes TSVGAttrDisplay
enable-background No This attribute is to be removed from the SVG specs. and is replaced by the “isolation” attribute
fill Yes TSVGAttrFill
fill-rule No
fill-opacity Yes TSVGAttrFillOpacity
filter Yes TSVGAttrFilter
flood-color Yes TSVGAttrFloodColor
flood-opacity Yes TSVGAttrFloodOpacity
font-family Yes TSVGAttrFontFamily
font-size Yes TSVGAttrFontSize
font-weight Yes With limitations
font-stretch Yes TSVGAttrFontStretch With limitations
font-style Yes TSVGAttrFontstyles With limitations
font-variant Yes TSVGAttrFontVariant With limitations
isolation Yes TSVGAttrIsolation
letter-spacing Yes TSVGAttrLetterSpacing
lighting-color Yes TSVGAttrLightingColor
marker Yes TSVGAttrMarker
marker-start Yes TSVGAttrMarkerStart
marker-mid Yes TSVGAttrMarkerMid
marker-end Yes TSVGAttrMarkerEnd
mask No Yes
opacity Yes TSVGAttrOpacity
overflow Yes TSVGAttrOverflow
pointer-events Yes TSVGAttrPointerEvents
requiredFeatures Yes TSVGAttrRequiredFeatures
requiredExtensions Yes TSVGAttrRequiredExtensions
stop-color Yes TSVGAttrStopColor
stop-opacity Yes TSVGAttrStopOpacity
stroke Yes TSVGAttrStroke
stroke-opacity Yes TSVGAttrStrokeOpacity
stroke-width Yes TSVGAttrStrokeWidth
stroke_linecap Yes TSVGAttrStrokeCap
stroke-linejoin Yes TSVGAttrStrokeJoin
stroke-miterlimit Yes TSVGAttrMiterLimit
stroke-dasharray Yes TSVGAttrDashArray
stroke-dashoffset Yes TSVGAttrDashOffset
systemLanguage Yes TSVGAttrSystemLanguage
text-anchor Yes TSVGAttrTextAnchor
text-decoration No
vector-effect No
viewport-fill No
viewport-fill-opacity No
visibility Yes TSVGAttrVisibility
writing-mode Yes TSVGAttrWritingMode

Table of implemented CSS

CSS is implemented as case-sensitive at the moment. Anything that is not on the list is not supported.

Selector types Implemented
* (All) Yes
<element> Yes
Selectors
. (Class) Yes
# (ID) Yes
Attribute Yes
PseudoClass Yes
PseudoClassTypes
FirstChild Yes
LastChild Yes
NthChild Yes
Language Yes
others… No
Attribute evaluators
Name only Yes
= (Equal) Yes
~= (Contains word) Yes
|= (Begins with word) Yes
^= (Begins with part of word) Yes
$= (Ends with word) Yes
*= (Contains part of word) Yes
others… No
Combinators
 (Descendant) Yes
> (Direct descendant) Yes
+ (Adjacent) Yes
~ (Preceding) Yes
others… No
Properties
See list of attributes