← API reference
CANONICAL TYPE REFERENCE

Length

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.

rawFloat!

The stored numeric value, in unit. Use this together with unit if you need to render in the user's original unit.

The unit the value was originally supplied in.

The value re-expressed in micrometres.

The value re-expressed in millimetres. This is the canonical unit for arithmetic-equivalence.

The value re-expressed in centimetres.

inchesFloat!

The value re-expressed in inches.

pointsFloat!

The value re-expressed in PostScript / DTP points.

valueFloat!

The value re-expressed in any supported unit. Convenience for clients that want to honour a user-chosen display preference.

Arguments (1)
unitLengthUnit!

The unit to re-express the value in.

View exact SDL
"""
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.
"""
type Length {
  """
  The stored numeric value, in `unit`. Use this together with `unit` if you need to render in the user's original unit.
  """
  raw: Float!
  """The unit the value was originally supplied in."""
  unit: LengthUnit!
  """The value re-expressed in micrometres."""
  micrometers: Float!
  """
  The value re-expressed in millimetres. This is the canonical unit for arithmetic-equivalence.
  """
  millimeters: Float!
  """The value re-expressed in centimetres."""
  centimeters: Float!
  """The value re-expressed in inches."""
  inches: Float!
  """The value re-expressed in PostScript / DTP points."""
  points: Float!
  """
  The value re-expressed in any supported unit. Convenience for clients that want to honour a user-chosen display preference.
  """
  value(
    """The unit to re-express the value in."""
    unit: LengthUnit!
  ): Float!
}

One stable address across all schema views. Follow a field’s type to explore connections between domains.