Releases: meyfa/php-svg
Releases · meyfa/php-svg
v0.8.0
What's Changed
Breaking changes
- Remove
$root
parameter ofSVGDocumentFragment
constructor (def5a72)
(breaks any code using nested<svg>
tags)
Features
- Add
getElementById
method to document class (936d22c) - Add
getElementsByTagName
method to nodes (2283a21) - Add support for node values (inner text);
<text>
,<textPath>
(PR #42 by @thomas-kl1) (c628ff3) - Allow omitting of leading XML tag when writing output (PR #48 by @micgro42) (fe8c9d9)
- Add
<title>
tag (PR #47 by @micgro42) (9c73817) - Add support for adding children at a specific index (#51) (9e50562)
- Add
SVGNodeContainer::setChild
method (#51) (48c3980) - Add generic type for unknown nodes(#41) (5677a18)
Fixes
- Fix
setType
method onSVGStyle
(PR #44 by @peter279k) (212cae4) - Travis 5.3 test (PR #46 by @peter279k) (e309858)
New Contributors
- @thomas-kl1 made their first contribution in #42
- @peter279k made their first contribution in #44
- @micgro42 made their first contribution in #48
Full Changelog: v0.7.0...v0.8.0
v0.7.0
What's Changed
Besides internal rewrites, this release offers many fixes for nonconforming behavior. In addition, there is now support for rectangles with rounded corners, the full range of CSS color notation and automatic entity escaping in attributes ("
→ "
).
Fixes
- Fix miscellaneous
SVGDocumentFragment
test failures (094238d) - Remove unnecessary rasterizer clipping (20e64d5)
- Treat empty namespace string like 'xmlns' (58a43f7)
- Fix namespaces not added to document fragment by
SVGReader
(dadcabd) - Fix width/height taken from
viewBox
bySVGReader
when explicit attributes are missing (dadcabd) - Fix
SVG::convertUnit
accepting missing value (c9ce6ed)
Features
- Add support for rounded rectangles (PR #29 by @yoya, PR #34 by @meyfa) (600da3e)
- Rewrite color parsing algorithm (#36, #37) (203c93e)
- Decode/Encode XML entities in reader/writer (#39) (a84f8dd)
- Make
SVGNode::setStyle
andSVGNode::setAttribute
unset properties when given null (0747a98) - Remove obsolete
SVGNode::setAttributeOptional
(#38) (0747a98) - Rewrite viewBox parsing for
SVGNode
(c8c4f6b)
Tests
- Huge expansion of unit testing suite (work in progress) (see #35)
New Contributors
Full Changelog: v0.6.1...v0.7.0
v0.6.1
v0.6.0
Breaking changes
- BREAKING: Update package name and author data (ae8650a)
- Please change the package name in your Composer file to
meyfa/php-svg
- Please change the package name in your Composer file to
- BREAKING: Shorten vendor namespace to "SVG" (cde475b)
- Please update all
use
statements to start withSVG\
, e.g.use SVG\SVGImage
- Please update all
Fixes
- Fix
SVGRect::setHeight()
setting the width (16d790c)
Features
- Add support for
<image>
tag (PR #26) (e2148fb)- Add SVGImageRenderer for embedded images (can render URLs as well as data URIs)
- Add SVGImageElement for
<image>
tag
- Add support for
<style>
tag, improved viewbox, nested docs (PR #27) (67ff696)
Style
v0.5.4
v0.5.3
v0.5.2
v0.5.1
Features
- Add support for rgb/rgba colors with percentages (81136fa), as well as hsl and hsla color support (aa48436) (see #11)
- Add
display: none
(fd2c893) andvisibility
(dbcb999) support to node rasterization (see #15)
Fixes
- Rewrite path command parsing (fixes #17, fixes #18) (2dedb4e)
- Fix "at least 3 points" error occurring for some paths (96605e8)
- Use floating-point modulo in HSL color parsing (9d9c064)
Style
- Update composer.json description (8c9e9d3)
v0.5.0
Features
- POTENTIALLY BREAKING: Make SVGNodeContainer methods chainable (fixes #9) (98aebf0)
- Add support for named colors (fixes #12) (0061d65)
- Add 'transparent' color support (fcae18c)
- Add support for 'pt' unit (12pt = 16px) (a02b4c1)
- Add getter & setter for
d
attribute to SVGPath (cafd2be)
Fixes
- Fix renderers interpreting percentages as pixels (35ab405)
- Draw precise outlines in SVGRectRenderer (fixes #7) (1137e78)