Your pinkies are weak fingers and are most susceptible to RSI. Your keyboard should allow you to type the modifier keys with your index fingers or thumbs. Apple users also need access to the Command button with both hands. It’s not a flaw of the text editor! Suitable keyboards for EmacsĪ good programming keyboard makes it easy to press the Control and Meta keys with both your left and right hands. Repeatedly pressing two keys with one hand is not ergonomic and will cause RSI.Įmacs pinky is caused by the location of the control key on your keyboard. This encourages programmers to press Control + c (C-c) by holding Control with their left pinky and “c” with their right index finger. There is only one Control key in the lower left corner of most keyboards. Lots of Emacs commands require the Control key. You should not hold the shift key with your left pinky and press the “w” key with your left index finger. When typing capital W, you should hold down the shift key with your right hand and type the “w” key with your left hand. You should use two hands whenever typing commands that require two keys. You haven’t given Emacs a fair shot if you haven’t tried it out with a suitable keyboard. Most keyboards suck for programming because the special characters and modifer keys aren’t easily accessible.Įmacs keybindings should be used with keyboards easily let you press the modifier keys with both hands. TL DR Emacs isn’t great on normal keyboards but is amazing on keyboards like the Kinesis Advantage that provide easy access to modifier keys for both hands. Yep, that’s right, people have been blaming Emacs for decades when the real problem is the keyboard they’re using to write Emacs! If you’ve had a bad experience with Emacs is probably because you didn’t use the right keyboard. There is a reason tons of famous programmers use Emacs. This blog post outlines a different approach to learning Emacs that won’t leave you confused or with RSI. You’re not alone – Emacs pinky is a thing and several famous Emacs users suffer with debilitating repetitive strain injury. If you care about that command, you may want to pick a different key.Have you ever tried Emacs, found the keybindings to be highly unergonomic, and wondered why so many great programmers are passionate about such a weird editor? This will, of course, shadow the binding for python-find-imports. (eval-after-load "python" '(josh-after-load-python)) (define-key python-mode-map (kbd "C-c C-i") 'python-select-cell)) Use eval-after-load (or the with-eval-after-load wrapper in recent versions of Emacs): (defun josh-after-load-python () The keymap doesn't exist until Python mode is loaded, so you need to delay until this happens. If you want your command to be bound only in Python mode, you need to define it in the Python mode keymap, python-mode-map. If you want your command to be bound globally, you should bind a different key, such as C-c i. As the end-user, expect major modes to often override C-c C-letter bindings. Emacs key bindings manual#I can't find them in the Emacs manual, they're buried in the Elisp manual under major mode conventions: C-c is the prefix that is left free in Emacs C-c C-letter is conventionally for major modes, and C-c letter is conventionally for the end-user. There are conventions for key bindings in Emacs. There's no easy way to look up where a particular binding was made, but you can list the bindings made by the current major mode and active minor modes with C-h m ( describe-mode). in the current mode) by pressing C-h c ( describe-key-briefly) or C-h k ( describe-key) then typing the key (or key sequence). You can check what a key does in the current context (e.g. This is explained in more detail in the manual in the section on local keymaps. Python mode binds C-c C-i (to python-find-imports), so its binding hides yours. Key bindings defined by a mode hide global bindings. Modes can define their own key bindings (and most do).
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |