Previous: Attributes, Up: Schematic Document Model [Contents][Index]

### 1.5 Coordinate system

Lepton documents use a coordinate system (internally referred to as ‘world’ coordinates) with coordinates increasing upwards and to the right (i.e. a conventional right-handed Cartesian coordinate system).

Although all coordinates may be positive or negative, lepton-schematic only displays objects with positive coordinates (i.e. in the upper right quadrant of the coordinate system). It is therefore recommended to use only positive coordinates.

In the Scheme API, the coordinate of a point is expressed in the format:

    (x . y)

and a set of bounds (i.e. a rectangular area in the document plane) is expressed in the format:

    ((left . top) . (right . bottom))

where `left` is the smaller x coordinate, `right` is the larger x coordinate, and `bottom` and `top` are respectively the smaller and larger y coordinates.