Skip to main content
Version: Next

OBJECT Get style sheet

OBJECT Get style sheet ( {* ;} object ) : Text

ParameterTypeDescription
*OperatorIf specified, object is an object name (string)
If omitted, object is a field or variable
objectanyObject name (if * is specified) or
Field or variable (if * is omitted)
Function resultTextName of style sheet

This command is not thread-safe, it cannot be used in preemptive code.

Description

The OBJECT Get style sheet command returns the name of the style sheet associated with the object(s) designated by the object and * parameters.

Style sheets may have been assigned in Design mode using the Property List, or for the current process using the OBJECT SET STYLE SHEET command.

Passing the optional * parameter indicates that the object parameter is an object name (string). If you do not pass this parameter, it indicates that the object parameter is a field or variable. In this case, you pass a field or variable reference instead of a string (field or variable object only).

The command can return either:

  • a style sheet name,
  • an empty string ("") if no style sheet is assigned, or
  • if an automatic style sheet is assigned, one of the following constants found in the "Font Styles" theme:
ConstantTypeValueComment
Automatic style sheetText__automatic__Used by default for all objects
Automatic style sheet_additionalText__automatic_additional_text__Supported by static text, fields and variables only. Used for additional text in dialog boxes.
Automatic style sheet_mainText__automatic_main_text__Supported by static text, fields and variables only. Used for main text in dialog boxes.

If the command designates several objects, the style sheet returned is only meaningful if the style sheet is assigned to all of the objects.

Compatibility Note

In project architecture, only the three automatic style sheets are supported by this command.

See also

Font Styles
OBJECT SET STYLE SHEET