GNUStep, macOS, Linux and Keybindings

Published: 2023-03-26 10:30:30

Why I think the perfect Linux desktop environment doesn't exist.

GNUStep, macOS, Linux and Keybindings

I'd love to run GNUStep on my Linux machine simply because The NeXT heritage brings with it the only sane keyboard shortcut / keybinding system on the Linux desktop. Before I go on a tangent, let me link to NEXTSPACE 1 which is a CentOS based GNUStep OS. Sadly, since the author is from the Ukraine, all development has halted since last February :( I hope he is ok.

Now the keybinding tangent: If you're not rolling VIM keybindings in the whole desktop (which is tricky for non-modal interfaces and alienating a large amount of users), the next best ergonomic keybinding scheme is the Emacs / Gnu Readline system 2. It allows moving the cursor without having to move hands around (e.g. going to the arrow keys, coming back to the alphabetical keys). It is one of the base tenets of unix systems. Every terminal supports it. Yet, the whole bunch of Linux Desktop systems completely ignored these keybindings and copypastaed the Windows concept instead, coming up with a weird chimera of readline in some places, and half-windows, half-self-invented in others.

Gnome used to have an Emacs compatibility mode that was somehow off by default and had to be enabled in a tweak. It was removed with GTK 4 however. If you want to do that in KDE, you have to run a weird python daemon, and half the apps constantly stop working because they key codes are being messed with.

MacOS on the other hand, supports these keybindings in every input dialog, it is a pleasure to use. Even more so, to have the same keybindings in every app and not having to learn new ones on a per-app basis.

Of course, running weird python key code daemons runs into the other problem that macOS & Gnustep solved in a much nicer way: By copying the shortcut system from Windows and patching it on top of Readline, many shortcuts have double entries. Printing is CTRL-P, but so is readline "Previous Line". macOS and Gnustep solve this by having a separate key for app actions: Command (or Hyper or Alt). So print is Command+P. Everywhere. Previous line is CTRL-P. This is always my go-to Linux joke where "Copy" is "CTRl-C" everywhere, except in the Terminal, where it's CTRL-SHIFT-C because yeah, CTRL-C has another meaning. Talk about a sane shortcut system if apps have to use different ones per shortcut because the amalgamation of Windows Shortcuts + Readline is a match made in hell.

In the end, it is really about habit.

For context, I've used Desktop Linux from 1996 till 1998, 2002 till 2007 and tried again for the past two years with a Ryzen desktop.

The main reasons that bring me back to macOS (apart from the M1 / M2 hardware):

  • I much much much prefer the macOS keyboard shortcut setup. Command+C works everywhere. On Linux, Ctrl+C works most of the time, but sometimes it's Ctrl+Shift+C or something else. I run into this far too often because I'm a create of habit.

  • I also enjoy that basically all apps adhere to the same keyboard shortcuts. E.g. Command+T for new tab works not just in Terminal, but in every tabbed app.

  • I haven't found a way to customise Gnome or KDE so that application switching with Expose / Mission Control works as fluid as on the Mac. I use this all the time to go to different windows.

  • I like that the package manager is separate from the operating system. More than once have I run into a Linux situation where I had weird package conflicts and it was super tricky to get out of it. With Brew I just reinstall it and I'm done.