Colors and Styles (Stand-alone GNU Info 6.8)

Next: Customizing Key Bindings and Variables, Previous: Manipulating Variables, Up: Stand-alone GNU Info [Contents][Index]

## 13 Colors and Styles

You can choose to highlight parts of Info’s display, such as cross-references and search matches, using a variety of styles, including colors, boldface and underline. Here are the variables that are available to do this:

`link-style` ¶

  Used for cross-references and menu entries.

`active-link-style` ¶

  Used for a cross-reference or menu entry when typing `RET` would have the effect of following said cross-reference or menu entry.

`match-style` ¶

  Used for matches from a search command. (See Searching an Info File.)

Each of these is given in the `.infokey` file just as the variables in the previous chapter. Their values are a comma-separated list of values in the following table:

`black` ¶
`red`
`green`
`yellow`
`blue`
`magenta`
`cyan`
`white`

  Use the color specified for text.

`nocolor`
`nocolour`

  Turn off any color that was in effect, using the terminal’s default color.

`bgblack` ¶
`bgred`
`bggreen`
`bgyellow`
`bgblue`
`bgmagenta`
`bgcyan`
`bgwhite`

  Use the color specified for the background.

`bgnocolor`
`bgnocolour`

  Use the terminal’s default background color.

`underline` ¶
`nounderline`

  Turn text underline on or off.

`standout`
`nostandout`

  Turn ‘standout mode’ on or off. Standout mode entails the use of appearance modes that make text stand out, and varies between terminals.

`bold` ¶
`regular`
`nobold`

  Turn boldface on or off.

`blink` ¶
`noblink`

  Make the text blink, or not.

Here is an sample excerpt from an `.infokey` file:

    #var
    link-style=yellow
    active-link-style=yellow,bold
    match-style=underline,bold,nocolor

With this, cross-references are all yellow, and active cross-references are additionally displayed in bold. Any search matches will be shown in bold, and underlined. Moreover, if there is a search match inside a cross-reference, the ‘`nocolor`’ rendition style will cancel the yellow color, leaving the text in the match the terminal’s default color. (Note, however, that the rendition styles for active cross-references take priority over those for search matches, so search matches there will still be displayed in yellow.)

Next: Customizing Key Bindings and Variables, Previous: Manipulating Variables, Up: Stand-alone GNU Info [Contents][Index]