Popular recipes tagged "editor" but not "chess"http://code.activestate.com/recipes/tags/editor-chess/2014-09-01T18:26:51-07:00ActiveState Code RecipesCall out to an external editor (Python)
2014-09-01T18:26:51-07:00Steven D'Apranohttp://code.activestate.com/recipes/users/4172944/http://code.activestate.com/recipes/578926-call-out-to-an-external-editor/
<p style="color: grey">
Python
recipe 578926
by <a href="/recipes/users/4172944/">Steven D'Aprano</a>
(<a href="/recipes/tags/editing/">editing</a>, <a href="/recipes/tags/editor/">editor</a>, <a href="/recipes/tags/external/">external</a>, <a href="/recipes/tags/text/">text</a>).
Revision 2.
</p>
<p>Here's a function that lets you use Python to wrap calls to an external editor. The editor can be an command line editor, like venerable old "ed", or something more powerful like nano, vim or emacs, and even GUI editors. After the editor quits, the text you typed in the editor is returned by the function.</p>
<p>A simple example, using the (rather cryptic) 'ed' editor on Linux. For the benefit of those unfamiliar with 'ed', I have annotated the editor session with comments.</p>
<pre class="prettyprint"><code>>>> status, text = edit('ed')
0 ## ed prints the initial number of lines
a ## start "append" mode
Hello World!
Goodbye now
. ## stop appending
w ## write the file to disk
25 ## ed prints the number of bytes written
q ## quit ed and return to Python
>>> status
0
>>> print text
Hello World!
Goodbye now
</code></pre>
Plain Text Editor in Python (Python)
2013-06-18T15:33:01-07:00Captain DeadBoneshttp://code.activestate.com/recipes/users/4184772/http://code.activestate.com/recipes/578568-plain-text-editor-in-python/
<p style="color: grey">
Python
recipe 578568
by <a href="/recipes/users/4184772/">Captain DeadBones</a>
(<a href="/recipes/tags/editor/">editor</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/text/">text</a>, <a href="/recipes/tags/text_processing/">text_processing</a>).
</p>
<p>Just a simple text editor written in Python with Tk for graphics. </p>
<p>Check out my blog <a href="http://thelivingpearl.com/">Captain DeadBones Chronicles</a></p>
Text Editor in Python 3.3 (Python)
2013-06-19T15:58:17-07:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/578569-text-editor-in-python-33/
<p style="color: grey">
Python
recipe 578569
by <a href="/recipes/users/2608421/">Stephen Chappell</a>
(<a href="/recipes/tags/editor/">editor</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/text/">text</a>, <a href="/recipes/tags/text_processing/">text_processing</a>).
</p>
<p>This is a simple text editor written in Python using <code>tkinter</code> for graphics.</p>
<p>Check out Captain DeadBones' <a href="http://thelivingpearl.com/">Chronicles</a> blog.</p>
Komodo JS Macro: Execute JavaScript (JavaScript)
2012-05-07T13:21:30-07:00Patrick Clokehttp://code.activestate.com/recipes/users/4180275/http://code.activestate.com/recipes/578120-komodo-js-macro-execute-javascript/
<p style="color: grey">
JavaScript
recipe 578120
by <a href="/recipes/users/4180275/">Patrick Cloke</a>
(<a href="/recipes/tags/debug/">debug</a>, <a href="/recipes/tags/debugging/">debugging</a>, <a href="/recipes/tags/editor/">editor</a>, <a href="/recipes/tags/komodo/">komodo</a>, <a href="/recipes/tags/macro/">macro</a>).
</p>
<p>Executes a JavaScript file (or the selected text) and display the results in the command output window.</p>
Komodo JS Macro: move tabs (JavaScript)
2012-04-10T17:39:47-07:00Todd Whitemanhttp://code.activestate.com/recipes/users/2666241/http://code.activestate.com/recipes/578093-komodo-js-macro-move-tabs/
<p style="color: grey">
JavaScript
recipe 578093
by <a href="/recipes/users/2666241/">Todd Whiteman</a>
(<a href="/recipes/tags/editor/">editor</a>, <a href="/recipes/tags/komodo/">komodo</a>, <a href="/recipes/tags/macro/">macro</a>, <a href="/recipes/tags/position/">position</a>, <a href="/recipes/tags/tabs/">tabs</a>, <a href="/recipes/tags/toddw/">toddw</a>).
</p>
<p>This Komodo macro is an example to show how to programmatically re-position a Komodo editor tab. This macro moves the currently selected tab to the start of the tab list.</p>
Macro to Quick find (ctrl+f3) on double click (JavaScript)
2011-07-22T07:46:26-07:00Adamhttp://code.activestate.com/recipes/users/4173315/http://code.activestate.com/recipes/577801-macro-to-quick-find-ctrlf3-on-double-click/
<p style="color: grey">
JavaScript
recipe 577801
by <a href="/recipes/users/4173315/">Adam</a>
(<a href="/recipes/tags/editor/">editor</a>, <a href="/recipes/tags/javascript/">javascript</a>, <a href="/recipes/tags/komodo/">komodo</a>, <a href="/recipes/tags/macro/">macro</a>, <a href="/recipes/tags/scintilla/">scintilla</a>).
Revision 3.
</p>
<p>This does a search for the selected word when you double click it. Functionality similar to Notepad++. Faster that ctrl-f3.</p>
Basic Text Editor (Tcl)
2011-03-21T23:10:10-07:00Jonathan Fenechhttp://code.activestate.com/recipes/users/4169413/http://code.activestate.com/recipes/577617-basic-text-editor/
<p style="color: grey">
Tcl
recipe 577617
by <a href="/recipes/users/4169413/">Jonathan Fenech</a>
(<a href="/recipes/tags/basic/">basic</a>, <a href="/recipes/tags/editor/">editor</a>, <a href="/recipes/tags/text/">text</a>).
</p>
<p>Text editor with copy,cut and paste functions.</p>
Komodo JS Macro - delete marked lines (JavaScript)
2010-08-30T17:32:24-07:00Eric Promislowhttp://code.activestate.com/recipes/users/4166930/http://code.activestate.com/recipes/577378-komodo-js-macro-delete-marked-lines/
<p style="color: grey">
JavaScript
recipe 577378
by <a href="/recipes/users/4166930/">Eric Promislow</a>
(<a href="/recipes/tags/bookmarks/">bookmarks</a>, <a href="/recipes/tags/editor/">editor</a>, <a href="/recipes/tags/javascript/">javascript</a>, <a href="/recipes/tags/komodo/">komodo</a>).
</p>
<p>You can set bookmarks in Komodo, for ease ni revisiting certain lines. This recipe lets you
delete all the marked lines in the current buffer. This code is undoable, but the markers
are gone for good. They aren't restored by Scintilla, and having Komodo restore them
would be a pain.</p>
CommentEditor: HTML editor for online comments (Python)
2009-06-17T12:10:55-07:00Jack Trainorhttp://code.activestate.com/recipes/users/4076953/http://code.activestate.com/recipes/576814-commenteditor-html-editor-for-online-comments/
<p style="color: grey">
Python
recipe 576814
by <a href="/recipes/users/4076953/">Jack Trainor</a>
(<a href="/recipes/tags/editor/">editor</a>, <a href="/recipes/tags/html/">html</a>, <a href="/recipes/tags/wxwidgets/">wxwidgets</a>).
Revision 3.
</p>
<p>Edit online comments with easy addition of HTML tags for bold, italics, underlining, blockquote and anchored links. Then check your work with the preview feature.</p>
<p>Requires wxWidgets.</p>