Class: PointText

OSDPaperjsAnnotation.PointText(geoJSON)

Represents a point with text annotation item.

Constructor

new PointText(geoJSON)

The `PointText` class represents a point with text annotation item. It inherits from the `AnnotationItem` class and provides methods to work with point text annotations.
Parameters:
Name Type Description
geoJSON Object The GeoJSON object containing annotation data.
Properties:
Name Type Description
_paperItem paper.Group The associated paper item representing the point with text.
Source:

Extends

  • AnnotationItem

Members

circle

Get the circle that represents the point.
Source:

textitem

Get the text item associated with the point.
Source:

Methods

getCoordinates() → {Array.<number>}

Get the coordinates of the point.
Source:
Returns:
The coordinates of the point.
Type
Array.<number>

getGeoJSONType() → {Object}

Get the type of this object.
Source:
Returns:
with fields `type === 'Point'` and `subtype === 'PointText'`
Type
Object

getProperties() → {Object}

Get the properties of the point.
Source:
Returns:
The properties of the point.
Type
Object

getStyleProperties() → {Object}

Get the style properties of the point.
Source:
Returns:
The style properties of the point.
Type
Object

setStyle(props)

This method sets the style properties of the point with text using the provided properties object.
Parameters:
Name Type Description
props Object The style properties to set.
Source:

(static) onTransform(operation)

This static method handles transformation operations on the point annotation.
Parameters:
Name Type Description
operation string The type of transformation operation.
Source:

(static) supportsGeoJSONType(type, subtypeopt) → {Boolean}

Retrieves the supported types by the PointText annotation item.
Parameters:
Name Type Attributes Description
type String
subtype String <optional>
Source:
Returns:
Whether this constructor supports the requested type/subtype
Type
Boolean