ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
HFile_bkshell.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_bkshell extends HFile
8  {
9  public function HFile_bkshell()
10  {
11  $this->HFile();
12  /*************************************/
13  // Beautifier Highlighting Configuration File
14  // Bourne & Korn Shell
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", "brown", "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  "bg" => "1",
50  "break" => "1",
51  "cd" => "1",
52  "continue" => "1",
53  "echo" => "1",
54  "eval" => "1",
55  "exec" => "1",
56  "exit" => "1",
57  "export" => "1",
58  "fg" => "1",
59  "function" => "1",
60  "getopts" => "1",
61  "hash" => "1",
62  "jobs" => "1",
63  "kill" => "1",
64  "newgrp" => "1",
65  "pwd" => "1",
66  "read" => "1",
67  "readonly" => "1",
68  "return" => "1",
69  "select" => "1",
70  "set" => "1",
71  "shift" => "1",
72  "stop" => "1",
73  "stty" => "1",
74  "suspend" => "1",
75  "test" => "1",
76  "times" => "1",
77  "trap" => "1",
78  "type" => "1",
79  "ulimit" => "1",
80  "umask" => "1",
81  "unset" => "1",
82  "wait" => "1",
83  "CDPATH" => "2",
84  "EDITOR" => "2",
85  "HOME" => "2",
86  "IFS" => "2",
87  "LANG" => "2",
88  "MAIL" => "2",
89  "MAILCHECK" => "2",
90  "MAILPATH" => "2",
91  "OLDPWD" => "2",
92  "PATH" => "2",
93  "PPID" => "2",
94  "PS1" => "2",
95  "PS2" => "2",
96  "REPLY" => "2",
97  "SHACCT" => "2",
98  "SHELL" => "2",
99  "TERM" => "2",
100  "case" => "3",
101  "do" => "3",
102  "done" => "3",
103  "elif" => "3",
104  "else" => "3",
105  "esac" => "3",
106  "fi" => "3",
107  "for" => "3",
108  "if" => "3",
109  "then" => "3",
110  "while" => "3",
111  "+" => "4",
112  "-" => "4",
113  "=" => "4",
114  "//" => "4",
115  "/" => "4",
116  "%" => "4",
117  "&" => "4",
118  "^" => "4",
119  "!" => "4",
120  "|" => "4",
121  ">>" => "8",
122  ">&" => "8",
123  "<<" => "8",
124  "<&" => "8",
125  "<" => "8",
126  ">" => "8",
127  "$#" => "6",
128  "$-" => "6",
129  "$?" => "6",
130  "$!" => "6",
131  "$*" => "6",
132  "$@" => "6",
133  "$$" => "6",
134  "$0" => "6",
135  "$1" => "6",
136  "$2" => "6",
137  "$3" => "6",
138  "$4" => "6",
139  "$5" => "6",
140  "$6" => "6",
141  "$7" => "6",
142  "$8" => "6",
143  "$9" => "6",
144  "-a" => "7",
145  "-o" => "7",
146  "-eq" => "7",
147  "-ne" => "7",
148  "-le" => "7",
149  "-lt" => "7",
150  "-ge" => "7",
151  "-gt" => "7",
152  "-b" => "7",
153  "-c" => "7",
154  "-d" => "7",
155  "-f" => "7",
156  "-g" => "7",
157  "-k" => "7",
158  "-l" => "7",
159  "-p" => "7",
160  "-r" => "7",
161  "-s" => "7",
162  "-S" => "7",
163  "-t" => "7",
164  "-u" => "7",
165  "-w" => "7",
166  "-x" => "7",
167  "-n" => "7",
168  "-z" => "7");
169 
170  // Special extensions
171 
172  // Each category can specify a PHP function that returns an altered
173  // version of the keyword.
174 
175 
176 
177  $this->linkscripts = array(
178  "1" => "donothing",
179  "2" => "donothing",
180  "3" => "donothing",
181  "4" => "donothing",
182  "8" => "donothing",
183  "6" => "donothing",
184  "7" => "donothing");
185  }
186 
187 
188  public function donothing($keywordin)
189  {
190  return $keywordin;
191  }
192  }
$BEAUT_PATH
donothing($keywordin)
Create styles array
The data for the language used.
Definition: HFile.php:21