4
<title>CodeMirror: Lua mode</title>
5
<link rel="stylesheet" href="../../lib/codemirror.css">
6
<script src="../../lib/codemirror.js"></script>
7
<script src="lua.js"></script>
8
<link rel="stylesheet" href="../../theme/neat.css">
9
<style>.CodeMirror {border: 1px solid black;}</style>
10
<link rel="stylesheet" href="../../doc/docs.css">
13
<h1>CodeMirror: Lua mode</h1>
14
<form><textarea id="code" name="code">
16
example useless code to show lua syntax highlighting
17
this is multiline comment
20
function blahblahblah(x)
29
my_custom_function( 0x34 )
31
unknown_function( "some string" )
40
for k,v in ipairs( table ) do
44
x is a multi line string
46
but its definition is iside a highest level string!
56
var editor = CodeMirror.fromTextArea(document.getElementById("code"), {
63
<p>Loosely based on Franciszek
64
Wawrzak's <a href="http://codemirror.net/1/contrib/lua">CodeMirror
65
1 mode</a>. One configuration parameter is
66
supported, <code>specials</code>, to which you can provide an
67
array of strings to have those identifiers highlighted with
68
the <code>lua-special</code> style.</p>
69
<p><strong>MIME types defined:</strong> <code>text/x-lua</code>.</p>