| <html> |
| <head> |
| <title>Theme CSS editor</title> |
| <style> |
| #editor { |
| border: 1px solid teal; |
| position: absolute; |
| top: 0px; |
| left: 0px; |
| bottom: 0px; |
| right: 0px; |
| margin: 20px; |
| } |
| |
| pre { |
| margin: 0px; |
| } |
| </style> |
| <link rel="stylesheet" type="text/css" href="%s"/> |
| <script src="%s"></script> |
| <script> |
| %s |
| </script> |
| <script> |
| /*globals require*/ |
| require(["orion/editor/edit", "examples/editor/swtContentAssist"], function(edit, mSWTContentAssist) { |
| var editor = edit({ |
| lang: "css" |
| }); |
| //ADD THE SWT CONTENT ASSIST |
| var contentAssist = editor.getContentAssist ? editor.getContentAssist() : editor._contentAssist; |
| contentAssist.addEventListener("Activating", function() { //$NON-NLS-0$ |
| contentAssist.providers.push(new mSWTContentAssist.SWTContentAssistProvider()); |
| }); |
| window.editor = editor; |
| //---------------- |
| }); |
| </script> |
| </head> |
| <body spellcheck="false"> |
| <pre id="editor" class="editor" data-editor-lang="css"> |
| %s |
| </pre> |
| </body> |
| </html> |