]>
src.bluestatic.org Git - viewsvn.git/blob - includes/geshi/geshi/lua.php
2 /*************************************************************************************
5 * Author: Roberto Rossi (rsoftware@altervista.org)
6 * Copyright: (c) 2004 Roberto Rossi (http://rsoftware.altervista.org), Nigel McNie (http://qbnz.com/highlighter)
7 * Release Version: 1.0.7.5
8 * CVS Revision Version: $Revision: 1.7 $
9 * Date Started: 2004/07/10
10 * Last Modified: $Date: 2005/10/22 07:52:59 $
12 * LUA language file for GeSHi.
17 * - Added support for objects and methods
18 * - Removed unusable keywords
20 * - Added support for multiple object splitters
24 * TODO (updated 2004/11/27)
25 * -------------------------
27 *************************************************************************************
29 * This file is part of GeSHi.
31 * GeSHi is free software; you can redistribute it and/or modify
32 * it under the terms of the GNU General Public License as published by
33 * the Free Software Foundation; either version 2 of the License, or
34 * (at your option) any later version.
36 * GeSHi is distributed in the hope that it will be useful,
37 * but WITHOUT ANY WARRANTY; without even the implied warranty of
38 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
39 * GNU General Public License for more details.
41 * You should have received a copy of the GNU General Public License
42 * along with GeSHi; if not, write to the Free Software
43 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
45 ************************************************************************************/
47 $language_data = array (
49 'COMMENT_SINGLE' => array(1 => "--"),
50 'COMMENT_MULTI' => array('--[[' => ']]'),
51 'CASE_KEYWORDS' => GESHI_CAPS_NO_CHANGE
,
52 'QUOTEMARKS' => array('"'),
53 'ESCAPE_CHAR' => '\\',
56 'and','break','do','else','elseif','end','false','for','function','if',
57 'in','local','nil','not','or','repeat','return','then','true','until','while',
58 '_VERSION','assert','collectgarbage','dofile','error','gcinfo','loadfile','loadstring',
59 'print','tonumber','tostring','type','unpack',
60 '_ALERT','_ERRORMESSAGE','_INPUT','_PROMPT','_OUTPUT',
61 '_STDERR','_STDIN','_STDOUT','call','dostring','foreach','foreachi','getn','globals','newtype',
62 'rawget','rawset','require','sort','tinsert','tremove',
63 'abs','acos','asin','atan','atan2','ceil','cos','deg','exp',
64 'floor','format','frexp','gsub','ldexp','log','log10','max','min','mod','rad','random','randomseed',
65 'sin','sqrt','strbyte','strchar','strfind','strlen','strlower','strrep','strsub','strupper','tan',
66 'openfile','closefile','readfrom','writeto','appendto',
67 'remove','rename','flush','seek','tmpfile','tmpname','read','write',
68 'clock','date','difftime','execute','exit','getenv','setlocale','time',
69 '_G','getfenv','getmetatable','ipairs','loadlib','next','pairs','pcall',
70 'rawegal','rawget','rawset','require','setfenv','setmetatable','xpcall',
71 'string.byte','string.char','string.dump','string.find','string.len',
72 'string.lower','string.rep','string.sub','string.upper','string.format','string.gfind','string.gsub',
73 'table.concat','table.foreach','table.foreachi','table.getn','table.sort','table.insert','table.remove','table.setn',
74 'math.abs','math.acos','math.asin','math.atan','math.atan2','math.ceil','math.cos','math.deg','math.exp',
75 'math.floor','math.frexp','math.ldexp','math.log','math.log10','math.max','math.min','math.mod',
76 'math.pi','math.rad','math.random','math.randomseed','math.sin','math.sqrt','math.tan',
77 'coroutine.create','coroutine.resume','coroutine.status',
78 'coroutine.wrap','coroutine.yield',
79 'io.close','io.flush','io.input','io.lines','io.open','io.output','io.read','io.tmpfile','io.type','io.write',
80 'io.stdin','io.stdout','io.stderr',
81 'os.clock','os.date','os.difftime','os.execute','os.exit','os.getenv','os.remove','os.rename',
82 'os.setlocale','os.time','os.tmpname',
83 'string','table','math','coroutine','io','os','debug'
87 '(', ')', '{', '}', '!', '@', '%', '&', '*', '|', '/', '<', '>', '=', ';'
89 'CASE_SENSITIVE' => array(
90 GESHI_COMMENTS
=> true,
95 1 => 'color: #b1b100;'
98 1 => 'color: #808080; font-style: italic;',
99 'MULTI' => 'color: #808080; font-style: italic;'
101 'ESCAPE_CHAR' => array(
102 0 => 'color: #000099; font-weight: bold;'
105 0 => 'color: #66cc66;'
108 0 => 'color: #ff0000;'
111 0 => 'color: #cc66cc;'
114 0 => 'color: #b1b100;'
117 0 => 'color: #66cc66;'
125 'OBJECT_SPLITTERS' => array(
129 'STRICT_MODE_APPLIES' => GESHI_NEVER
,
130 'SCRIPT_DELIMITERS' => array(
132 'HIGHLIGHT_STRICT_BLOCK' => array(