Calling functions with optional arguments from the mini-buffer

Surely one of the first things VIers want to know as do the rest of us is how to move forward N characters (or backward or whatever) from the mini-buffer in EMACS. Here is how it is done, using the universal argument. So to move forward 100 chars:

C:u 100, C:f

ADDENDUM:01/13/13
Thanks FUCO for providing a better solution:

There’s also a faster way. Just hold down control key (or meta key, by default the binding is on both) and type the number, then execute the command or invoke minibuffer with M-x
So, C-2 C-0 C-f will move you 20 characters. It’s neat because you don’t have to release control, you just hit the rest of the keys in sequence.

3 thoughts on “Calling functions with optional arguments from the mini-buffer”

  1. There’s also a faster way. Just hold down control key (or meta key, by default the binding is on both) and type the number, then execute the command or invoke minibuffer with M-x
    So, C-2 C-0 C-f will move you 20 characters. It’s neat because you don’t have to release control, you just hit the rest of the keys in sequence.

Leave a Reply

Your email address will not be published. Required fields are marked *