index.html 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <!doctype html>
  2. <title>CodeMirror: Properties files mode</title>
  3. <meta charset="utf-8"/>
  4. <link rel=stylesheet href="../../doc/docs.css">
  5. <link rel="stylesheet" href="../../lib/codemirror.css">
  6. <script src="../../lib/codemirror.js"></script>
  7. <script src="properties.js"></script>
  8. <style>.CodeMirror {border-top: 1px solid #ddd; border-bottom: 1px solid #ddd;}</style>
  9. <div id=nav>
  10. <a href="http://codemirror.net"><h1>CodeMirror</h1><img id=logo src="../../doc/logo.png"></a>
  11. <ul>
  12. <li><a href="../../index.html">Home</a>
  13. <li><a href="../../doc/manual.html">Manual</a>
  14. <li><a href="https://github.com/codemirror/codemirror">Code</a>
  15. </ul>
  16. <ul>
  17. <li><a href="../index.html">Language modes</a>
  18. <li><a class=active href="#">Properties files</a>
  19. </ul>
  20. </div>
  21. <article>
  22. <h2>Properties files mode</h2>
  23. <form><textarea id="code" name="code">
  24. # This is a properties file
  25. a.key = A value
  26. another.key = http://example.com
  27. ! Exclamation mark as comment
  28. but.not=Within ! A value # indeed
  29. # Spaces at the beginning of a line
  30. spaces.before.key=value
  31. backslash=Used for multi\
  32. line entries,\
  33. that's convenient.
  34. # Unicode sequences
  35. unicode.key=This is \u0020 Unicode
  36. no.multiline=here
  37. # Colons
  38. colons : can be used too
  39. # Spaces
  40. spaces\ in\ keys=Not very common...
  41. </textarea></form>
  42. <script>
  43. var editor = CodeMirror.fromTextArea(document.getElementById("code"), {});
  44. </script>
  45. <p><strong>MIME types defined:</strong> <code>text/x-properties</code>,
  46. <code>text/x-ini</code>.</p>
  47. </article>