~ivle-dev/ivle/codemirror

« back to all changes in this revision

Viewing changes to ivle/webapp/filesystem/browser/media/codemirror/htmltest.html

  • Committer: David Coles
  • Date: 2010-05-31 10:38:53 UTC
  • Revision ID: coles.david@gmail.com-20100531103853-8xypjpracvwy0qt4
Editor: Added CodeMirror-0.67 Javascript code editor source from 
http://marijn.haverbeke.nl/codemirror/ (zlib-style licence)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<html xmlns="http://www.w3.org/1999/xhtml">
 
2
  <head>
 
3
    <script src="js/codemirror.js" type="text/javascript"></script>
 
4
    <title>CodeMirror: HTML/XML demonstration</title>
 
5
    <link rel="stylesheet" type="text/css" href="css/docs.css"/>
 
6
    <style type="text/css">
 
7
      .CodeMirror-line-numbers {
 
8
        width: 2.2em;
 
9
        color: #aaa;
 
10
        background-color: #eee;
 
11
        text-align: right;
 
12
        padding-right: .3em;
 
13
        font-size: 10pt;
 
14
        font-family: monospace;
 
15
        padding-top: .4em;
 
16
      }
 
17
    </style>
 
18
  </head>
 
19
  <body style="padding: 20px;">
 
20
 
 
21
<p>This is a simple demonstration of the XML/HTML indentation module
 
22
for <a href="index.html">CodeMirror</a>. The <a
 
23
href="js/parsexml.js">javascript</a> file contains some comments with
 
24
more information.</p>
 
25
 
 
26
<div style="border: 1px solid black; padding: 0px;">
 
27
<textarea id="code" cols="120" rows="30">
 
28
&lt;html style="color: green"&gt;
 
29
  &lt;!-- this is a comment --&gt;
 
30
  &lt;head&gt;
 
31
    &lt;title&gt;HTML Example&lt;/title&gt;
 
32
  &lt;/head&gt;
 
33
  &lt;body&gt;
 
34
    The indentation tries to be &lt;em&gt;somewhat &amp;quot;do what
 
35
    I mean&amp;quot;&lt;/em&gt;... but might not match your style.
 
36
  &lt;/body&gt;
 
37
&lt;/html&gt;
 
38
</textarea>
 
39
</div>
 
40
 
 
41
<script type="text/javascript">
 
42
  var editor = CodeMirror.fromTextArea('code', {
 
43
    height: "350px",
 
44
    parserfile: "parsexml.js",
 
45
    stylesheet: "css/xmlcolors.css",
 
46
    path: "js/",
 
47
    continuousScanning: 500,
 
48
    lineNumbers: true
 
49
  });
 
50
</script>
 
51
  </body>
 
52
</html>