Type alias CoordinateSystemRelative

CoordinateSystemRelative: "relative"

Type definition for selector of relative coordinate system.

This coordinate system is relative to the bottom left corner of the Control (chart/dashboard/etc.), and is measured as pixels. For example, { x: 100, y: 20 } corresponds to 100 pixels from left and 20 pixels from bottom.

 // Example of a CoordinateRelative
const coordinateRelative = { x: 45, y: 10 }

By using translateCoordinate method, relative coordinates can be translated to other coordinate systems and vice versa. For example, in order to:

  • Position LCJS UI elements in pixels relative to control.
  • Find locations expressed with other coordinate systems relative to the control.
  • etc.

Users should not need to reference this type directly. Instead, the convenience selector coordsRelative should be used.