Skip to content

Length ​

Type: Object

A linear measurement with preserved unit provenance. Equality and ordering compare by canonical millimetres, but the original unit is round-tripped through the API and storage.

Fields ​

NameTypeArgsDescriptionDeprecated
centimetersFloat!The value re-expressed in centimetres.
inchesFloat!The value re-expressed in inches.
micrometersFloat!The value re-expressed in micrometres.
millimetersFloat!The value re-expressed in millimetres. This is the canonical unit for arithmetic-equivalence.
pointsFloat!The value re-expressed in PostScript / DTP points.
rawFloat!The stored numeric value, in unit. Use this together with unit if you need to render in the user's original unit.
unitLengthUnit!The unit the value was originally supplied in.
valueFloat!unit: LengthUnit!The value re-expressed in any supported unit. Convenience for clients that want to honour a user-chosen display preference.

Connect machines, automate workflows, and build custom apps for print production.