ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
HFile_lpc.php
Go to the documentation of this file.
1 <?php
2 $BEAUT_PATH = realpath(".") . "/Services/COPage/syntax_highlight/php";
3 if (!isset($BEAUT_PATH)) {
4  return;
5 }
6 require_once("$BEAUT_PATH/Beautifier/HFile.php");
7  class HFile_lpc extends HFile
8  {
9  public function HFile_lpc()
10  {
11  $this->HFile();
12  /*************************************/
13  // Beautifier Highlighting Configuration File
14  // LPC
15  /*************************************/
16  // Flags
17 
18  $this->nocase = "0";
19  $this->notrim = "0";
20  $this->perl = "0";
21 
22  // Colours
23 
24  $this->colours = array("blue", "purple", "gray", "brown", "blue", "purple", "gray");
25  $this->quotecolour = "blue";
26  $this->blockcommentcolour = "green";
27  $this->linecommentcolour = "green";
28 
29  // Indent Strings
30 
31  $this->indent = array("{");
32  $this->unindent = array("}");
33 
34  // String characters and delimiters
35 
36  $this->stringchars = array("\"");
37  $this->delimiters = array("~", "!", "@", "%", "^", "&", "*", "(", ")", "[", "]", "{", "}", "-", "+", "=", "|", "\\", "/", ":", ";", "\"", "'", "<", ">", " ", ",", " ", ".", "?");
38  $this->escchar = "";
39 
40  // Comment settings
41 
42  $this->linecommenton = array("//");
43  $this->blockcommenton = array("/*");
44  $this->blockcommentoff = array("*/");
45 
46  // Keywords (keyword mapping to colour number)
47 
48  $this->keywords = array(
49  "array" => "1",
50  "class" => "1",
51  "double" => "1",
52  "float" => "1",
53  "function" => "1",
54  "int" => "1",
55  "mixed" => "1",
56  "mapping" => "1",
57  "nomask" => "1",
58  "object" => "1",
59  "public" => "1",
60  "private" => "1",
61  "static" => "1",
62  "string" => "1",
63  "void" => "1",
64  "varargs" => "1",
65  "break" => "2",
66  "case" => "2",
67  "continue" => "2",
68  "default" => "2",
69  "do" => "2",
70  "else" => "2",
71  "for" => "2",
72  "foreach" => "2",
73  "if" => "2",
74  "in" => "2",
75  "return" => "2",
76  "switch" => "2",
77  "while" => "2",
78  "abs" => "3",
79  "absolute_path" => "3",
80  "adlog_file" => "3",
81  "adminlist" => "3",
82  "adminp" => "3",
83  "arch" => "3",
84  "assure_save_dir" => "3",
85  "assure_user_save_dir" => "3",
86  "base_name" => "3",
87  "cat" => "3",
88  "clone_object" => "4",
89  "creator_file" => "3",
90  "data_dir" => "3",
91  "data_file" => "3",
92  "debug_info" => "4",
93  "directory_exists" => "3",
94  "exclude_array" => "3",
95  "exclude_element" => "3",
96  "exec" => "3",
97  "expand" => "3",
98  "export_uid" => "4",
99  "extract" => "3",
100  "file_exists" => "3",
101  "filter" => "4",
102  "find_items" => "3",
103  "find_short" => "3",
104  "first_inventory" => "3",
105  "format_string" => "3",
106  "format_time" => "3",
107  "get_logdir" => "3",
108  "get_logdir_logname" => "3",
109  "get_logfile" => "3",
110  "get_object" => "3",
111  "get_objects" => "3",
112  "getoid" => "3",
113  "gettype" => "3",
114  "hiddenp" => "3",
115  "identify" => "3",
116  "int_string" => "3",
117  "intl_date_stamp" => "3",
118  "log_file" => "3",
119  "max" => "3",
120  "maxelt" => "3",
121  "min" => "3",
122  "minelt" => "3",
123  "mkdirs" => "3",
124  "mud_name" => "3",
125  "mud_port" => "3",
126  "mudlib_name" => "3",
127  "mudlib_version" => "3",
128  "next_inventory" => "3",
129  "objective" => "3",
130  "possessive" => "3",
131  "ppossessive" => "3",
132  "previous_living" => "3",
133  "process_string" => "3",
134  "process_value" => "3",
135  "query_snoop" => "3",
136  "query_snooping" => "3",
137  "reduce_to_tilde_path" => "3",
138  "seniorlist" => "3",
139  "seniorp" => "3",
140  "set_default_fail_msg" => "3",
141  "set_eval_limit" => "4",
142  "shadowp" => "3",
143  "shutdown" => "3",
144  "snoop" => "3",
145  "sorted_inventory" => "3",
146  "strtype" => "3",
147  "subjective" => "3",
148  "sumofarr" => "3",
149  "tail" => "3",
150  "temp_file" => "3",
151  "testcharp" => "3",
152  "transfer" => "3",
153  "trim_spaces" => "3",
154  "trimpath" => "3",
155  "uniq_array" => "3",
156  "update_file" => "3",
157  "user_data_dir" => "3",
158  "user_data_file" => "3",
159  "user_path" => "3",
160  "userp" => "3",
161  "version" => "3",
162  "wizardp" => "3",
163  "wrap" => "3",
164  "write_log_file" => "3",
165  "allocate" => "4",
166  "allocate_buffer" => "4",
167  "acos" => "4",
168  "asin" => "4",
169  "atan" => "4",
170  "add_action" => "4",
171  "allocate_mapping" => "4",
172  "arrayp" => "4",
173  "author_stats" => "4",
174  "all_inventory" => "4",
175  "all_previous_objects" => "4",
176  "bind" => "4",
177  "bufferp" => "4",
178  "crc32" => "4",
179  "call_other" => "4",
180  "call_out" => "4",
181  "call_stack" => "4",
182  "catch" => "4",
183  "cp" => "4",
184  "ceil" => "4",
185  "cos" => "4",
186  "copy" => "4",
187  "command" => "4",
188  "commands" => "4",
189  "cache_stats" => "4",
190  "classp" => "4",
191  "children" => "4",
192  "clonep" => "4",
193  "capitalize" => "4",
194  "clear_bit" => "4",
195  "crypt" => "4",
196  "call_out_info" => "4",
197  "check_memory" => "4",
198  "ctime" => "4",
199  "disable_commands" => "4",
200  "disable_wizard" => "4",
201  "debugmalloc" => "4",
202  "dump_file_descriptors" => "4",
203  "dump_prog" => "4",
204  "dump_socket_status" => "4",
205  "dumpallobj" => "4",
206  "domain_stats" => "4",
207  "deep_inventory" => "4",
208  "destruct" => "4",
209  "deep_inherit_list" => "4",
210  "evaluate" => "4",
211  "exp" => "4",
212  "ed" => "4",
213  "ed_cmd" => "4",
214  "ed_start" => "4",
215  "enable_commands" => "4",
216  "enable_wizard" => "4",
217  "environment" => "4",
218  "explode" => "4",
219  "error" => "4",
220  "eval_cost" => "4",
221  "external_start" => "4",
222  "filter_array" => "4",
223  "file_length" => "4",
224  "file_name" => "4",
225  "file_size" => "4",
226  "floor" => "4",
227  "function_owner" => "4",
228  "fetch_variable" => "4",
229  "find_player" => "4",
230  "filter_mapping" => "4",
231  "floatp" => "4",
232  "functionp" => "4",
233  "find_living" => "4",
234  "find_object" => "4",
235  "find_call_out" => "4",
236  "flush_messages" => "4",
237  "function_exists" => "4",
238  "function_profile" => "4",
239  "functions" => "4",
240  "generate_source" => "4",
241  "get_dir" => "4",
242  "get_char" => "4",
243  "get_config" => "4",
244  "geteuid" => "4",
245  "getuid" => "4",
246  "heart_beat_info" => "4",
247  "heart_beats" => "4",
248  "in_edit" => "4",
249  "in_input" => "4",
250  "input_to" => "4",
251  "interactive" => "4",
252  "intp" => "4",
253  "implode" => "4",
254  "inherit_list" => "4",
255  "inherits" => "4",
256  "keys" => "4",
257  "link" => "4",
258  "log" => "4",
259  "living" => "4",
260  "livings" => "4",
261  "load_object" => "4",
262  "lower_case" => "4",
263  "localtime" => "4",
264  "lpc_info" => "4",
265  "map_array" => "4",
266  "member_array" => "4",
267  "mkdir" => "4",
268  "map" => "4",
269  "message" => "4",
270  "malloc_status" => "4",
271  "memory_info" => "4",
272  "mud_status" => "4",
273  "map_delete" => "4",
274  "map_mapping" => "4",
275  "match_path" => "4",
276  "mapp" => "4",
277  "master" => "4",
278  "move_object" => "4",
279  "max_eval_cost" => "4",
280  "memory_summary" => "4",
281  "new" => "4",
282  "notify_fail" => "4",
283  "named_livings" => "4",
284  "origin" => "4",
285  "opcprof" => "4",
286  "objectp" => "4",
287  "objects" => "4",
288  "previous_object" => "4",
289  "pow" => "4",
290  "printf" => "4",
291  "pointerp" => "4",
292  "present" => "4",
293  "pluralize" => "4",
294  "program_info" => "4",
295  "query_shadowing" => "4",
296  "query_ed_mode" => "4",
297  "query_host_name" => "4",
298  "query_idle" => "4",
299  "query_ip_name" => "4",
300  "query_ip_number" => "4",
301  "query_ip_port" => "4",
302  "query_notify_fail" => "4",
303  "query_verb" => "4",
304  "query_load_average" => "4",
305  "query_privs" => "4",
306  "query_heart_beat" => "4",
307  "read_buffer" => "4",
308  "remove_call_out" => "4",
309  "remove_shadow" => "4",
310  "read_bytes" => "4",
311  "read_file" => "4",
312  "rename" => "4",
313  "rm" => "4",
314  "rmdir" => "4",
315  "restore_variable" => "4",
316  "receive" => "4",
317  "remove_action" => "4",
318  "remove_interactive" => "4",
319  "resolve" => "4",
320  "refs" => "4",
321  "rusage" => "4",
322  "random" => "4",
323  "reload_object" => "4",
324  "restore_object" => "4",
325  "reg_assoc" => "4",
326  "regexp" => "4",
327  "repeat_string" => "4",
328  "replace_string" => "4",
329  "reclaim_objects" => "4",
330  "replace_program" => "4",
331  "replaceable" => "4",
332  "reset_eval_cost" => "4",
333  "sort_array" => "4",
334  "shadow" => "4",
335  "stat" => "4",
336  "sin" => "4",
337  "sqrt" => "4",
338  "save_variable" => "4",
339  "sizeof" => "4",
340  "store_variable" => "4",
341  "say" => "4",
342  "set_this_player" => "4",
343  "shout" => "4",
344  "set_debug_level" => "4",
345  "set_malloc_mask" => "4",
346  "swap" => "4",
347  "stringp" => "4",
348  "set_author" => "4",
349  "set_light" => "4",
350  "set_living_name" => "4",
351  "set_privs" => "4",
352  "seteuid" => "4",
353  "save_object" => "4",
354  "set_heart_beat" => "4",
355  "set_hide" => "4",
356  "socket_accept" => "4",
357  "socket_acquire" => "4",
358  "socket_address" => "4",
359  "socket_bind" => "4",
360  "socket_close" => "4",
361  "socket_create" => "4",
362  "socket_error" => "4",
363  "socket_listen" => "4",
364  "socket_release" => "4",
365  "socket_write" => "4",
366  "set_bit" => "4",
367  "sprintf" => "4",
368  "sscanf" => "4",
369  "strcmp" => "4",
370  "strlen" => "4",
371  "strsrch" => "4",
372  "set_reset" => "4",
373  "shallow_inherit_list" => "4",
374  "this_object" => "4",
375  "throw" => "4",
376  "tan" => "4",
377  "to_float" => "4",
378  "to_int" => "4",
379  "typeof" => "4",
380  "this_interactive" => "4",
381  "this_player" => "4",
382  "this_user" => "4",
383  "time_expression" => "4",
384  "trace" => "4",
385  "traceprefix" => "4",
386  "tell_object" => "4",
387  "tell_room" => "4",
388  "terminal_colour" => "4",
389  "test_bit" => "4",
390  "time" => "4",
391  "unique_array" => "4",
392  "users" => "4",
393  "unique_mapping" => "4",
394  "undefinedp" => "4",
395  "upper_case" => "4",
396  "uptime" => "4",
397  "values" => "4",
398  "virtualp" => "4",
399  "variables" => "4",
400  "write_buffer" => "4",
401  "write_bytes" => "4",
402  "write_file" => "4",
403  "write" => "4",
404  "inherit" => "5",
405  "#define" => "5",
406  "#include" => "5",
407  "#if" => "5",
408  "#else" => "5",
409  "#ifdef" => "5",
410  "#pragma" => "5",
411  "#endif" => "5",
412  "#ifndef" => "5",
413  "#undef//" => "5",
414  "{" => "6",
415  "}" => "6",
416  "attack" => "7",
417  "add_boost" => "7",
418  "add_hp" => "7",
419  "add_sp" => "7",
420  "add_money" => "7",
421  "add_extra_attack" => "7",
422  "add_name" => "7",
423  "create" => "7",
424  "clear_opponents" => "7",
425  "do_command" => "7",
426  "evade_attack" => "7",
427  "get_weapon" => "7",
428  "heart_beat" => "7",
429  "hit_player" => "7",
430  "hold_attack" => "7",
431  "init" => "7",
432  "load_chat" => "7",
433  "load_a_chat" => "7",
434  "move_living" => "7",
435  "move" => "7",
436  "move_or_destruct" => "7",
437  "notify_died" => "7",
438  "notify_killed" => "7",
439  "notify_softkilled" => "7",
440  "notify_got_hit" => "7",
441  "notify_sold" => "7",
442  "notify_softdied" => "7",
443  "notify_moved" => "7",
444  "query_guild_data" => "7",
445  "query_objective" => "7",
446  "query_opponents" => "7",
447  "query_possessive" => "7",
448  "query_name" => "7",
449  "query_pronoun" => "7",
450  "query_short" => "7",
451  "query_long" => "7",
452  "query_fightable" => "7",
453  "query_use" => "7",
454  "query_ac" => "7",
455  "query_sc" => "7",
456  "query_wc" => "7",
457  "query_hp" => "7",
458  "query_sp" => "7",
459  "query_no_get" => "7",
460  "query_no_drop" => "7",
461  "query_opponent" => "7",
462  "query_npc" => "7",
463  "query_living" => "7",
464  "query_vis" => "7",
465  "query_value" => "7",
466  "query_light" => "7",
467  "query_total_boost" => "7",
468  "query_origin" => "7",
469  "query_level" => "7",
470  "query_str" => "7",
471  "query_dex" => "7",
472  "query_con" => "7",
473  "query_int" => "7",
474  "query_wis" => "7",
475  "query_cha" => "7",
476  "query_protection" => "7",
477  "query_location" => "7",
478  "remove_object" => "7",
479  "receive_object" => "7",
480  "remove_item_boost" => "7",
481  "reset" => "7",
482  "remove_boost" => "7",
483  "remove_extra_short" => "7",
484  "register_notify" => "7",
485  "register_prevent" => "7",
486  "release_object" => "7",
487  "set_ac" => "7",
488  "set_al" => "7",
489  "set_gender" => "7",
490  "set_guild_data" => "7",
491  "set_female" => "7",
492  "set_male" => "7",
493  "set_name" => "7",
494  "set_neuter" => "7",
495  "set_race" => "7",
496  "set_sc" => "7",
497  "set_stats" => "7",
498  "set_value" => "7",
499  "set_wc" => "7",
500  "set_weight" => "7",
501  "set_type" => "7",
502  "set_long" => "7",
503  "set_short" => "7",
504  "set_softkill" => "7",
505  "set_fightable_msg" => "7",
506  "set_weapon" => "7",
507  "set_locations" => "7",
508  "set_location_prob" => "7",
509  "spell_player" => "7",
510  "stop_attack" => "7",
511  "start_attack" => "7",
512  "start_attack_allowed" => "7",
513  "set_immunity" => "7",
514  "set_humanoid" => "7",
515  "set_aggressive" => "7",
516  "second_life" => "7",
517  "set_property" => "7",
518  "set_no_drop" => "7",
519  "set_no_get" => "7",
520  "unregister_notify" => "7",
521  "unregister_prevent" => "7");
522 
523  // Special extensions
524 
525  // Each category can specify a PHP function that returns an altered
526  // version of the keyword.
527 
528 
529 
530  $this->linkscripts = array(
531  "1" => "donothing",
532  "2" => "donothing",
533  "3" => "donothing",
534  "4" => "donothing",
535  "5" => "donothing",
536  "6" => "donothing",
537  "7" => "donothing");
538  }
539 
540 
541  public function donothing($keywordin)
542  {
543  return $keywordin;
544  }
545  }
HFile_lpc()
Definition: HFile_lpc.php:9
Create styles array
The data for the language used.
Definition: HFile.php:21
donothing($keywordin)
Definition: HFile_lpc.php:541
$BEAUT_PATH
Definition: HFile_lpc.php:2