Cargo Features
[dependencies]
svg2pdf = { version = "0.13.0", default-features = false, features = ["image", "filters", "text"] }
- default = filters, image, text
-
These default features are set whenever
svg2pdfis added withoutsomewhere in the dependency tree.default-features = false - image default filters
-
Enables image
Affects
render::image… - filters default = image
-
Enables tiny-skia ^0.11.4 and raster-images of resvg ^0.45
resvg:
Enables decoding and rendering of raster images. When disabled,
imageelements with SVG data will still be rendered. Adds around 200KiB to your binary.Affects
render::filter… - text default
-
Enables fontdb, siphasher, subsetter, and ttf-parser, text of usvg ^0.45 and text of resvg ^0.45
resvg:
Enables SVG Text support.
Adds around 400KiB to your binary.Affects
render::text,context::Context.fonts…
Features from optional dependencies
In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.
- resvg filters text
-
Enables resvg ^0.45