NanoSVG::Parser
Inherits Reference < Object
Constants
ALIGN_MAX = 2
ALIGN_MEET = 1
ALIGN_MID = 1
ALIGN_MIN = 0
preserveAspectRatio alignment
ALIGN_NONE = 0
ALIGN_SLICE = 2
EPSILON = 1e-12
KAPPA90 = 0.5522847493_f32
MAX_ATTR = 128
MAX_CLASSES = 32
MAX_DASHES = 8
PI = 3.14159265358979323846264338327_f32
SQRT2F = (Math.sqrt(2.0)).to_f32
XML_MAX_ATTRIBS = 256
Constructors
new
SourceClass methods
encode_paint_order(a : UInt8, b : UInt8, c : UInt8) : UInt8
Sourceparse(input : String, units : String = "px", dpi : Float32 = 96.0_f32) : Image
Parses an SVG from a string (does not modify the input).
Instance methods
create_gradients
Sourcedpi
Sourcedpi=(dpi : Float32)
Sourceimage
Sourceimage=(image : Image)
Sourceparse_xml(input : String)
Sourceresolve_pending_uses
Instantiates deferred <use> references whose defs appeared later in the document. Unresolvable references are dropped silently.
scale_to_viewbox(units : String)
Source