SGLabelStyle Class

The SGLabelStyle class denotes a style object for labels created using the SGWorld.creator.createLabel() method.

Constructor

Name

Description

Constructor

Initializes a new instance of SGLabelStyle.

Properties

Name

Description

textColor Property

The text color of the label.

backgroundColor Property

The background color of the label.

lineToGround Property

Boolean. Indicates if the label will have a line from its pivot to the ground.

lineColor Property

If the lineToGround is set to true, this property indicates the line color.

fontName Property

String. The name of the label font.

fontSize Property

A number indicating the font size.

bold Property

Boolean. Indicates if the text is bold.

italic Property

Boolean. Indicates if the text is italic.

underline Property

Boolean. Indicates if the text is underlined.

frameFileName Property

A URL to a file containing frame patterns for the label.

frameIndex Property

Frame pattern index in the frame file.

maxViewingHeight Property

The maximum height, above which the label will not be seen.

minViewingHeight Property

The minimum height, below which the label will not be seen.

textOnImage Property

If the label has both text and image, this property indicates if the text will be over the image or outside the image.

multilineJustification Property

String. Determines the justification of a multiline label.

textAlignment Property

If the label has both text and image, this property determines how the text will be aligned in relation to the image

pivotAlignment Property

Determines the point on the label that will serve as its pivot

lockMode

Normally, a label is always facing the viewer. This property lets the client change this by making the label face in a specific direction or to lie on the terrain surface