~ubuntu-branches/ubuntu/trusty/yelp-xsl/trusty

« back to all changes in this revision

Viewing changes to js/jquery.syntax.brush.perl5.js

  • Committer: Bazaar Package Importer
  • Author(s): Michael Terry
  • Date: 2011-07-09 10:02:21 UTC
  • mto: (11.1.1 experimental) (1.3.1)
  • mto: This revision was merged to the branch mainline in revision 13.
  • Revision ID: james.westby@ubuntu.com-20110709100221-27hsncxrd63leyx4
Tags: upstream-3.1.2
ImportĀ upstreamĀ versionĀ 3.1.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
// brush: "perl5" aliases: []
2
2
 
3
 
//      This file is part of the "jQuery.Syntax" project, and is licensed under the GNU AGPLv3.
4
 
//      Copyright 2010 Samuel Williams. All rights reserved.
 
3
//      This file is part of the "jQuery.Syntax" project, and is distributed under the MIT License.
 
4
//      Copyright (c) 2011 Samuel G. D. Williams. <http://www.oriontransfer.co.nz>
5
5
//      See <jquery.syntax.js> for licensing details.
6
6
 
7
7
Syntax.register('perl5', function(brush) {
18
18
        brush.push(operators, {klass: 'operator'});
19
19
        brush.push(builtins, {klass: 'function'});
20
20
        
 
21
        // Regular expressions
 
22
        brush.push(Syntax.lib.perlStyleRegularExpressions);
 
23
        
21
24
        // Comments
22
25
        brush.push(Syntax.lib.perlStyleComment);
23
26
        brush.push(Syntax.lib.webLink);
27
30
                pattern: /(\$|@|%)\w+/gi,
28
31
                klass: 'variable'
29
32
        });
30
 
                
 
33
        
 
34
        // Enddoc
 
35
        brush.push({
 
36
                pattern: /__END__[\s\S]*/gm,
 
37
                klass: 'comment'
 
38
        });
 
39
        
31
40
        // Strings
32
41
        brush.push(Syntax.lib.singleQuotedString);
33
42
        brush.push(Syntax.lib.doubleQuotedString);