by im_down_w_otp · 4y ago · 0 comments
I've been full-time Linux (Kubuntu) for a few years now, and I've hobbled together something that only irritates me to death about 30% of the time rather than the 100% of the time it used to before spending days and days fiddling with a bunch of different flavors of remapping at nearly every layer of the system.
If I'm ever fabulously wealthy, I already know I'm just going to finance an open source fastidious spiritual successor to MacOS 10.6
I'm going to give Pop_Os a try, but I suspect I'm going to run into the same problems I always do. The trouble with Linux as a desktop for me isn't weather it's beautiful or not. The problem is how disintegrated everything is and the thousand papercuts ways in which it works.
That said, I absolutely consider it basically an incredible miracle that the experience is as good as it is, frankly. So, I keep at it.
So, along with consistent keyboard shortcuts, I'd like to add consistent and configurable mouse/trackball actions (some apps scrollwheel goes up/down, others it zooms, some support pinch zoom, some don't).
- Latest update (December 2021): https://www.gitclear.com/blog/linux_touchpad_update_december...
- HN: https://news.ycombinator.com/item?id=29555822
So far, pinch-to-zoom has been implemented in Firefox. (If you are using X11 instead of Wayland, then the environment variable MOZ_USE_XINPUT2=1 needs to be set.) Gestures for back/forward navigation have not been implemented yet (Firefox Bugzilla issue: https://bugzilla.mozilla.org/show_bug.cgi?id=1539730).
The project aims to support gestures in other Linux apps, too. If you would like to help fund this project, the developer has a GitHub sponsor page here:
But thanks for the link, I'll check it out
If this was MacOS, I'd agree. But on Linux, it's a different hardware landscape. There are hundreds of trackpads that Linux is compatible with, but not every one of them is multitouch (or implements multitouch the same way). Gesture support on Linux has been a long time coming, but that's mostly because getting uniform trackpad support over thousands of laptops is just not a very fast process, whereas on MacOS, Apple can make certain assumptions about the hardware it's running.
In Windows and Linux clicking the trackpad with 3 fingers causes a middle click, in MacOS this is not an option at all. Moreover, enabling it is apparently a project so difficult that the cheapest solution[0] I could find costs €8 just to add middle click functionality, nothing else.
Bit of a tangent, but it's always funny to me to discuss ChromeOS and Android as distinct from Linux distributions. I get that they're each practically as "Linux" as TiVo (and might not even be that forever, depending on how Fuscia evolves), but it actually might help avoid confusion if we started using the term GNU/Linux unironically in some contexts.
Termux folks keep hitting walls, because they refuse to acknowledge these are the only APIs they are allowed to call.
https://developer.android.com/ndk/guides/stable_apis
So when they make use of other Linux stuff that according to Google are private APIs, things don't go well.
As for ChromeOS, the kernel isn't exposed to userspace in any form, which are basically Webapps.
Running Linux applications on Chrome OS makes use of a secondary distribution in a VM, pretty much similar to how WSL 2 works on Windows.
So they might use the Linux kernel, yet they are far away from being distros that can easily run the GNU stuff.
It is not the first time I hear this, so this OSX feature must be truly addictive & productive.
I don’t really like the snide nature of your comment, people care a lot about things like trackpad functionalities. Objectively, unix has been lacking in this department.
In my case (and I suspect many others) a case of muscle memory, which can take a while to retrain, so you move to a new OS hoping you can keep the same motions you're used to and just get your work done. It's also important if you regularly have to use multiple OSes (as some tech support people have to do, and when you need to test on different OSes)
And, for the life of me, I never get copy paste from a terminal to work like I want it to.
alt-tab is universal. Hell, alt-tab works on Android if you hook up a keyboard to it. Mac is the only thing where alt-tab falls on its face. Even if you remind yourself that you're on Mac and use cmd-tab, it cycles between apps, not windows. You need to use cmd-` for that. I often find myself in a cycle of using 3 windows across 2 apps and it drives me bonkers.
But alt on a Windows keyboard layout and and command on a Mac keyboard layout are the same key location, so I don't understand how you can be confused by this... maybe stop looking at the keyboard?
So if you work in an IDE, keep reading docs in one Firefox window and test your application in another Firefox window then in KDE or XFCE or another sane windowing system[1] - even Windows - you just use alt - tab.
On Mac you have to stop an think: Should I switch to another browser Window? Ok, that is CMD - backtick. Switch to or from IDE? That is CMD - tab.
Press the wrong combination? Now Cyberduck has entered the mix.
[1]:I was about to write Windows or Linux but starting with Unity and now also Gnome has copied this to be bug comptible with Mac
I ended up installing https://alt-tab-macos.netlify.app/ which adds a keystroke that will cycle through all windows in all apps on all spaces. It's a huge improvement.
(You can tweak this, if you need to, in System Preferences, Keyboard section, Keyboard tab, Modifier Keys... button.)
I'm an Emacs man. Many Emacs shortcut keys suck, but it's what I'm used to, so it's what I want.
Unrelated, I also use Hyperdock, from the same developer, to get the dock into the 21st century.
I also list alternatives on that page. That may inspire you
You can just use middle click everywhere, no? One checkbox in the clipboard manager and done.
Btw ctrl+shift+v to paste is often much more useful than ctrl+v, e.g. for emails, and is the exact same in the terminal.
Why can’t one switch between windows of the same application on MacOS with a modifier+tab combination?
I was stuck using the shortcuts (ctrl + left or right arrow key), or clicking the Mission Control button I had to pin to the Dock.
"Just swish your virtual desktops around" seems extremely convoluted when I just want to switch between different windows.
Doesn't command+c/command+v work?
I use emacs as well, but apple touchpads are good enough that frankly it's probably faster for me to just highlight text in iterm2 with the mouse (which is what I do). In emacs I use the standard C-spc shortcuts, though.
None of my work is particularly terminal-heavy, thankfully.
MacOS is able to keep this consistent because ctrl+c/v isn't mapped to copy/paste, and instead command+c/v is. If you really want, Linux is perfectly capable of mapping Super+c/v to copy/paste. You would probably only need to do this in your terminal emulator and your DE.
https://github.com/rbreaves/kinto
The proper way is remap the modifier keys and then remap further based on the app on focus. Gives you coverage whether you explicitly remapped an individual app or not.
I tried kinto on Pop about a year ago and it worked pretty well but conflicted with their workspace and tiling key commands so never tried switching to it beyond a single days worth of preview.
Like yourself, I also thought Linux would be capable, until you actually dig in to do it and realize it's a nightmare of different conflicts.
For starters, that super key is usually for the main menu/dashboard in most Linux os's and intentionally not easy to remap.
Then each application has its own key mapping, so even if you change the system copy/paste, chrome and any other app may have it practically hard coded - they are not all configurable and that includes most terminal applications.
Seems so simple till you dig in and try to accomplish it. In the end, the best solution was to find a terminal app where I could switch the copy command with the cancel command, and then I just have to remember when I'm on my Linux system, cntrl+shift+c is to cancel a command. 1/2 the time I use the system terminal though, and then the command is back to Linux native.
So now I have to remember that special terminal app to use, and that the cancel command is different, on top of the fact the key binding are on different keys also.
It is annoying as hell. And that is ultimately why I end up using my work Mac, even for personal stuff I would prefer to be on Linux.
Remapping the position of Control to the Super key just shuffles the annoyance around, unfortunately. I tried to live with it for a few months.
- Pretty much everything uses ctrl+shift+v for pasting without formating. Really useful for emails, Word, ...etc.
- vim does not use ctrl+c/v
- emacs (=Mac keybindings) also does not. Simply because their bindings predate IBM's ctrl+c/v
- middle mouse button works everywhere and can use the same clipboard (one checkbox)
I generally try to follow this pattern when possible.
But I really do wish that it was easier to get a consistent look and feel on Linux, including key bindings.
Point being it's more about use case matching than one option being the dark ages and another being The One Right Way™. Layer on that some like using clipboard history and others just want a single parking space and it gets even more blurry.
Regardless, from my experience, the terminal is the only place where Ctrl+C and Ctrl+V are not the standard shortcuts to copy and paste on Linux. These shortcuts seem to be universal everywhere else.
The biggest issue is that some apps don't play nice with the x clipboard.
Not to mention many Linux users hate having to use the mouse.
There are some interesting differences between them as well. When using the clipboard your application sends whatever you copied to the clipboard and pasting copies it out of the clipboard. With selection, however, the application merely announces that the user has selected something in that application. When you middle–click to paste, the application you pasted into must send a message to whichever application was most recently used to select something (relayed via the X server), and the reply contains the selected data.
https://www.x.org/releases/X11R7.6/doc/xorg-docs/specs/ICCCM...
¹ Actually, there are three³. CLIPBOARD for control–c/v, PRIMARY for selecting with the mouse, and SECONDARY for selecting with the mouse while holding down alt.
² But of course these two systems are implemented using the same messages to and from the X server. They simply have different conventions for how they are used.
³ Actually, there are as many as you care to implement. These three are simply conventional; applications are free to use other names to identify other communication channels.
⁴ … Profit!
Mind you, Mac has a similar annoyance with its command-C/V. If you work with Linux (+BSD) , Windows and Mac every day, as I do, be prepared to be frustrated a LOT.
I'd love if keyboards just had dedicated keys for this. It's used enough to warrant them (much more than other obscure functions like SysRq that do get their own key, or Apple's 19 function keys). I guess this is because I'm the DOS single task days there wasn't much of a need for copying and pasting.
The ctrl-z/x/c/v combination didn't exist when the Macintosh came out. The cmd+z/x/c/v existed on the Lisa (39 years ago!), so predates Mac by 2 years, which in turn predates Windows using by using ctrl-z/x/c/v by 8. Originally, Windows used the IBM CUA standard[0], which can still be used in Windows (KDE and Gnome came 13 and 16 years later respectively). If you're in a windows terminal, try ctrl+ins to copy and shift+ins to paste, works in Gnome and in KDE (with some remapping in Konsole.) Using ctrl-c in a *NIX based system seems like a dumb decision to me, since ctrl-c is SIGINT - kind of useful.
[0]https://en.wikipedia.org/wiki/IBM_Common_User_Access#Descrip...
Tilix, kitty, Windows Terminal and others support using ctrl-c for both copy-to-clipboard and SIGINT.
To me it's a game changer and judging from the sibling comments, pretty much no one knows this is a feature that exists. Ctrl-Shift-C/V is barbaric and I have opened issues and merge requests to implement it in other popular terminal emulators.
https://github.com/pkulak/dotfiles/blob/master/.config/alacr...
There's nothing stopping you from deciding to use Super+c/v as copy/paste instead of Ctrl+c/v or Ctrl+Shift+c/v. Apple doesn't use Ctrl+c/v either... they use Command, so the conflict you're referring to doesn't exist there either.
Put them in the place of "Scroll Lock" and "Pause/Break" or "SysRq".
I really wish I did not have to do that
Would it help if I point out that this is just rose tinted glasses? ;-)
Or at least, when I used Mac full time back in 2009 - 2012, it was the least consistent thing I ever used: even such basic shortcuts as moving a word forward or backwards was inconsistent. Same with home/end: in one app it would be CMD + arrow left/right, in another it would be fn + arrow left/right. In Safari CMD + left meant back which kind of made sense but was hugely annoying when I filed out a web form in Oracle Enterprise Manager or something, wanted to select to the start of the line and ended up leaving the form, discarding half an hours work.
(Yes, bad web application. Feel free to tell Oracle that.)
That said, I kind of like Apple when they aren't messing up keyboards physically or logically and aren't busy snooping in my pictures. I've convinced my wife to use iPhone and switched most of my kids phones to iPhones and even use one myself and have bought a Mac mini lately - it is good as long as one can take it slowly, one careful step at a time - definitely not something I'd want to deal with in anger or if my life or the customers data depend on it.
And consistent - it is not!
That said, on Windows and in Linux this is extremely much simpler and more consistent, I can write it down right here and now, it doesn't need a full web page:
arrow keys: move
ctrl + arrow left/right: move left/right to next word boundary.
shift + arrow left/right: select a character to the left/right.
ctrl + shift + arrow left/right: select to next word boundary.
So it wasn't jumping between words it was home/end.
I have recently started to use it for personal things though, but again just things that I can use all the time in the world for.
I tried installing a dev environment on it and it was instant frustration.
NixOS, by accident or intention, inherently circumvents this problem. It also has actual non-existent UX: you need to manage your own home-manager configs (for now, I want to change that). The maintainers have put good effort into being able to express tons of preferences in your nixfile (to the degree of Firefox plugins).
You may get nerdsniped by it.
having a global menu interface that presents a uniform structure for navigating applications to the end user with sane default keyboard shortcuts (but universally configurable) would be a -game changer-
it also opens the doors to novel ideas up like Command Palette-like UX paradigms. imagine changing the resolution of a graphic document with about ten keystrokes, and being able to work so seamlessly in all of your apps! it’s almost like a universal command interface that works in GUI apps… okay, maybe i’m getting ahead of myself.
> If I'm ever fabulously wealthy, I already know I'm just going to finance an open source fastidious spiritual successor to MacOS 10.6
i, for one, root for your financial success ;)
if and whenever i’m able to make the jump though, i would absolutely love to do the same. i would love to help organise and coordinate efforts towards it
Im a former Mac person and I really like it. Ticks all the boxes you've just said.
incidentally, KDE apps sometimes do expose global menus, and there is a shell extension for this on Gnome, but it didn’t work in 40 last i checked.
but yes, it is the perfect jumping point for the kind of workflow i desire :)
Really wish Linux followed macs example of using super instead of ctrl for copy/paste/etc in general though…
https://github.com/rbreaves/sorun
Have fun!!!
The config file for the curious.
https://github.com/rbreaves/sorun/blob/main/configs/ubuntu_b...
I suspect once I package it properly and make it available in various repos and app stores that it will get more coverage. Also Kinto is feature complete as far as I am concerned, only changes that happen now are mostly minor. May do a rewrite of some parts of it to make updates go smoother and allow users to retain their own changes easier but no major functionality changes or additions are planned at this time.
Works flawlessly on Windows and Ubuntu for me :-)
Makes life worth living! ;-)
I don't think that exists, does it? EXWM comes close, but it doesn't have the database.
I know, I know, I just said "someone" when I should do it myself.
https://github.com/mooz/xkeysnail
https://github.com/k0kubun/xremap
https://github.com/autokey/autokey
My advice is to skip the last one unless you need something truly complicated and a config syntax that is just insane regardless of your level of complexity imo.
Of course if you just want mac based keybinds to be done for you then use my kinto app.
Am curious now how well that works via xrdp then as xkeysnail & other uinput methods don’t.
How do you send a break on a mac terminal? I didn't think it was any different.
and you can change that if you want in your terminal emulator. I modified some of my xterm's defaults using stty (I didn't change ctrl-c though, but you can change it).
See Ktrl + alt or Kmonad
https://github.com/ItayGarin/ktrl https://github.com/ItayGarin/alt https://github.com/kmonad/kmonad
KDE apps are also universally very remappable