From: Dan Boger Date: Tue, 17 Feb 2009 04:51:49 +0000 (-0800) Subject: r476 - v2.0.4 - Fix #topics hilights X-Git-Url: https://git.sommitrealweird.co.uk/twirssi-net-twitter-lite.git/commitdiff_plain/a4096004424ab94a9b48fe240cefe1aada290581?ds=inline r476 - v2.0.4 - Fix #topics hilights --- diff --git a/twirssi.pl b/twirssi.pl index b4094ad..27d4960 100644 --- a/twirssi.pl +++ b/twirssi.pl @@ -11,8 +11,8 @@ $Data::Dumper::Indent = 1; use vars qw($VERSION %IRSSI); -$VERSION = "2.0.3"; -my ($REV) = '$Rev: 475 $' =~ /(\d+)/; +$VERSION = "2.0.4"; +my ($REV) = '$Rev: 476 $' =~ /(\d+)/; %IRSSI = ( authors => 'Dan Boger', contact => 'zigdon@gmail.com', @@ -21,7 +21,7 @@ my ($REV) = '$Rev: 475 $' =~ /(\d+)/; . 'Can optionally set your bitlbee /away message to same', license => 'GNU GPL v2', url => 'http://twirssi.com', - changed => '$Date: 2009-02-16 20:36:03 -0800 (Mon, 16 Feb 2009) $', + changed => '$Date: 2009-02-16 20:50:17 -0800 (Mon, 16 Feb 2009) $', ); my $window; @@ -1099,11 +1099,12 @@ sub hilight { if ( Irssi::settings_get_str("twirssi_nick_color") ) { my $c = Irssi::settings_get_str("twirssi_nick_color"); $c = $irssi_to_mirc_colors{$c}; - $text =~ s/(^|\W)\@([-\w]+)/$1\cC$c\@$2\cO/g; + $text =~ s/(^|\W)\@([-\w]+)/$1\cC$c\@$2\cO/g if $c; } if ( Irssi::settings_get_str("twirssi_topic_color") ) { my $c = Irssi::settings_get_str("twirssi_topic_color"); - $text =~ s/(^|\W)\#([-\w]+)/$1\cC$c\#$2\cO/g; + $c = $irssi_to_mirc_colors{$c}; + $text =~ s/(^|\W)\#([-\w]+)/$1\cC$c\#$2\cO/g if $c; } $text =~ s/[\n\r]/ /g;