1 package Xchat::VPIT::Highlight;
8 use lib get_info 'xchatdir';
10 use Xchat::XPI::Events qw<filter>;
11 use Xchat::XPI::Utils qw<irc_lc gui>;
13 our $VERSION = '0.04';
17 hook_print 'Private Message to Dialog', sub {
23 '#cpantesters' => [ qw<
24 Acme-CPANAuthors-You-re_using
31 Perl-Critic-Policy-Dynamic-NoIndirect
50 my $rx = '(?:' . join('|', @{$hl{$_}}) . ')';
54 filter 'Channel Action' => sub {
55 my $chan = irc_lc get_info 'channel';
56 if ($hl{$chan} and $_[1] =~ /$hl{$chan}/) {
62 } => 'Channel Action Hilight';
71 my $rx = '(?:' . join('|', @{$skip{$_}}) . ')';
75 filter 'Channel Action Hilight' => sub {
76 my $chan = irc_lc get_info 'channel';
77 if ($skip{$chan} and $_[1] =~ /$skip{$chan}/) {
83 } => 'Channel Action';
85 $ph = Xchat::XPI->new(
86 name => 'Smart highlighting',
88 desc => 'Highlight on private messages',
89 author => 'Vincent Pit (VPIT)',
90 email => 'perl@profvince.com',
91 url => 'http://www.profvince.com',