I am using SVG Tiny 1.1 and it’s hard for me to understand the concept of “user unit”.
The SVG 1.1 specification defines each <length> without a specific element (for example, "mm", "cm", "pt", etc.) to be in the "user block".
When implementing the "SVGLength" interface, I came across 4 attributes associated with a length value; value, unityType, valueInSpecifiedUnit, valueAsString. The last 3 attributes are clear enough for me.
valueInSpecifiedUnitis in block type unitType.valueAsStringequals valueInSpecifiedUnit+ unitTypestring value. For example: "10 mm"
However, the attribute value is specified in the user block. So my questions are:
- What is a custom block?
- how to convert from “user unit” to “absolute unit”, for example millimeter (mm)?
Hi,
source
share