How many keys does your keyboard actually need?
TL;DR: 31.
What?
10 keys for each of the 3 rows at the center of the keyboard plus a space-bar (or thumb key) is all you need, which makes it 31 keys.
How?
By using a couple of patterns, namely Home Row Modifiers (done properly) and SpaceFN, as well as a couple of layers: Extend (navigation and editing) and Fumbol (functions, numbers and symbols).
Why?
- So you can touch-type all keys, not just letters and basic symbols;
- So you don’t have to move your hands much and can make better use of your stronger fingers;
- So you can transition to a split, column-staggered, ergonomic, 34-key keyboard (or anything in between) and still be able to use your laptop’s keyboard with ease while remaining productive.
Interested?
Check out the Kenkyo keyboard layout.
Long version
I have earned a living as a software developer for 15 years and have used computers, and therefore keyboards, for about 30. But I had never questioned the design and format of keyboards until the pandemic hit. It was a time of introspection and learning. This is the story of how I have used the knowledge I gradually acquired since then to put together my 31-key, layered keyboard layout: Kenkyo.
The Extend Layer
I came across it while looking at DreymaR’s Big Bag of Tricks a few yeas back. That was the first time I heard about layers. I thought it was a great concept, but I did not try it straight away. It was after learning about kmonad that I remembered it and attemped to implement my own variant for the first time. Following the Colemak community’s guidelines, I chose to bind it to the CapsLock key.
My Extend layer has gone through many changes, but I have found it so intuitive and useful that it has never crossed my mind to let go of it.
The Fumbol layer
Once you learn about layers, one of the first things many of us think about is making one that can host keys like functions, numbers and symbols. I know because I have found online all sorts of creative takes on that same problem. I decided early on I just wanted to keep it simple and intuitive:
- The top row would contain the function keys;
- the home row would become a number row;
- and the bottom row would host other symbol keys that were hard to reach… and some media keys just because there was some spare room.
I also wanted to be able to stay on the layer temporarily in order to type sequences of numbers, and sometimes symbols. It became clear that I had to bind it to the only proper thumb key available on a standard keyboard: the space-bar. I later learnt this pattern was once known as SpaceFN. But it turns out it is not a trivial pattern to implement and presents similar challenges to those of the pattern we will discuss next.
Home Row Modifiers
As the name implies, home row modifiers (or HRMs) put keys like Ctrl, Shift and Alt/Option on the home or center row of the keyboard. They achieve this by distinguishing between taps and holds, which would result on a character being emitted or a modifier being activated respectively.
Sounds easy? Well, it’s not. Many of us are faced with a daunting sense of frustration when we try to put them in practice for the first time and abandon them early on. Unfortunately, the are many barely usable implementations out there that have given HRMs a bad reputation. But if done properly, HRMs can become an essential tool. It took me a while to figure out what makes a good implementation:
- Prior idle time: make sure you HRMs are skipped if a key or sequence of them has been pressed recently. This is how you can avoid misfires while you are in the middle of typing. This will also drastically reduce the perceived lag when you are typing as no evaluations are taking place and the key codes are emitted immediately. Good keyboard customization tools can do this: kanata with switch and key timings; keyd with overloadi; ZMK with require-prior-idle-ms; and finally, as I found out on the day I’m typing this, QMK with the Tap Flow module.
- Trigger on release: another technique that can also prevent misfires caused by key-rolls is to only activate an HRM if the modified key is both pressed and released before the HRM itself is released.
There are other interesting techniques, like Bilateral Combinations, but I believe that applying the precautions explained above and adjusting the timings to suit the typing style and speed of the user are sufficient to minimize frustrations and rip most of the benefits of HRMs.
31 keys
I went through many iterations to integrate the patterns described above into my layout. I only managed to reduce the number of keys to 31 after I realized I did not really need to make the CapsLock key useful. Many will passionately tell you how it is in a privileged location and it does not deserve it. However, if you turn it into something too useful instead, it will be your pinky finger who will suffer.
Therefore, I decided to try binding the Extend layer to the space-bar. After all, I knew it was the layer I use the most. But how could I access the Fumbol layer quickly and easily when I needed to?
As I had now plenty of unassigned keys on the left side of the Extend layer now (my pinky had been stuck on CapsLock so I could not reach them in the previous arrangement), I used one to swap the Extend layer for the Fumbol layer until I released the space-bar. This was great for when I needed to stay on Fumbol to type a series of numbers and/or symbols, but it felt like too much work when I just wanted to enter a single symbol or press a function key.
Then I remembered a technique some use to cope with their frustration with HRMs: Bottom Row Modifiers (BRMs). After some trial an error, I placed a pair of Fumbol Layer Modifiers on the V and M keys of the bottom row. While I was at it, I added an AltGr and a redundant Ctrl modifiers as well, which permitted me to perform all sorts of key combinations not only on the main layer, but on the Fumbol layer as well.
And that is how Kenkyo ended up only requiring 31 keys to do it all.
Conclusion
There is something about being able to rely solely on motor memory that makes typing pleasurable.
I used to think that using a tiny keyboard was an extravagant thing to do and wasn’t really practical. But I can now see that, if done right, most of the things one may do with a traditional keyboard can be done more efficiently and comfortably with a proper layout and way fewer keys.
I have recently acquired my first 36-key keyboard and transitioning to it using Kenkyo couldn’t have been easier. My new keyboard supports QMK, but I can’t find the motivation to go through the learning process that would lead me to replicate my layout using firmware because, even if I get it right (which is not certain), I won’t be able to make use of it with my laptop’s keyboard.
I hope some of you find this interesting and useful. Thank you for reading.