use warnings; use strict; Xchat::register(my$NAME='Focus High', my$VERSION='001', 'Focus Window on Highlight'); Xchat::print("\cB$NAME $VERSION\cb by b0at"); Xchat::hook_print($_, sub { Xchat::command('gui focus'); return Xchat::EAT_NONE; }) for # comment any of these out to remove them 'Channel Action Hilight' , 'Channel Msg Hilight' , 'Private Message' , 'Private Message to Dialog' , 'Notice' ; __END__