Tk::TextHighlight::Perl - a Plugin for Perl syntax highlighting
Tk::TextHighlight::PerlCool inherits Syntax::Highlight::Perl;
use Tk; require Tk::TextHighlight; my $m = new MainWindow; my $e = $m->Scrolled("TextHighlight", -syntax => "PerlCool", -scrollbars => "se", -background => "black", )->pack(-expand => 1, -fill => "both"); $m->MainLoop;
For its limitations see also there. This module provides extra methods to provide syntax highlighting for the Perl programming language.
returns a list of string snippets and tags that can be inserted in a Tk::Text like widget instantly.
sets and returns a reference to a list of tagnames and options. By default it is set to:
[ ['DEFAULT', -foreground => 'black'], ['Comment_Normal', -foreground => 'lightblue'], ['Comment_Pod', -foreground => 'lightblue'], ['Directive', -foreground => 'darkgreen'], ['Label', -foreground => 'black'], ['Quote', -foreground => 'green'], ['String', -foreground => 'green'], ['Variable_Scalar', -foreground => 'blue'], ['Variable_Array', -foreground => 'blue'], ['Variable_Hash', -foreground => 'blue'], ['Subroutine', -foreground => 'cyan'], ['Character', -foreground => 'magenta'], ['Keyword', -foreground => 'darkgreen'], ['Builtin_Operator', -foreground => 'darkred'], ['Operator', -foreground => 'darkgreen'], ['Number', -foreground => 'yellow'], ]
Used internally. Don't call it yourself.
Compares @state to the current state of the formatter. returns true when equal.
Returns a list of the current state of the formatter. Called by the highlighting routines in Tk::TextHighlight.
Sets the state of the formatter. Called by the highlighting routines in Tk::TextHighlight.
Original CodeText Author: Hans Jeuken (haje@toneel.demon.nl)
TextHighlight Author: Jim Turner (turnerjw784@mesh.net)
Propably plenty
To install Tk::TextHighlight, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Tk::TextHighlight
CPAN shell
perl -MCPAN -e shell install Tk::TextHighlight
For more information on module installation, please visit the detailed CPAN module installation guide.