README.md in prawn-svg-0.24.0 vs README.md in prawn-svg-0.25.0
- old
+ new
@@ -58,18 +58,18 @@
- <tt><rect></tt>. Rounded rects are supported, but only one radius is applied to all corners.
- <tt><path></tt> supports all commands defined in SVG 1.1, although the
implementation of elliptical arc is a bit rough at the moment.
- - <tt><text></tt> and <tt><tspan></tt> with attributes
- <tt>text-anchor</tt>, <tt>font-size</tt>, <tt>font-family</tt>, <tt>font-weight</tt>, <tt>font-style</tt>, <tt>letter-spacing</tt>, <tt>dx</tt>, <tt>dy</tt>
+ - `<text>`, `<tspan>` and `<tref>` with attributes `x`, `y`, `dx`, `dy`, `rotate`, and with extra properties
+ `text-anchor`, `font-size`, `font-family`, `font-weight`, `font-style`, `letter-spacing`
- <tt><svg></tt>, <tt><g></tt> and <tt><symbol></tt>
- <tt><use></tt>
- - <tt><style></tt> plus <tt>id</tt>, <tt>class</tt> and <tt>style</tt> attributes (see CSS section below)
+ - <tt><style></tt> (see CSS section below)
- <tt><image></tt> with <tt>http:</tt>, <tt>https:</tt>, <tt>data:image/\*;base64</tt> and `file:` schemes
(`file:` is disabled by default for security reasons, see Options section above)
- <tt><clipPath></tt>
@@ -80,30 +80,34 @@
into Prawn. (gradientTransform, spreadMethod and stop-opacity are unimplemented.)
- `<switch>` and `<foreignObject>`, although prawn-svg cannot handle any data that is not SVG so `<foreignObject>`
tags are always ignored.
- - attributes/styles: <tt>fill</tt>, <tt>stroke</tt>, <tt>stroke-width</tt>, <tt>stroke-linecap</tt>, <tt>stroke-dasharray</tt>, <tt>opacity</tt>, <tt>fill-opacity</tt>, <tt>stroke-opacity</tt>, <tt>transform</tt>, <tt>clip-path</tt>, <tt>display</tt>, `marker-start`, `marker-mid`, `marker-end`
+ - properties: `clip-path`, `color`, `display`, `fill-opacity`, `fill`, `opacity`, `overflow`, `stroke`, `stroke-dasharray`, `stroke-linecap`, `stroke-opacity`, `stroke-width`
- - the <tt>viewBox</tt> attribute on <tt><svg></tt> and `<marker>` tags
+ - properties on lines, polylines, polygons and paths: `marker-end`, `marker-mid`, `marker-start`
- - the <tt>preserveAspectRatio</tt> attribute on <tt><svg></tt>, <tt><image></tt> and `<marker>` tags
+ - attributes on all elements: `class`, `id`, `style`, `transform`, `xml:space`
- - transform methods: <tt>translate</tt>, <tt>rotate</tt>, <tt>scale</tt>, <tt>matrix</tt>
+ - the <tt>viewBox</tt> attribute on <tt><svg></tt> and `<marker>` elements
+ - the <tt>preserveAspectRatio</tt> attribute on <tt><svg></tt>, <tt><image></tt> and `<marker>` elements
+
+ - transform methods: <tt>translate()</tt>, <tt>rotate()</tt>, <tt>scale()</tt>, <tt>matrix()</tt>
+
- colors: HTML standard names, <tt>#xxx</tt>, <tt>#xxxxxx</tt>, <tt>rgb(1, 2, 3)</tt>, <tt>rgb(1%, 2%, 3%)</tt>
- measurements specified in <tt>pt</tt>, <tt>cm</tt>, <tt>dm</tt>, <tt>ft</tt>, <tt>in</tt>, <tt>m</tt>, <tt>mm</tt>, <tt>yd</tt>, <tt>pc</tt>, <tt>%</tt>
- - fonts: generic CSS fonts, built-in PDF fonts, and any TTF fonts in your fonts path
+ - fonts: generic CSS fonts, built-in PDF fonts, and any TTF fonts in your fonts path, specified in any of the measurements above plus `em` or `rem`
## CSS
prawn-svg uses the css_parser gem to parse CSS <tt><style></tt> blocks. It only handles simple tag, class or id selectors; attribute and other advanced selectors are not supported by the gem.
## Not supported
-prawn-svg does not support sub-viewports, radial gradients, or patterns.
+prawn-svg does not support radial gradients or patterns.
## Configuration
### Fonts