Length
Symbolica documentation for getting started, symbolic expressions, numerical evaluation, pattern matching, and APIs in Python and Rust.
Length
class LengthA Typst length such as 2pt or 1.2em.
Attributes
| Name | Description |
|---|---|
unit |
|
value |
unit
Length.unit: builtins.strvalue
Length.value: builtins.floatMethods
| Name | Description |
|---|---|
__new__ |
|
__repr__ |
|
cm |
|
em |
|
inches |
|
mm |
|
pt |
__new__
Length.__new__(value: builtins.float, unit: typing.Literal['pt', 'mm', 'cm', 'in', 'em']) -> Length__repr__
Length.__repr__() -> builtins.strcm
Length.cm(value: builtins.float) -> Lengthem
Length.em(value: builtins.float) -> Lengthinches
Length.inches(value: builtins.float) -> Lengthmm
Length.mm(value: builtins.float) -> Lengthpt
Length.pt(value: builtins.float) -> Length