aboutsummaryrefslogtreecommitdiff
path: root/js/codemirror/mode/xml/index.html
diff options
context:
space:
mode:
authorPierre Frisch2011-12-22 07:25:50 -0800
committerValerio Virgillito2012-01-27 11:18:17 -0800
commitb89a7ee8b956c96a1dcee995ea840feddc5d4b27 (patch)
tree0f3136ab0ecdbbbed6a83576581af0a53124d6f1 /js/codemirror/mode/xml/index.html
parent2401f05d1f4b94d45e4568b81fc73e67b969d980 (diff)
downloadninja-b89a7ee8b956c96a1dcee995ea840feddc5d4b27.tar.gz
First commit of Ninja to ninja-internal
Signed-off-by: Valerio Virgillito <rmwh84@motorola.com>
Diffstat (limited to 'js/codemirror/mode/xml/index.html')
-rw-r--r--js/codemirror/mode/xml/index.html42
1 files changed, 42 insertions, 0 deletions
diff --git a/js/codemirror/mode/xml/index.html b/js/codemirror/mode/xml/index.html
new file mode 100644
index 00000000..122848ae
--- /dev/null
+++ b/js/codemirror/mode/xml/index.html
@@ -0,0 +1,42 @@
1<!doctype html>
2<html>
3 <head>
4 <title>CodeMirror 2: XML mode</title>
5 <link rel="stylesheet" href="../../lib/codemirror.css">
6 <script src="../../lib/codemirror.js"></script>
7 <script src="xml.js"></script>
8 <link rel="stylesheet" href="../../theme/default.css">
9 <style type="text/css">.CodeMirror {border-top: 1px solid black; border-bottom: 1px solid black;}</style>
10 <link rel="stylesheet" href="../../css/docs.css">
11 </head>
12 <body>
13 <h1>CodeMirror 2: XML mode</h1>
14 <form><textarea id="code" name="code">
15&lt;html style="color: green"&gt;
16 &lt;!-- this is a comment --&gt;
17 &lt;head&gt;
18 &lt;title&gt;HTML Example&lt;/title&gt;
19 &lt;/head&gt;
20 &lt;body&gt;
21 The indentation tries to be &lt;em&gt;somewhat &amp;quot;do what
22 I mean&amp;quot;&lt;/em&gt;... but might not match your style.
23 &lt;/body&gt;
24&lt;/html&gt;
25</textarea></form>
26 <script>
27 var editor = CodeMirror.fromTextArea(document.getElementById("code"), {mode: {name: "xml", htmlMode: true}});
28 </script>
29 <p>The XML mode supports two configuration parameters:</p>
30 <dl>
31 <dt><code>htmlMode (boolean)</code></dt>
32 <dd>This switches the mode to parse HTML instead of XML. This
33 means attributes do not have to be quoted, and some elements
34 (such as <code>br</code>) do not require a closing tag.</dd>
35 <dt><code>alignCDATA (boolean)</code></dt>
36 <dd>Setting this to true will force the opening tag of CDATA
37 blocks to not be indented.</dd>
38 </dl>
39
40 <p><strong>MIME types defined:</strong> <code>application/xml</code>, <code>text/html</code>.</p>
41 </body>
42</html>