Next: , Previous: , Up: Character Attributes   [Contents][Index]


9.4 Character Attribute Hooks

It is often useful to use the character attribute mechanism as an abstract interface to other information about characters which in fact is stored elsewhere. For example, some implementation of Hemlock might decide to define a Print Representation attribute which controls how a character is displayed on the screen.

To make this easy to do, each attribute has a list of hook functions which are invoked with the attribute, character and new value whenever the current value changes for any reason.

Function: character-attribute-hooks attribute

Return the current hook list for attribute. This may be set with setf. The add-hook and remove-hook macros should be used to manipulate these lists.