currentDisplayAttrs (EGL system variable)

You can use the consoleLib.currentDisplayAttrs system variable to specify display characteristics for the next text displayed after the variable has been set. After the text is displayed, the specified attributes return to their previous values.

The consoleLib.currentDisplayAttrs variable works with the various "display" functions in consoleLib, such as consoleLib.displayAtLine() or consoleLib.displayAtPosition().

You can set the following properties for the consoleLib.currentDisplayAttrs variable: For more information, see the topics for the individual properties.

Type: PresentationAttributes

Example

You can set the properties using dot syntax:
consoleLib.currentDisplayAttrs.color = red;
consoleLib.currentDisplayAttrs.highlight=[underline];
Alternatively, you can use a set-values block to set all properties in a single statement:
consoleLib.currentDisplayAttrs {color = red, highlight=[underline]};
The specified attributes persist only through the next "display" function. In the following code, the first text is in red, the second in the default color for the window (here assumed to be white):
consoleLib.currentDisplayAttrs {color=red};
consoleLib.displayAtPosition("Red text",4,5);
consoleLib.displayAtPosition("White text", 5,5);

Feedback