Skip to content

Instantly share code, notes, and snippets.

@faustman
Forked from jdkanani/notepad.html
Created February 8, 2013 18:48
Show Gist options
  • Save faustman/4741071 to your computer and use it in GitHub Desktop.
Save faustman/4741071 to your computer and use it in GitHub Desktop.

Revisions

  1. @jdkanani jdkanani revised this gist Feb 1, 2013. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion notepad.html
    Original file line number Diff line number Diff line change
    @@ -27,6 +27,6 @@
    -->


    <!-- If you want a instant markdown converter use this : !-->
    <!-- If you want a markdown converter use this : !-->
    data:text/html,<style type="text/css">.e{position:absolute;top:0;right:50%;bottom:0;left:0;} .c{position:absolute;overflow:auto;top:0;right:0;bottom:0;left:50%;}</style><div class="e" id="editor"></div><div class="c"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script src="http://cdnjs.cloudflare.com/ajax/libs/showdown/0.3.1/showdown.min.js"></script><script> function showResult(e){consoleEl.innerHTML=e}var e=ace.edit("editor");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/markdown");var consoleEl=document.getElementsByClassName("c")[0];var converter=new Showdown.converter;e.commands.addCommand({name:"markdown",bindKey:{win:"Ctrl-M",mac:"Command-M"},exec:function(t){var n=e.getSession().getMode().$id;if(n=="ace/mode/markdown"){showResult(converter.makeHtml(t.getValue()))}},readOnly:true})</script>
    <!-- Press Ctrl+M or Command+M to convert your markdown code to html :) -->
  2. @jdkanani jdkanani revised this gist Jan 31, 2013. 1 changed file with 2 additions and 3 deletions.
    5 changes: 2 additions & 3 deletions notepad.html
    Original file line number Diff line number Diff line change
    @@ -27,7 +27,6 @@
    -->


    <!-- If you want a instant markdown converter use this :
    Press Ctrl+M or Command+M to convert your markdown code to html :)
    -->
    <!-- If you want a instant markdown converter use this : !-->
    data:text/html,<style type="text/css">.e{position:absolute;top:0;right:50%;bottom:0;left:0;} .c{position:absolute;overflow:auto;top:0;right:0;bottom:0;left:50%;}</style><div class="e" id="editor"></div><div class="c"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script src="http://cdnjs.cloudflare.com/ajax/libs/showdown/0.3.1/showdown.min.js"></script><script> function showResult(e){consoleEl.innerHTML=e}var e=ace.edit("editor");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/markdown");var consoleEl=document.getElementsByClassName("c")[0];var converter=new Showdown.converter;e.commands.addCommand({name:"markdown",bindKey:{win:"Ctrl-M",mac:"Command-M"},exec:function(t){var n=e.getSession().getMode().$id;if(n=="ace/mode/markdown"){showResult(converter.makeHtml(t.getValue()))}},readOnly:true})</script>
    <!-- Press Ctrl+M or Command+M to convert your markdown code to html :) -->
  3. @jdkanani jdkanani revised this gist Jan 31, 2013. 1 changed file with 4 additions and 0 deletions.
    4 changes: 4 additions & 0 deletions notepad.html
    Original file line number Diff line number Diff line change
    @@ -1,6 +1,7 @@
    data:text/html, <style type="text/css">.e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div class="e" id="editor"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("editor");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/ruby");</script>
    <!--
    For other language: Instead of `ace/mode/ruby`, Use
    Markdown -> `ace/mode/markdown`
    Python -> `ace/mode/python`
    C/C++ -> `ace/mode/c_cpp`
    @@ -12,8 +13,11 @@
    css, html, php, latex,
    tex, sh, sql, lua, clojure, dart, typescript, go, groovy, json, jsp, less, lisp,
    lucene, perl, powershell, scss, textile, xml, yaml, xquery, liquid, diff and many more...
    ---------------------------------------------------------------------------------------
    For other theme: Instead of `ace/theme/monokai`, Use
    Eclipse -> ace/theme/eclipse
    GitHub -> ace/theme/github
    TextMate -> ace/theme/textmate
  4. @jdkanani jdkanani revised this gist Jan 31, 2013. 1 changed file with 8 additions and 7 deletions.
    15 changes: 8 additions & 7 deletions notepad.html
    Original file line number Diff line number Diff line change
    @@ -1,9 +1,6 @@
    data:text/html, <style type="text/css">.e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div class="e" id="editor"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("editor");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/ruby");</script>


    <!--
    For other language: Instead of `ace/mode/ruby`, Use
    Markdown -> `ace/mode/markdown`
    Python -> `ace/mode/python`
    C/C++ -> `ace/mode/c_cpp`
    @@ -15,14 +12,18 @@
    css, html, php, latex,
    tex, sh, sql, lua, clojure, dart, typescript, go, groovy, json, jsp, less, lisp,
    lucene, perl, powershell, scss, textile, xml, yaml, xquery, liquid, diff and many more...
    ---------------------------------------------------------------------------------------
    For other theme: Instead of `ace/theme/monokai`, Use
    Eclipse -> ace/theme/eclipse
    GitHub -> ace/theme/github
    TextMate -> ace/theme/textmate
    and
    ambiance, dawn, chaos, chrome, dreamweaver, xcode, vibrant_ink, solarized_dark, solarized_light, tomorrow, tomorrow_night, tomorrow_night_blue,
    twilight, tomorrow_night_eighties, pastel_on_dark and many more..
    -->
    -->


    <!-- If you want a instant markdown converter use this :
    Press Ctrl+M or Command+M to convert your markdown code to html :)
    -->
    data:text/html,<style type="text/css">.e{position:absolute;top:0;right:50%;bottom:0;left:0;} .c{position:absolute;overflow:auto;top:0;right:0;bottom:0;left:50%;}</style><div class="e" id="editor"></div><div class="c"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script src="http://cdnjs.cloudflare.com/ajax/libs/showdown/0.3.1/showdown.min.js"></script><script> function showResult(e){consoleEl.innerHTML=e}var e=ace.edit("editor");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/markdown");var consoleEl=document.getElementsByClassName("c")[0];var converter=new Showdown.converter;e.commands.addCommand({name:"markdown",bindKey:{win:"Ctrl-M",mac:"Command-M"},exec:function(t){var n=e.getSession().getMode().$id;if(n=="ace/mode/markdown"){showResult(converter.makeHtml(t.getValue()))}},readOnly:true})</script>
  5. @jdkanani jdkanani revised this gist Jan 30, 2013. 1 changed file with 8 additions and 2 deletions.
    10 changes: 8 additions & 2 deletions notepad.html
    Original file line number Diff line number Diff line change
    @@ -11,12 +11,18 @@
    Java -> `ace/mode/java`
    Scala- -> `ace/mode/scala`
    CoffeeScript -> `ace/mode/coffee`
    and so on..
    and
    css, html, php, latex,
    tex, sh, sql, lua, clojure, dart, typescript, go, groovy, json, jsp, less, lisp,
    lucene, perl, powershell, scss, textile, xml, yaml, xquery, liquid, diff and many more...
    For other theme: Instead of `ace/theme/monokai`, Use
    Eclipse -> ace/theme/eclipse
    GitHub -> ace/theme/github
    TextMate -> ace/theme/textmate
    and so on..
    and
    ambiance, dawn, chaos, chrome, dreamweaver, xcode, vibrant_ink, solarized_dark, solarized_light, tomorrow, tomorrow_night, tomorrow_night_blue,
    twilight, tomorrow_night_eighties, pastel_on_dark and many more..
    -->
  6. @jdkanani jdkanani revised this gist Jan 30, 2013. 1 changed file with 3 additions and 1 deletion.
    4 changes: 3 additions & 1 deletion notepad.html
    Original file line number Diff line number Diff line change
    @@ -4,15 +4,17 @@
    <!--
    For other language: Instead of `ace/mode/ruby`, Use
    Markdown -> `ace/mode/markdown`
    Python -> `ace/mode/python`
    C/C++ -> `ace/mode/c_cpp`
    Javscript -> `ace/mode/javascript`
    Java -> `ace/mode/java`
    Scala- -> `ace/mode/scala`
    CoffeeScript -> `ace/mode/coffee`
    and so on..
    For other language: Instead of `ace/theme/monokai`, Use
    For other theme: Instead of `ace/theme/monokai`, Use
    Eclipse -> ace/theme/eclipse
    TextMate -> ace/theme/textmate
  7. @jdkanani jdkanani revised this gist Jan 30, 2013. 1 changed file with 0 additions and 5 deletions.
    5 changes: 0 additions & 5 deletions notepad.html
    Original file line number Diff line number Diff line change
    @@ -1,8 +1,3 @@

    data:text/html, <style type="text/css">#e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div id="e"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("e");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/ruby");</script>


    <!--For firefox 18 -->
    data:text/html, <style type="text/css">.e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div class="e" id="editor"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("editor");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/ruby");</script>


  8. @jdkanani jdkanani renamed this gist Jan 30, 2013. 1 changed file with 20 additions and 3 deletions.
    23 changes: 20 additions & 3 deletions Notepad Bookmarklet for → notepad.html
    Original file line number Diff line number Diff line change
    @@ -1,8 +1,25 @@

    data:text/html, <style type="text/css">#e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div id="e"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("e");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/ruby");</script>


    <!--For firefox 18 -->
    data:text/html, <style type="text/css">.e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div class="e" id="editor"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("editor");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/ruby");</script>


    For firefox 18:
    ===============
    <!--
    For other language: Instead of `ace/mode/ruby`, Use
    data:text/html, <style type="text/css">.e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div class="e" id="editor"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("editor");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/ruby");</script>
    Python -> `ace/mode/python`
    C/C++ -> `ace/mode/c_cpp`
    Javscript -> `ace/mode/javascript`
    Java -> `ace/mode/java`
    Scala- -> `ace/mode/scala`
    and so on..
    For other language: Instead of `ace/theme/monokai`, Use
    Eclipse -> ace/theme/eclipse
    TextMate -> ace/theme/textmate
    and so on..
    -->
  9. @jdkanani jdkanani revised this gist Jan 30, 2013. 2 changed files with 8 additions and 1 deletion.
    8 changes: 8 additions & 0 deletions Notepad Bookmarklet for
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,8 @@
    data:text/html, <style type="text/css">#e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div id="e"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("e");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/ruby");</script>



    For firefox 18:
    ===============

    data:text/html, <style type="text/css">.e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div class="e" id="editor"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("editor");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/ruby");</script>
    1 change: 0 additions & 1 deletion Ruby Notepad Bookmarklet
    Original file line number Diff line number Diff line change
    @@ -1 +0,0 @@
    data:text/html, <style type="text/css">#e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div id="e"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("e");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/ruby");</script>
  10. @jakeonrails jakeonrails created this gist Jan 29, 2013.
    1 change: 1 addition & 0 deletions Ruby Notepad Bookmarklet
    Original file line number Diff line number Diff line change
    @@ -0,0 +1 @@
    data:text/html, <style type="text/css">#e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div id="e"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("e");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/ruby");</script>