8 ms·
Setting up a second keyboard for more shortcuts in Emacs
- tomcooks 8y agoJokes write themselves /s
- cm2187 8y agoAnother idea to consider, something like the Elgato Stream Deck (LCD keyboard where you can configure the image and behavior of every key).
- blacksmith_tb 8y agoWow, those LCD keys are fancy, but it's hard to imagine that's worth the premium over a usb or BT 10-key. Not sure about other platforms, but on macOS with something like Karabiner-elements[1] or Controllermate[2] you could assign all sorts of things to those keys. 1: https://github.com/tekezo/Karabiner-Elements https://github.com/tekezo/Karabiner-Elements 2: https://www.orderedbytes.com/controllermate/ https://www.orderedbytes.com/controllermate/
- cm2187 8y agoI find them useful in a slightly different use case. For things where you don't use them often enough to learn the shortcut by heart (i.e. you don't need the visual help) but often enough that it is worth having a button for it. For instance something you will be doing intensely for a short period of the time in the year.
- Scarbutt 8y agovery nerdy.
- rzzzt 8y agoA second keyboard is also good for playing split-screen multiplayer DOS games. No more incessant beeping in Mortal Kombat when both of you try to perform a combo at the same time!
- namibj 8y agoActually, a sane keyboard with sufficient rollover suffices for that task. Just don't but a <20$ model to get this.
- brandonmenc 8y agoI though emacs/vi users don't want to take their fingers off the home row?
- elago 8y agoTrue for me. Using spacemacs which uses vi style keybindings, so most shortcuts are key sequences instead of chords. I think its faster for me to press two or three characters on the keyboard my fingers are already on before I move them into place on another keyboard. Adding a second keyboard and using the Russian layout is a cool method to use a 2nd keyboard that doesn't just duplicate the keys of the first, and likely has more fun applications than just adding more shortcuts to your text editor.
- ryanianian 8y agoThere's also "key-chord-mode" which lets you bind any function to any two keys pressed in unison (or right after each-other) [1]. IIRC it's built-in to all modern versions. [1] https://www.emacswiki.org/emacs/KeyChord https://www.emacswiki.org/emacs/KeyChord I'm trying to build out more ergonomic bindings since emacs-pinky is starting to haunt me at times. I have key-chords setup for very common things like jump to beginning/end of line ('jk' and 'kl').
- spapas82 8y agoThat's definitely true for vi; but only after you properly remap your ESC key to something else (usually jj or caps lock). Emacs is a differenet story... By default it uses a lot of alt and ctrl key combinations and also makes heavy usage of the arrow and home/end keys. Of course, there is a vi mode for emacs (evil; this is what Spacemacs uses) to take advantage of vi keys in emacs. But I believe that most emacs users just stick to the alt/ctrl shortcuts.
- RBerenguel 8y agoI mix and match vi (evil) and normal emacs commands, choosing what's best for the case and for me. Some commands are so ingrained (C-a and C-e for navigating for instance) and convenient as they are that I just remapped them to be available in all modes
- phyzome 8y agoHaha, gloriously hacky.
- wodenokoto 8y agoIs it possible to have the 2 keyboards plugged in with different layouts in windows?
- sevensor 8y agoThere's also the emacs pedal: https://www.emacswiki.org/emacs/FootSwitches https://www.emacswiki.org/emacs/FootSwitches
- mrkgnao 8y agoI mean, if a piano (or something closer to a Tonnetz[0] layout) is okay, why not a full organ with >1 keyboard and pedals? :) [0]: https://en.wikipedia.org/wiki/Tonnetz https://en.wikipedia.org/wiki/Tonnetz
- pavel_lishin 8y agoI've seriously considered getting some sort of foot pedal arrangement, albeit mostly for FPS games - I'd love to be able to use one foot to melee attack, and another to activate/deactivate the mic.
- test6554 8y agoThey need a kick animation.
- sodaplayer 8y agoI’ve tried repurposing a three-button guitar footpedal for FPS games before. The connection for the pedal is TRS, with one button being ring, another sleeve, and the last both—so it ended up being useful for only two commands as the last button would be ghosted by pushing the other two simultaneously. I used the pedal for left and right leaning and with melee in the center, but with the ghosting, I ended up dropping melee and just stuck with using it for only leaning. I used an Arduino Pro Micro which supports acting as a keyboard and just soldered a TRS socket so I could just use a regular TRS cable to hook up the footpedal. It’s a bit satisfying once you get it working and the project didn’t cost too much—maybe about $20 (found a cheap used footpedal) and enough games use “q” and “e” binds that I get to use it a bit.
- mindslight 8y agoSomething I've been wondering and casually looking into: besides another whole keyboard, what other keypad-like layouts/devices are there? What I think I want is another row of F-keys above the ones that are there (I use these to switch between windows). Of course I now use a TKL, but never warmed up to the idea of using the numpad for this. I think part of me just doesn't like the idea of repurposing keys with strong meanings. I've pondered getting one of those pads used to drive music software. The Elgato Stream Deck mentioned elsewhere in this thread seems quite interesting (to look into when I have more time). Any other pointers? Also related: I'd really like to try a wireless chorded keyboard for mobile use.
- CarVac 8y agoYou could get a terminal Model M or Model F, the 122 key kind.
- mayoff 8y agoX-Keys makes a variety of USB key pads in various shapes, including single rows of 4, 8, or 16 keys. http://xkeys.com/XkeysKeyboards/index.php http://xkeys.com/XkeysKeyboards/index.php
- thecrumb 8y agoAlso see Genovation https://www.genovation.com https://www.genovation.com
- 83 8y agoI use an Ergodox Infinity which has 'layers'. All keys are programmable and you assign keys to toggle/activate a layer. Its essentially extra shift keys - one layer turns my whole keyboard to symbols and another makes the home position for my right hand a num pad without having to move my hand. Pretty slick once you have it setup and get used to it, takes a lot of work to get there though.
- jenscow 8y ago> All keys are programmable and you assign keys to toggle/activate a layer. Hmm, it's possible to do this with any keyboard. Find a key that you never/hardly use and bind that to running the command which toggles the layout. Thanks for the inspiration.
- vemv 8y agoThree modifiers are enough: Command, option, control. Easy on macOS, possible on Linux: (setq mac-control-modifier 'super) (setq mac-option-modifier 'meta) (setq mac-command-modifier 'control) I never have to resort to using two modifiers at the same time (e.g. Command + Option), as said 3 individual modifiers are plenty. I also never use C-c or C-u prefixes, or other emacs-isms. Everything is a single combination, which is fundamentally simpler and more ergonomic. For rarely-used commands, I just `M-x the-command`. Better than assigning complicated or easy-to-forget shortcuts.
- Scarbutt 8y agoso you rebind lots of key chords?
- vemv 8y agoThese are (almost) all of them, I'd say it's a bearable amount: https://github.com/vemv/.emacs.d/blob/master/lib/non-submodules/vemv.shortcuts.global.el https://github.com/vemv/.emacs.d/blob/master/lib/non-submodu... (also some are redundantly rebound, like left-key to left-char. I do it for... reasons)
- nickdrozd 8y agoDon't forget about the hyper key! (setq mac-function-modifier 'hyper)
- bitwize 8y agoDouble bucky, an additional keyboard or two... (see: http://www.art.net/~hopkins/Don/text/double-bucky.html http://www.art.net/~hopkins/Don/text/double-bucky.html)
- Analemma_ 8y agoHeh, his feels like what happens when an Emacs user gets mocked by the vi crowd and decides to just own it. Good for him.
- sleepybrett 8y agoA little more complicated, but a lot more versatile. I had a similar issue, where I wanted a large amount of extra keys for macros/hotkeys. I bought a planck kit from olkb (https://olkb.com/planck/ https://olkb.com/planck/) (which is just one of many keyboard kits that will run the QMK firmware (https://github.com/qmk/qmk_firmware) https://github.com/qmk/qmk_firmware)) built it and rewrote the keymap to output my special keys. Later I went on to wire up a couple simple industrial style footswitches to a cheapo arduino pro micro clone and put qmk on there. A few other interesting and smaller keyboard kits can be found from vendors like https://www.1upkeyboards.com/ https://www.1upkeyboards.com/ (the sweet16 macropad/keypad) and https://keeb.io https://keeb.io (the chocopad or just half of any of their "ortholinear" split keyboard pcbs.
- 1996 8y agoIf you need a second keyboard to use your text editor, maybe the problem is not the keyboard, but the text editor. yes emacs is more than that, but with f1-f12, ctrl,shift,alt and their various combinations to the alphanumeric keys, it seems a bit overkill to me. If you still need more keys, you can also get a JP keyboard with extra modifiers conveniently located next to the spacebar.
- deleted 8y ago[deleted]
- deleted 8y ago[deleted]
- databus 8y agoIs it possible to do this on Mac? Have a second, external keyboard mapped to a different language than the primary keyboard?
- Kagerjay 8y agoWith lua + autohotkey scripts in windows this is definitely possible the last time I checked. You run a luascript on another keyboard mapped to a generic key, luascript inputs that as the proper text-based language There's a tomscott video on it https://www.youtube.com/watch?v=lIFE7h3m40U https://www.youtube.com/watch?v=lIFE7h3m40U Checkout Teran van Hemert (linustechtips editor) for some potential ideas too. He's got crazy macro schemas, I've used a couple of his and there great. All windows based as well though. https://www.youtube.com/playlist?list=PLH1gH0v9E3ruYrNyRbHhDe6XDfw4sZdZr https://www.youtube.com/playlist?list=PLH1gH0v9E3ruYrNyRbHhD... Mac, I can only assume its something you would write in applescript. But maybe you find some interesting ideas there. I found something called "http://www.orderedbytes.com/controllermate/" http://www.orderedbytes.com/controllermate/" that might be of interest to you
- naveen99 8y agohttps://autohotkey.com/boards/viewtopic.php?t=45307 https://autohotkey.com/boards/viewtopic.php?t=45307 http://www.oblita.com/interception http://www.oblita.com/interception
- egypturnash 8y agoYou could use Karabiner[1]. No need to do the “different language” hack, just make a big pile of key remappings that only affect that particular keyboard. It’s pretty easy to target just one input device with that. 1: https://pqrs.org/osx/karabiner/ https://pqrs.org/osx/karabiner/
- nerdponx 8y agoDoes Emacs distinguish between "left" and "right" modifiers? If so, you could (ab)use those to effectively create 4 extra prefix layers.
- agumonkey 8y agosoon emacs-organ
- girzel 8y agoHmmm, with pull-stops to activate various minor modes...
- melse 8y agoReminds me of this https://www.jwz.org/blog/2016/09/searching-for-finally-got-my-emacs-setup-just-how-i-like-it-yields-excellent-results/ https://www.jwz.org/blog/2016/09/searching-for-finally-got-m...
- tekacs 8y agoSince jwz dislikes HN, most users will want to use this link instead: http://archive.is/z8VCZ http://archive.is/z8VCZ