Skip to content

Conversation

@FoamyGuy
Copy link
Contributor

@FoamyGuy FoamyGuy commented May 6, 2025

  • updated boot.py to use adafruit_argv_file functions
  • fix new file functionality in the editor picker
  • allow saving files in /sd/ and /saves/ when the rest of storage is readonly
  • add ctrl-P hotkey in editor to launch the picker to open a new file
  • auto indent to the level of previous line when you make a new line
  • backspace deletes 4 spaces at a time if there are no non-space characters before the cursor on the current line i.e. a single press of backspace will erase one set of indention spaces added by the auto indention from the point above.
  • fix some docstrings and copyrights

next todo:

  • optional mouse click to move cursor
  • refactor cursor to use TilePaletteMapper
  • maybe handle tab key

I tried for a while to add support for tab indention with the editor / code but that turns out to be quite tricky. The Terminal class doesn't seem to support showing anything for "\t" so it would be up to user code to "fake" all of the required behaviors. I tried inserting "-> " in place of "\t" visually, and got it sort of working but not all the way. The cursor position and visible cursor text get all thrown off, I tried making special behavior in several spots for tab handling but never did get it fully working and in the end bailed on my efforts. I will check how strong of a desire there is to support tabs in the editor, and ponder some alternative solutions if there is.

FoamyGuy added 2 commits May 6, 2025 17:25
… allow saving files in /saves/ and /sd/ when main storage is readonly, ctrl-p hotkey to open picker from editor
… cursor to use TilePaletteMapper, use ctrl-O for open, fix saving files, highlight bottom row
@FoamyGuy
Copy link
Contributor Author

FoamyGuy commented May 8, 2025

Latest commits:

  • added optional support for usb mouse in the editor, move mouse and click to move the visible cursor to that location
  • made getkey() inside of dang non-blocking (required to get the mouse working). Updated various things to account for this change
  • Change the visible cursor to use TilePaletteMapper instead of a Label overlayed on top. Requires branch from Integrate TilePaletteMapper and TileGrid further circuitpython#10318
  • In editor change ctrl-P for Picker, to ctrl-O for Open.
  • Fixes for saving files when drive is RW, and fix for saving inside of /saves/ when main storage is RO after creating a new file
  • Highlight the bottom row with hotkeys and user feedback using the TPM

and

  • use circup to install libs needed by builtin_apps

An issue is created in the core for the visual tabs in Terminal. adafruit/circuitpython#10319

@FoamyGuy FoamyGuy merged commit e49c754 into main May 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants