IrcII Colorized Formatting
To colorize output in IrcII one uses the "on" filter to match public and private messages, and specifies an action to take, which should be echo in order to actually output the message. Within this action $0 refers to your nick, $1 to the channel and $2- to the words of the message. The formatting codes are as follows:
| Effect | Prefix Value | Format | |------------------+--------------+---------------| | All Off | ^O (\017) | ^O | | Toggle Bold | ^B (\002) | ^B | | Toggle Underline | ^_ (\017) | ^_ | | Toggle Reverse | ^V (\026) | ^V | | Color | ^C (\003) | ^C<fg>[,<bg>] |
For color the <fg> and <bg> are ascii integers the background value is optional. The values for the colors are from mIRC and show in the table below including the ansi values they map to.
Here's an example set of "on" filters to colorize nicks with yours done differently from others. The ^X characters are actual control characters, so you'll need to enter them appropriately (e.g., in vim you can do ctrl-v ctrl-c). Add something like these to your .ircrc file.
set colour on # My messages on ^send_public * if (C == [$0]) \ { echo $Z ^B^C10<$(N)>^O $1- } \ { echo $Z ^B^C10<$(0)>^O $1- } on ^send_msg * echo $Z -> ^B^C10*$(0)*^O $1- # Other's messages on ^public * echo $Z ^B^C2<$(0)>^O $2- on ^msg * echo $Z ^B^C2*$(0)*^O $1-
Color value tables:
| Value | mIRC Colour | ANSI color | |-------+-------------+--------------------| | 0 | White | (15) Light White | | 1 | Black | (0) Black | | 2 | Blue | (4) Blue | | 3 | Green | (2) Green | | 4 | Light Red | (9) Light Red | | 5 | Brown | (1) Red | | 6 | Purple | (5) Magenta | | 7 | Orange | (3) Yellow | | 8 | Yellow | (11) Light Yellow | | 9 | Light Green | (10) Light Green | | 10 | Cyan | (6) Cyan | | 11 | Light Cyan | (14) Light Cyan | | 12 | Light Blue | (12) Light Blue | | 13 | Pink | (13) Light Magenta | | 14 | Gray | (8) Dark Gray | | 15 | Light Gray | (7) White | | | | |
The following table indicates the mIRC color value to use given the ansi name value.
| ANSI Value | mIRC | |-------------+------| | 0 (black) | 1 | | 1 (red) | 5 | | 2 (green) | 3 | | 3 (yellow) | 7 | | 4 (blue) | 2 | | 5 (magenta) | 6 | | 6 (cyan) | 10 | | 7 (white) | 15 | | Bold Value | mIRC | |-------------+------| | 0 (black) | 14 | | 1 (red) | 4 | | 2 (green) | 9 | | 3 (yellow) | 8 | | 4 (blue) | 12 | | 5 (magenta) | 13 | | 6 (cyan) | 11 | | 7 (white) | 0 |
Solarized Colors:
Solarized Name | mIRC | ANSI |
---|---|---|
base03 | 14 | Br. Black |
base02 | 1 | Black |
base01 | 9 | Br. Green |
base00 | 8 | Br. Yellow |
base0 | 12 | Br. Blue |
base1 | 11 | Br. Cyan |
base2 | 15 | White |
base3 | 0 | Br. White |
yellow | 7 | Yellow |
orange | 4 | Br. Red |
red | 5 | Red |
magenta | 6 | Magenta |
violet | 13 | Br. Magenta |
blue | 2 | Blue |
cyan | 10 | Cyan |
green | 3 | Green |