/HILITE [pattern [= response]]

Creates a macro which will trigger on text matching pattern and display it with the hilite attribute, optionally executing response.

With no arguments, /hilite sets the flag %{hilite} to 1 (on). This flag enables hilite and other attributes on triggers. It is on by default.

The attribute(s) for hilited text are determined by the %{hiliteattr} variable. The default is bold (hiliteattr=B). Colors are also available (e.g., hiliteattr=Cgreen); see "attributes" and "color" for more information.

The matching style of the hilite pattern is determined by %{matching}. The priority of the hilite is determined by %{hpri}. These variables are examined when the hilite is defined, not when it is executed.

If /hilite does not create a new macro, it returns 0. Otherwise, it returns the number of the new macro (useful in /undefn and /edit).

The standard library also defines /hilite_page and /hilite_whisper which hilite several different commonly used page and whisper formats.

/hilite pattern [=response]
is equivalent to
/def -ah -t"pattern" [=response].


  /hilite {*} tried to kill you!
With the default settings, any line matching that pattern will appear bold.

To hilite messages generated by tf, see hooks.

See: triggers, patterns, attributes, /def, /nohilite, /partial

Back to index
Back to tf home page
Copyright © 1995, 1996, 1997, 1998, 1999, 2002, 2003, 2004, 2005, 2006-2007 Ken Keys