Crates.io | usvgr |
lib.rs | usvgr |
version | 0.43.2 |
source | src |
created_at | 2022-09-04 11:47:36.636183 |
updated_at | 2024-10-24 17:13:35.212845 |
description | An SVG simplification library. |
homepage | |
repository | https://github.com/RazrFalcon/svgr |
max_upload_size | |
id | 658252 |
size | 637,488 |
usvgr
(micro SVG) is an SVG parser that tries to solve most of SVG complexity.
SVG is notoriously hard to parse. usvgr
presents a layer between an XML library and
a potential SVG rendering library. It will parse an input SVG into a strongly-typed tree structure
were all the elements, attributes, references and other SVG features are already resolved
and presented in the simplest way possible.
So a caller doesn't have to worry about most of the issues related to SVG parsing
and can focus just on the rendering part.
rect
and circle
) will be converted into pathsuse
will be resolved and replaced with the reference contentsvg
will be resolved#elem
and url(#elem)
) will be resolvedswitch
will be resolvedxml:space
),
text chunks and spans resolvingfilter="contrast(50%)"
objectBoundingBox
will be replaced with userSpaceOnUse
a
, view
, cursor
, script
, no events and no animationsusvgr is licensed under the MPLv2.0.