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().
Type: PresentationAttributes
consoleLib.currentDisplayAttrs.color = red;
consoleLib.currentDisplayAttrs.highlight=[underline];
consoleLib.currentDisplayAttrs {color = red, highlight=[underline]};
consoleLib.currentDisplayAttrs {color=red};
consoleLib.displayAtPosition("Red text",4,5);
consoleLib.displayAtPosition("White text", 5,5);