flagxor / ueforth

Apache License 2.0
95 stars 26 forks source link

visual edit: saving with CTRL+S #48

Closed farvardin closed 7 months ago

farvardin commented 1 year ago

hello,

in the visual editor, I suppose it works fine from a windows terminal, but on most unix system, CTRL+S will block the terminal, cf. https://unix.stackexchange.com/questions/137842/what-is-the-point-of-ctrl-s

https://github.com/flagxor/ueforth/blob/c7dcbbef36402836d32ef4084c35ea91636d71ca/common/visual.fs#L135

I understand there isn't really another obvious shortcut, but maybe it would be possible to use alt+S?

For my part I've remapped it to CTRL+P, and I've also added a visual "saved" message which will help to make sure it tried to save:

 dup [char] P [char] @ - = if drop save update ." saved" exit then
flagxor commented 7 months ago

Added Ctrl-P as an alias in 65eb318f2c29c9303657833102df7b532a66f280 And also added ." saved"