Skip to main content

Module svg_path_parser

Module svg_path_parser 

Source
Expand description

SVG d="" path data parser. SVG d="" path data parser.

Parses the d attribute of SVG <path> elements into SvgMultiPolygon geometry, supporting all 14 SVG path commands (M/m, L/l, H/h, V/v, C/c, S/s, Q/q, T/t, A/a, Z/z).

Enums§

SvgPathParseError
Errors that can occur during SVG path parsing.

Functions§

parse_svg_path_d
Parse an SVG path d attribute string into a SvgMultiPolygon.
svg_circle_to_paths
Approximate a circle with 4 cubic bezier curves.
svg_rect_to_path
Convert an SVG <rect> to a path with optional rounded corners.