45 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
47 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
46 * |
48 * |
47 ************************************************************************************/ |
49 ************************************************************************************/ |
48 |
50 |
49 $language_data = array ( |
51 $language_data = array ( |
50 'LANG_NAME' => 'TCL', |
52 'LANG_NAME' => 'TCL', |
51 'COMMENT_SINGLE' => array(1 => '#'), |
53 'COMMENT_SINGLE' => array(1 => '#'), |
52 'COMMENT_MULTI' => array(), |
54 'COMMENT_MULTI' => array(), |
53 'CASE_KEYWORDS' => GESHI_CAPS_NO_CHANGE, |
55 'COMMENT_REGEXP' => array( |
54 'QUOTEMARKS' => array('"', "'"), |
56 1 => '/(?<!\\\\)#(?:\\\\\\\\|\\\\\\n|.)*$/m', |
55 'ESCAPE_CHAR' => '\\', |
57 2 => '/{[^}\n]+}/' |
56 'KEYWORDS' => array( |
58 ), |
|
59 'CASE_KEYWORDS' => GESHI_CAPS_NO_CHANGE, |
|
60 'QUOTEMARKS' => array('"', "'"), |
|
61 'ESCAPE_CHAR' => '\\', |
|
62 'KEYWORDS' => array( |
|
63 /* |
|
64 * Set 1: reserved words |
|
65 * http://python.org/doc/current/ref/keywords.html |
|
66 */ |
|
67 1 => array( |
|
68 'proc', 'global', 'upvar', 'if', 'then', 'else', 'elseif', 'for', 'foreach', |
|
69 'break', 'continue', 'while', 'set', 'eval', 'case', 'in', 'switch', |
|
70 'default', 'exit', 'error', 'return', 'uplevel', 'loop', |
|
71 'for_array_keys', 'for_recursive_glob', 'for_file', 'unwind_protect', |
|
72 'expr', 'catch', 'namespace', 'rename', 'variable', |
|
73 // itcl |
|
74 'method', 'itcl_class', 'public', 'protected'), |
57 |
75 |
58 /* |
76 /* |
59 ** Set 1: reserved words |
77 * Set 2: builtins |
60 ** http://python.org/doc/current/ref/keywords.html |
78 * http://asps.activatestate.com/ASPN/docs/ActiveTcl/8.4/tcl/tcl_2_contents.htm |
61 */ |
79 */ |
62 1 => array( |
80 2 => array( |
63 'proc', 'global', 'upvar', 'if', 'then', 'else', 'elseif', 'for', 'foreach', |
81 // string handling |
64 'break', 'continue', 'while', 'set', 'eval', 'case', 'in', 'switch', |
82 'append', 'binary', 'format', 're_syntax', 'regexp', 'regsub', |
65 'default', 'exit', 'error', 'proc', 'return', 'uplevel', 'loop', |
83 'scan', 'string', 'subst', |
66 'for_array_keys', 'for_recursive_glob', 'for_file', 'unwind_protect', |
84 // list handling |
67 'expr', 'catch', 'namespace', 'rename', 'variable', |
85 'concat', 'join', 'lappend', 'lindex', 'list', 'llength', 'lrange', |
68 // itcl |
86 'lreplace', 'lsearch', 'lset', 'lsort', 'split', |
69 'method', 'itcl_class', 'public', 'protected'), |
87 // procedures and output |
|
88 'incr', 'close', 'eof', 'fblocked', 'fconfigure', 'fcopy', 'file', |
|
89 'fileevent', 'flush', 'gets', 'open', 'puts', 'read', 'seek', |
|
90 'socket', 'tell', |
|
91 // packages and source files |
|
92 'load', 'loadTk', 'package', 'pgk::create', 'pgk_mkIndex', 'source', |
|
93 // interpreter routines |
|
94 'bgerror', 'history', 'info', 'interp', 'memory', 'unknown', |
|
95 // library routines |
|
96 'enconding', 'http', 'msgcat', |
|
97 // system related |
|
98 'cd', 'clock', 'exec', 'glob', 'pid', 'pwd', 'time', |
|
99 // platform specified |
|
100 'dde', 'registry', 'resource', |
|
101 // special variables |
|
102 '$argc', '$argv', '$errorCode', '$errorInfo', '$argv0', |
|
103 '$auto_index', '$auto_oldpath', '$auto_path', '$env', |
|
104 '$tcl_interactive', '$tcl_libpath', '$tcl_library', |
|
105 '$tcl_pkgPath', '$tcl_platform', '$tcl_precision', '$tcl_traceExec', |
|
106 ), |
70 |
107 |
71 /* |
108 /* |
72 ** Set 2: builtins |
109 * Set 3: standard library |
73 ** http://asps.activatestate.com/ASPN/docs/ActiveTcl/8.4/tcl/tcl_2_contents.htm |
110 */ |
74 */ |
111 3 => array( |
75 2 => array( |
112 'comment', 'filename', 'library', 'packagens', 'tcltest', 'tclvars', |
76 // string handling |
113 ), |
77 'append', 'binary', 'format', 're_syntax', 'regexp', 'regsub', |
|
78 'scan', 'string', 'subst', |
|
79 // list handling |
|
80 'concat', 'join', 'lappend', 'lindex', 'list', 'llength', 'lrange', |
|
81 'lreplace', 'lsearch', 'lset', 'lsort', 'split', |
|
82 // math |
|
83 'expr', |
|
84 // procedures and output |
|
85 'incr', 'close', 'eof', 'fblocked', 'fconfigure', 'fcopy', 'file', |
|
86 'fileevent', 'flush', 'gets', 'open', 'puts', 'read', 'seek', |
|
87 'socket', 'tell', |
|
88 // packages and source files |
|
89 'load', 'loadTk', 'package', 'pgk::create', 'pgk_mkIndex', 'source', |
|
90 // interpreter routines |
|
91 'bgerror', 'history', 'info', 'interp', 'memory', 'unknown', |
|
92 // library routines |
|
93 'enconding', 'http', 'msgcat', |
|
94 // system related |
|
95 'cd', 'clock', 'exec', 'exit', 'glob', 'pid', 'pwd', 'time', |
|
96 // platform specified |
|
97 'dde', 'registry', 'resource', |
|
98 // special variables |
|
99 '$argc', '$argv', '$errorCode', '$errorInfo', '$argv0', |
|
100 '$auto_index', '$auto_oldpath', '$auto_path', '$env', |
|
101 '$tcl_interactive', '$tcl_libpath', '$tcl_library', |
|
102 '$tcl_pkgPath', '$tcl_platform', '$tcl_precision', '$tcl_traceExec', |
|
103 ), |
|
104 |
114 |
105 /* |
115 /* |
106 ** Set 3: standard library |
116 * Set 4: special methods |
107 */ |
117 */ |
108 3 => array( |
118 // 4 => array( |
109 'comment', 'dde', 'filename', 'http', 'library', 'memory', |
119 // ) |
110 'packagens', 'registry', 'resource', 'tcltest', 'tclvars', |
|
111 ), |
|
112 |
120 |
113 /* |
121 ), |
114 ** Set 4: special methods |
122 'SYMBOLS' => array( |
115 */ |
123 '(', ')', '[', ']', '{', '}', '$', '*', '&', '%', '!', ';', '<', '>', '?' |
116 4 => array( |
124 ), |
117 ) |
125 'CASE_SENSITIVE' => array( |
118 |
126 GESHI_COMMENTS => false, |
119 ), |
127 1 => true, |
120 'SYMBOLS' => array( |
|
121 '(', ')', '[', ']', '{', '}', '$', '*', '&', '%', '!', ';', '<', '>', '?' |
|
122 ), |
|
123 'CASE_SENSITIVE' => array( |
|
124 GESHI_COMMENTS => true, |
|
125 1 => true, |
|
126 2 => true, |
128 2 => true, |
127 3 => true, |
129 3 => true, |
128 4 => true |
130 // 4 => true |
129 ), |
131 ), |
130 'STYLES' => array( |
132 'STYLES' => array( |
131 'KEYWORDS' => array( |
133 'KEYWORDS' => array( |
132 1 => 'color: #ff7700;font-weight:bold;', // Reserved |
134 1 => 'color: #ff7700;font-weight:bold;', // Reserved |
133 2 => 'color: #008000;', // Built-ins + self |
135 2 => 'color: #008000;', // Built-ins + self |
134 3 => 'color: #dc143c;', // Standard lib |
136 3 => 'color: #dc143c;', // Standard lib |
135 4 => 'color: #0000cd;' // Special methods |
137 // 4 => 'color: #0000cd;' // Special methods |
136 ), |
138 ), |
137 'COMMENTS' => array( |
139 'COMMENTS' => array( |
138 1 => 'color: #808080; font-style: italic;', |
140 1 => 'color: #808080; font-style: italic;', |
139 'MULTI' => 'color: #808080; font-style: italic;' |
141 2 => 'color: #483d8b;', |
140 ), |
142 'MULTI' => 'color: #808080; font-style: italic;' |
141 'ESCAPE_CHAR' => array( |
143 ), |
142 0 => 'color: #000099; font-weight: bold;' |
144 'ESCAPE_CHAR' => array( |
143 ), |
145 0 => 'color: #000099; font-weight: bold;' |
144 'BRACKETS' => array( |
146 ), |
145 0 => 'color: black;' |
147 'BRACKETS' => array( |
146 ), |
148 0 => 'color: black;' |
147 'STRINGS' => array( |
149 ), |
148 0 => 'color: #483d8b;' |
150 'STRINGS' => array( |
149 ), |
151 0 => 'color: #483d8b;' |
150 'NUMBERS' => array( |
152 ), |
151 0 => 'color: #ff4500;' |
153 'NUMBERS' => array( |
152 ), |
154 0 => 'color: #ff4500;' |
153 'METHODS' => array( |
155 ), |
154 1 => 'color: black;' |
156 'METHODS' => array( |
155 ), |
157 1 => 'color: black;' |
156 'SYMBOLS' => array( |
158 ), |
157 0 => 'color: #66cc66;' |
159 'SYMBOLS' => array( |
158 ), |
160 0 => 'color: #66cc66;' |
159 'REGEXPS' => array( |
161 ), |
|
162 'REGEXPS' => array( |
160 0 => 'color: #ff3333;' |
163 0 => 'color: #ff3333;' |
161 ), |
164 ), |
162 'SCRIPT' => array( |
165 'SCRIPT' => array( |
163 ) |
166 ) |
164 ), |
167 ), |
165 'URLS' => array( |
168 'URLS' => array( |
166 ), |
169 1 => '', |
167 'OOLANG' => true, |
170 2 => '', |
168 'OBJECT_SPLITTERS' => array( |
171 3 => '', |
169 1 => '::' |
172 // 4 => '' |
170 ), |
173 ), |
171 'REGEXPS' => array( |
174 'OOLANG' => true, |
172 0 => '[\\$]+[a-zA-Z_][a-zA-Z0-9_]*', |
175 'OBJECT_SPLITTERS' => array( |
173 ), |
176 1 => '::' |
174 'STRICT_MODE_APPLIES' => GESHI_NEVER, |
177 ), |
175 'SCRIPT_DELIMITERS' => array( |
178 'REGEXPS' => array( |
176 ), |
179 //Special variables |
177 'HIGHLIGHT_STRICT_BLOCK' => array( |
180 0 => '[\\$]+[a-zA-Z_][a-zA-Z0-9_]*', |
178 ) |
181 ), |
|
182 'STRICT_MODE_APPLIES' => GESHI_NEVER, |
|
183 'SCRIPT_DELIMITERS' => array( |
|
184 ), |
|
185 'HIGHLIGHT_STRICT_BLOCK' => array( |
|
186 ), |
|
187 'PARSER_CONTROL' => array( |
|
188 'COMMENTS' => array( |
|
189 'DISALLOWED_BEFORE' => '\\' |
|
190 ) |
|
191 ) |
179 ); |
192 ); |
180 |
193 |
181 ?> |
194 ?> |