They tend to produce unwanted effects when an mIRC code is directly
followed by a text digit (which is going to happen often in this context, e.g.
with git hex commit IDs). the mIRC codes have no end delimiter, so
unless the client's recognizer is very carefully crafted it will eat
following text.
self.filtercmd = None
# Color highlighting is disabled by default.
self.color = None
- self.bold = self.green = self.blue = ""
- self.yellow = self.brown = self.reset = ""
+ self.bold = self.green = self.blue = self.yellow = ""
+ self.brown = self.magenta = self.cyan = self.reset = ""
def activate_color(self, style):
"IRC color codes."
- if style == 'mIRC':
- self.bold = '\x02'
- self.green = '\x033'
- self.blue = '\x032'
- self.yellow = '\x037'
- self.brown = '\x035'
- self.reset = '\x0F'
if style == 'ANSI':
self.bold = '\x1b[1m'
self.green = '\x1b[1;32m'
self.blue = '\x1b[1;34m'
+ self.red = '\x1b[1;31m'
self.yellow = '\x1b[1;33m'
self.brown = '\x1b[33m'
+ self.magenta = '\x1b[35m'
+ self.cyan = '\x1b[36m'
self.reset = '\x1b[0m'
def load_preferences(self, conf):
"Load preferences from a file in the repository root."
<varlistentry>
<term>color</term>
<listitem>
-<para>If "mIRC", highlight notification fields with mIRC color codes.
-If "ANSI", highlight notification fields with ANSI color escape sequences.
+<para>If "ANSI", highlight notification fields with ANSI color escape sequences.
Defaults to "none" (no colors). Note: if you turn this on and
notifications stop appearing on your channel, you need to turn off
IRC's color filter on that channel. To do this you will need op