Keyword Interface
version 8 by Aaron Reed
Section: Control
As noted above, authors can enable or disable keyword highlighting for any component. Players also have control over emphasis style through the KEYWORD verb, which brings up a menu with flexible options, customized to which keywords are enabled and with instructions for activating a screen reader mode for blind players.
If keywords are a crucial component of your game, you can add the following:
Keywords required is true.
This will bring up a message before your game begins ensuring that players can see the keyword highlighting, and giving them an option to adjust styles.
You can show some stock explanatory text, customized to which keywords are enabled, by using the following phrase, perhaps in the carry out rule for an "about" command:
show KI message for keyword-introduction
To change the default color values at the start of play, authors can use syntax like:
The style of object-word is keyword-cyan.
The four modes are object-word, direction-word, topic-word, and parser-word. For Glulx games, possible styles are keyword-color1-style and keyword-color2-style; for z-code games, they are keyword-red, keyword-green, keyword-yellow, keyword-blue, keyword-magenta, keyword-cyan, keyword-white, and keyword-black. Both VMs provide the additional styles keyword-bold-style, keyword-italics-style, keyword-fixedwidth-style, and keyword-no-style.
To change the Glulx colors, you can adjust g-color1 and g-color2 by amending the Table of Common Color Values-- see the documentation for "Glulx Text Effects" by Emily Short for more information.
Table of Common Color Values (amended)
| glulx color value | assigned number | |
| g-color1 | 15645627 |
All messages the extension prints are customizable by amending the Table of Keyword Interface messages. Open up the extension source to see the full list of messages.