3 # Template::Toolkit syntax file
7 keyword &\[abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ\]; brightgreen
8 keyword &#\{xX\}\[0123456789abcdefABCDEF\]; brightgreen
9 keyword &#\[0123456789\]; brightgreen
11 # Although TT is most often used to generate HTML, it's not *only* used for that, so assuming HTML around it may be presumptuous anyway.
12 # Since cooledit doesn't support sub-context, we can't have TT *in* HTML, like <img src="[% image_url %]">
13 # The best possible workaround, which still sucks, is to uncomment the line below, which will highlight any HTML tags that don't contain a '[', but without special highlight for strings, and without any HTML-specific keywords
14 # keyword <\[abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ01234567890\s"#$%&'()*+,-.=?@\\\]^_`{|}~\]> green
17 # TT directives - http://template-toolkit.org/docs/manual/Directives.html
18 context [% %] red black
19 keyword whole GET yellow
20 keyword whole CALL yellow
21 keyword whole SET yellow
22 keyword whole DEFAULT yellow
24 keyword whole INSERT yellow
25 keyword whole INCLUDE yellow
26 keyword whole PROCESS yellow
27 keyword whole WRAPPER yellow
28 keyword whole BLOCK yellow
30 keyword whole IF yellow
31 keyword whole UNLESS yellow
32 keyword whole ELSIF yellow
33 keyword whole ELSE yellow
34 keyword whole SWITCH yellow
35 keyword whole CASE yellow
37 keyword whole FOREACH yellow
38 keyword whole IN yellow
39 keyword whole WHILE yellow
41 keyword whole FILTER yellow
42 keyword whole USE yellow
43 keyword whole MACRO yellow
44 keyword whole PERL yellow
45 keyword whole RAWPERL yellow
47 keyword whole TRY yellow
48 keyword whole THROW yellow
49 keyword whole CATCH yellow
50 keyword whole FINAL yellow
52 keyword whole NEXT yellow
53 keyword whole LAST yellow
54 keyword whole RETURN yellow
55 keyword whole STOP yellow
56 keyword whole CLEAR yellow
57 keyword whole META yellow
58 keyword whole TAGS yellow
59 keyword whole DEBUG yellow
61 keyword whole END yellow
63 # AND, OR and NOT are apparently not documented
64 keyword whole AND white
65 keyword whole OR white
66 keyword whole NOT white
69 # TT VMethods - http://template-toolkit.org/docs/manual/VMethods.html
70 keyword .defined brown
73 keyword .replace brown
97 keyword .reverse brown
100 keyword .unshift brown
104 keyword .unique brown
107 keyword .splice brown
110 keyword '*' brightgreen
113 context <!-- --> brown
117 context <! > brightred/orange
121 context </ > brightcyan
123 # HTML open tags - enabling this will hide TT syntax in HTML, e.g. <img src="[% image_url %]">
124 #context < > brightcyan