A full screen editor for the Elf/OS written in 1802 Assembly language and based loosely on the Kilo editor by Salvatore Sanfilippo aka antirez and the Elfos-Edit editor by Mike Riley.
The Elf/OS kilo editor was written for an 1802 based Microcomputer running the Elf/OS operating system, such as the Pico/Elf by Mike Riley or the 1802-Mini by David Madole or the AVI Elf II by Ed Keefe. A lot of information and software for the Pico/Elf, the 1802-Mini and the AVI Elf II can be found on the Elf-Emulation website and in the COSMAC ELF Group at groups.io.
The Elf/OS kilo editor were assembled and linked with updated versions of the Asm-02 assembler and Link-02 linker by Mike Riley. The updated versions required to assemble and link this code are available at fourstix/Asm-02 and fourstix/Link-02.
Keys | Command |
---|---|
Ctrl+B, Home | Move to the Beginning of line |
Ctrl+C | Copy line to clip board |
Ctrl+D, Down | Move cursor Down |
Ctrl+E, End | Move to End of line |
Ctrl+F | Find text |
Ctrl+G | Go to line number | Ctrl+H, Backspace | Move back and delete character |
Ctrl+I, Tab | Move forward to next tab stop |
Ctrl+J | Join lines |
Ctrl+K, Delete | Delete (Kill) character |
Ctrl+L, Left | Move cursor Left |
Ctrl+M, Enter | Insert Mode: insert new line or split at cursor |
Overwrite Mode: Move down to the next line. | |
Ctrl+N, PgDn | Next screen |
Ctrl+O, Insert | Toggle Overwrite/insert Mode screen |
Ctrl+P, PgUp | Previous screen |
Ctrl+Q | Quit, confirm if file changed |
Ctrl+R, Right | Move cursor Right |
Ctrl+S | Save file |
Ctrl+T | Move to Top of file |
Ctrl+U, Up | Move cursor Up |
Ctrl+V | Paste line from clip board |
Ctrl+W | show Where cursor is located in file |
Ctrl+X | Cut line into clip board |
Ctrl+Y | Save As new file |
Ctrl+Z | Move to bottom of file |
Ctrl+], Shift+Tab | Move back to previous tab stop |
Ctrl+\ | Split line at cursor |
Ctrl+? | Show help information |
Ctrl+_ (See Note) |
Note: On older DEC video terminals the Ctrl+_ key combination replaces the Ctrl+? combination key for help. Some emulators may support one or the other or both.
Insert Mode
Overwrite Mode
These key character sequences follow the VT102 terminal specification. In the table below, {ESC} is the Escape control character, ASCII 27, hex value $1B. Should one of these keys not behave as expected, you may need to configure your terminal program to return the expected key character sequence. Note that the Delete key can have either one of two possible sequences.
Key | Character Sequence |
---|---|
Up (Arrow) | {ESC}[A |
{ESC}A (See Note) | |
Down (Arrow) | {ESC}[B |
{ESC}B (See Note) | |
Right (Arrow) | {ESC}[C |
{ESC}C (See Note) | |
Left (Arrow) | {ESC}[D |
{ESC}D (See Note) | |
Home | {ESC}[1~ |
Insert | {ESC}[2~ |
Delete | {ESC}[3~ |
DEL ($7F) | |
End | {ESC}[4~ |
PgUp | {ESC}[5~ |
PgDn | {ESC}[6~ |
Backspace | Ctrl+H ($08) |
Tab | Ctrl+I ($09) |
Shift+Tab | {ESC}[Z |
Enter | Ctrl+M ($0D) |
Note: On some older DEC video terminals, the arrow keys send {ESC}A through {ESC}D instead of the ANSI sequences {ESC}[A through {ESC}[D.
This code is public domain under the MIT License, but please buy me a beverage if you use this and we meet someday (Beerware).
References to any products, programs or services do not imply that they will be available in all countries in which their respective owner operates.
Any company, product, or services names may be trademarks or services marks of others.
All libraries used in this code are copyright their respective authors.
This code is based on a Elf/OS kernel written by Mike Riley and created with the Asm/02 assembler and Link/02 linker also written by Mike Riley.
Elf/OS Copyright (c) 2004-2024 by Mike Riley
Kilo Editor Copyright (c) 2016-2024 by Salvatore Sanfilippo
Elf-Elfos-Edit Copyright (c) 2004-2024 by Mike Riley
Asm/02 1802 Assembler Copyright (c) 2004-2024 by Mike Riley
Link/02 1802 Linker Copyright (c) 2004-2024 by Mike Riley
VT102 User Guide Copyright (c) 1982 by Digital Equipment Corporation
Many thanks to the original authors for making their designs and code available as open source.
This code, firmware, and software is released under the MIT License.
The MIT License (MIT)
Copyright (c) 2024 by Gaston Williams
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.