Editing revision 11 of CommandLine
HomePage
|
RecentChanges
|
EditorIndex
|
TextEditorFamilies
|
Preferences
Editing old revision 11. Saving this page will replace the latest revision with this text.
A command line is an essential feature for a text editor because quite often there are too many commands to bind to keys and there may be parameters to pass to the command that are not easy to pass by keystrokes. NealStephenson said it best [http://www.cryptonomicon.com/beginning.html In the Beginning...] The existance of a command line is a key feature of powerful text editors. Command lines are used in the ViFamily, EmacsFamily, IbmEditorFamily, and others. Also most editors that do have a commandline have an escape, usually the bang ('!') that allows one to execute system commands. Thus giving the editor a basic [[Shell]] feature. An alternative is the ability to "filter" a buffer of text with a command. That command could be either a built-in, a macro, or a [[Shell]] command. In [[VI]], this is the '|' pipe character's function on the CommandLine. ---- Perhaps we should distinguish between a command line and a shell escape? For instance, editors in the IBMEditorFamily like [[T]], [[cse]], or [[X2]] have an actual command line on the screen interface. Editors like [[Vi]] provide a means to execute a command in a sub-shell (via ":!<command>") but don't have a command line per se. One of the neatest implementations of commands in a sub-shell I've seen is in the [[e.com]] TinyEditor. e.com implemented macros by letting you bind named batch files to F-Keys (1.bat, 2.bat, etc.) Press the F-Key, and e.com would write the file being edited to a temp file, and run the named bat file in a sub-shell, passing it the temp file name. The bat file would run, performing the defined operations in the bat file on the temp file. When the bat file exited, e.com would read the changed file back in to the editing buffer. This provided an elegant means of extending e.com, by creating batch files to be text filters, performing operations that weren't built into e.com, like sorting lines in a file. Not bad for a 5K editor. --DMcCunney ---- CategoryFeatures
Summary:
This change is a minor edit.
Please calculate
*
=
(Visit
Preferences
to set your user name.)
View other revisions
HomePage
|
RecentChanges
|
EditorIndex
|
TextEditorFamilies
|
Preferences