Class: Label
Prev
Next

Class: Label

A text label.

Inherits: BorderedViewObject

Collection class: ViewObjectCollection

Constructors:

Methods:

Properties:

Label ( ViewObject parent )

  • ViewObject parent - The parent to place the new label in. May also be a string containing the name of an existing ViewObject.

Creates a new label and places it in the ViewObject parent.

Label ( Window window )

  • Window window - The window to place the new label in. May also be a string containing the name of an existing Window.

Creates a new label and places it in the Window window.

void adjustSizeForText ( )

Adjusts the size of the label to fit the text.

string text

Contains the text contents of the label. This may include carriage returns (\n), scalar references of the form [scalar_name], and some basic LaTeX.

string font

Used to set or get the current font used for the label.

number fontSize

Contains the size of the font used to draw the label.

number rotation

Contains the rotation angle of the label. Rotation is clockwise from normal and is stored in degrees.

number dataPrecision

Contains the number of digits of precision to display data values in the label. Restricted to a value between 0 and 16 inclusive.

boolean interpreted

Determines if the contents of the label should be interpreted in order to substitute LaTeX-like constructs. Default is true.

boolean scalarReplacement

Determines if the contents of the label should be interpreted in order to substitute variable reference constructs. Default is true.

boolean autoResize [Obsolete]

Automatically resizes the label to fit the text exactly. May trigger a slight move of the label. It will not automatically resize if the user resizes it manually via the size property or layout mode.

Prev
Next
Home


Would you like to make a comment or contribute an update to this page?
Send feedback to the KDE Docs Team