2 * CodePress regular expressions for Perl syntax highlighting
\r
7 { input : /\"(.*?)(\"|<br>|<\/P>)/g, output : '<s>"$1$2</s>' }, // strings double quote
\r
8 { input : /\'(.*?)(\'|<br>|<\/P>)/g, output : '<s>\'$1$2</s>' }, // strings single quote
\r
9 { input : /([\$\@\%]+)([\w\.]*)/g, output : '<a>$1$2</a>' }, // vars
\r
10 { input : /(def\s+)([\w\.]*)/g, output : '$1<em>$2</em>' }, // functions
\r
11 { input : /\b(alias|and|BEGIN|begin|break|case|class|def|defined|do|else|elsif|END|end|ensure|false|for|if|in|module|next|nil|not|or|redo|rescue|retry|return|self|super|then|true|undef|unless|until|when|while|yield)\b/g, output : '<b>$1</b>' }, // reserved words
\r
12 { input : /([\(\){}])/g, output : '<u>$1</u>' }, // special chars
\r
13 { input : /#(.*?)(<br>|<\/P>)/g, output : '<i>#$1</i>$2' } // comments
\r
16 Language.snippets = []
\r
18 Language.complete = [
\r
19 { input : '\'',output : '\'$0\'' },
\r
20 { input : '"', output : '"$0"' },
\r
21 { input : '(', output : '\($0\)' },
\r
22 { input : '[', output : '\[$0\]' },
\r
23 { input : '{', output : '{\n\t$0\n}' }
\r
26 Language.shortcuts = []
\r