Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Emacs-ish wishlist #23

Open
tommythorn opened this issue Apr 15, 2022 · 2 comments
Open

Emacs-ish wishlist #23

tommythorn opened this issue Apr 15, 2022 · 2 comments

Comments

@tommythorn
Copy link

tommythorn commented Apr 15, 2022

Wishlist of a lifelong Emacs user here with spinal-wired muscle memory.

I'm not looking for a complete Emacs clone, but here are some things that I use every minute that doesn't work in Zee which I would love to see added (this list is evolving - expect edits):

Notation: C-x is an Emacs shorthand for Control-x, M-y means Meta-y, S-z means Shift-z, etc.

  • C-u prefix: all commands in Emacs takes an optional numerical argument. C-u has rich semantics, in particular C-u defaults to 4 and every subsequent C-u quadruples this. E.g. C-u C-u C-u Down moves the cursor down 64 lines, C-u C-v moves down four pages etc. (I literally use this multiple times a minute). An explicit value can be set by entering the number, e.g. C-u 1 0 0 Down moves down 100.
  • M-b, M-f, M-p, M-n (equivalent to M-Left, M-Right, M-Up, M-Down). M-b/M-f skips backwords and forwards by "word" (what is considered a word is mode specific). Importantly, forward movements leaves the cursor after the word, backwards leaves it at the start of the word.
  • S-M-b/S-M-f are fabulous for navigating over nested parenthesis/braces/brackets.
  • C-o "opens" a line, that is, (AFAIK) equivalent to Return Left.
  • Undo bindings: C-x u, C-_, C-/
    It's amusing it took me this long to notice. Not sure why there are so many alternatives, but curiously which I use
    depends on the keyboard and terminal (eg. C-/ doesn't work in the macOS terminal for some reason).
  • M-q (fill-papagraph) for formatting text within the settable width, knows about comments and comment blocks.

NB: I might work on adding this myself if this is something you agree should be added.

@mcobzarenco
Copy link
Collaborator

mcobzarenco commented Apr 16, 2022

Thank you so much for creating this, it's so helpful. I basically agree with everything on your list -- the basic editing experience is not great right now.

(As some context, I got started on skipping backwards and forwards by word recently, but wished that adding a new command would be much easier / less boilerplate-y. My focused shifted last two weeks on fundamental stuff around extensibility. I've just pushed a big commit that links to tree sitter parsers dynamically to open the door to configuring what languages you need dynamically -- they all used to be statically linked).

EDIT: there's a strong argument to be made to just add all of these and worry later about how to register commands in an extensible way. The downside is just more stuff to move around once the details of what command is, how it gets registered, invoked and associated with key bindings settle more.

@hu-chia
Copy link

hu-chia commented Jun 10, 2022

And more, rectangular selections is a very very common usage.

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

No branches or pull requests

3 participants