Skip to content

Commit

Permalink
Documented the recent changes to the Block modes and Undo
Browse files Browse the repository at this point in the history
  • Loading branch information
robert-hh committed Nov 19, 2015
1 parent 55cf8b5 commit 301affa
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 5 deletions.
Binary file modified Pyboard Editor.doc
Binary file not shown.
Binary file modified Pyboard Editor.pdf
Binary file not shown.
18 changes: 13 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,10 @@ A small text editor written in Python running on PYBoard and WiPy, allowing to e

- Use USB_VCP or UART for input and output.
- Changed the read keyboard function to comply with slow byte-by-byte input on serial lines.
- Added support for TAB, BACKTAB, SAVE, FIND, REPLACE, GOTO line, YANK (delete line into a buffer), DUP (copy line into a buffer), ZAP (insert buffer),REDRAW, UNDO and GET (file)
- Join Lines by 'Delete Char' at the end or Backspace at the beginning of a line, Auto-indent for ENTER, context sensitive TAB, BACKTAB, and HOME
- Moved main into a function
- Added a status line and single line prompts for QUIT, SAVE, FIND, REPLACE, GOTO, GET and Toggles.
- Support of the basic mouse functions scrolling up/down and setting the cursor.
- Added support for Tab, BackTab, Save, Del and Backspace joining lines, Find, Replace, Goto Line, Undo, Get file, Auto-Indent, Set Flags, Copy/Delete & Paste, Indent, Un-Indent
- handling tab (0x09) on reading & writing files,
- Added a status line, line number column and single line prompts for
- Support of the basic mouse functions scrolling up/down and setting the cursor (not WiPy).

The editor assumes a VT100 terminal. It works in Insert mode. Cursor Keys, Home, End, PgUp, PgDn, Del and Backspace work as you would expect. The additional functions like FIND etc. are available with Ctrl-Keys. On reading files, tab characters are expanded to spaces with a tab size of 8, and trailing white space on a line will be discarded. The orginal state of tabs will not be restored when the file is written. Optionally, tabs can be written when saving the file, replacing spaces with tabs when possible. The screen size is determined, when the editor is started or when the Redraw-key (Ctrl-E) is hit.

Expand All @@ -19,6 +18,8 @@ The editor works also well in a Linux or MAC terminal environment, with both pyt
**Files:**

- pye.py: Source file with comments and code for PyBoard, WiPy and Linux micropython/python3. Runs on PyBoard as well, but the file size is much larger than the stripped down version.
- pye2.py: a variant of pye.py which does not change the cursor column during vertical moves.
- pye3.py: a variant of pye.py which tries to keep the cursor column during vertical moves as good as possible.
- Pyboard Editor.pdf: A short documentation
- README.md: This one
- pe.py: Condensed source file for PyBoard with all functions
Expand Down Expand Up @@ -102,3 +103,10 @@ c) expandtabs() and packtabs() with a second argument for tabsize (not for pye,
- Added a cleaner Indent and Un-Indent method; for WiPy too
- Removed the attempt to recover from out-of-memory situations: did not work.
- Still runs on WiPy, but really at it's limit

**1.9** Refinement of Mark and Undo
- Mark setting affects Save and Replace now. With Save, only the marked range is written, with replace, search & replace is done in the marked area only.
- The Undo history is kept after Save. So you can go back to a state before saving
- Removed UART mode on WiPy. Not stable yet. UART mode can be achieved by redirecting REPL.
- A variant of pye.py, called pye2.py, keeps the cursor column even if the cursor is moved beyond the text in a line, instead of moving to the end of text if a line is shorter than the actual cursor column. Another variant, pye3, tries to go back to the cursor column which once was set by a horizontal move. That's more how gedit works. Not sure which I like better.

0 comments on commit 301affa

Please sign in to comment.