GraphicOverlay

GraphicOverlay

new GraphicOverlay(options)

Description:
  • Represents an overlay containing Footprints, whether it is
Source:
Parameters:
Name Type Description
options GraphicOverlayOptions Configuration options for the overlay.

Methods

addFootprints(overlaysToAdd)

Description:
  • Add an array (or single) shapes (i.e. Footprint, Circle, Polyline, Ellipse, Vector, ...)
Source:
Parameters:
Name Type Description
overlaysToAdd Array.<Footprint> | Array.<Circle> | Array.<Polyline> | Array.<Ellipse> | Array.<Vector> a list (or single) shapes to add to the overlay

getFootprint(idx) → {Footprint|Circle|Polyline|Ellipse|Vector}

Description:
  • Returns a shape by an index
Source:
Parameters:
Name Type Description
idx number The index of the shape to retrieve
Returns:
The shape
Type
Footprint | Circle | Polyline | Ellipse | Vector

hide()

Description:
  • Hide the graphic overlay
Source:

removeAll()

Description:
  • Clear the overlay of all its shapes
Source:

setColor(color)

Description:
  • Set the color of the shapes inside the overlay
Source:
Parameters:
Name Type Description
color string the new color in hexadecimal e.g. '#ff00ff'

setLineDash(lineDashopt)

Description:
  • Set the dash line property
Source:
Parameters:
Name Type Attributes Default Description
lineDash Array.<number> <optional>
[] See the segments property here

setLineWidth(lineWidth)

Description:
  • Set the line width of the shapes inside the overlay
Source:
Parameters:
Name Type Description
lineWidth number the new line width in pixels

show()

Description:
  • Show the graphic overlay
Source:

toggle()

Description:
  • Toggle on/off the graphic overlay
Source:

(static) increaseBrightness(hex, percent) → {string}

Description:
  • Increase the brightness of a color by a percentage
Source:
Parameters:
Name Type Description
hex string The color given in hexadecimal e.g. '#ffa0bb'
percent number The percentage to increase the brightness of
Returns:
The new color given as an hexadecimal string
Type
string

(static) parseSTCS() → {Array.<Circle>|Array.<Polyline>|Array.<Ellipse>}

Description:
  • Parse a STCS string and returns a list of footprints (only circles, polygons and ellipses given in ICRS or FK5J2000 frame are handled). For visualization purposes, the difference between FK5J2000 and ICRS system is not noticeable. Therefore one can be interpreted as the other.
Source:
Returns:
The list of mixed circles, polygons and ellipses
Type
Array.<Circle> | Array.<Polyline> | Array.<Ellipse>