-
Notifications
You must be signed in to change notification settings - Fork 217
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conflict between General GUI and Sublime Text #702
Comments
I feel like this is a good argument for some more metadata on keymaps... so we might say "this one is broad DE/GUI, etc" and that would allow other keymaps that say "i'm more specific" to automagically lay new keys on top... Like in this case it's obvious that Sublime Text (a single app) is more specific than "the whole desktop experience"... but we currently have any way to codify that (without extra out-of-order keymaps). |
Actually if none of application combos mess with the General GUI combos then really General GUI should come LAST, after all the apps - so that it doesn't override any of them... I think that would be much safer too. Right now General GUI can send the wrong keypresses into any app "accidentally" even if that app itself handles that key already... are there examples where this could have a really bad outcome? I'm not sure... it seems far safer to let the apps override "General GUI" if you're inside that application - then it's combos win. I'm not sure if this would break any existing things. There doesn't seem to be any rhyme/reason to the existing order of keymaps (that I can see)... |
Or is this a case where the Kinto script (had I run it) would have commented out some of those lines? i didn't know it did that - I assumed it only UNCOMMENTED lines... |
I have argued for this in the past. I've run into this issue with some terminal shortcuts. At present, in order to get a few terminal shortcuts working, there has to be a small secondary |
And I believe my reasoning has been what sits in General UI ought to be truly universal in that those hotkeys don’t change or get over ridden by other apps in macOS - because developers clearly know what the OS level key maps are & either can’t or won’t supersede them. Granted that means some apps will seemingly lose their hotkeys in Linux or Windows till they are corrected but things like wordwise hotkeys are non-negotiable & should work throughout. |
I feel we're talking about two entirely different things. There are so many different facets here it's hard to discuss.
Full-screen is not an Mac OS-level shortcut on Apple OS in the same way that say, Cmd-Space is. Apple's own apps have even had different hotkeys for full-screen over the years- not to mention what 3rd party apps do. Apple's own apps have inconsistent shortcuts in other areas as well... this is likely because "full screen" isn't a common experience on Mac OS... there are variations in HOW the app is full screened that only the app can know - does it fill ALL monitors? Does it blank some monitors? etc... _We should be very careful in differentiating what is "OS-level" - keys that the Mac "window manager" or Dock owns... vs what are merely strong conventions.
Finally, we're not talking about "overriding" anything here on the MacOS side... This issue is consistency on the Mac OS side - to deal with the lack of consistency on the Linux side (which is an impossible problem and not something we can change or fix).
What we want it to do:
As I've already pointed out even on Mac full screen shortcuts have not always been consistent... but in this case we're talking about perfect consistency - on the input side - which is what we should be caring about. I don't see how this is "overriding" any thing at all... The fact just is that there is nothing magical about Alt-F10 on LInux... at BEST it's a common convention that some (not all) WMs have agreed upon... it's obviously not universal when it comes to applications, or this topic wouldn't have come up. Moreover, we already acknowledge this inside "General UI" that LInux shortcuts are NOT consistent at an OS level... take for example:
Pop OS and Fedora have very different keys for "change workspace"... but we shoudln't care about that... what we should care about is the "mac side" experience... which we achieve by mapping those keys to the correct keystrokes in linux. I don't see why this would be true at the DE level but not true at the application level. My understanding is that if it's possible with the keymapper the goal is highest fidelity (vs a real Mac)... That is exactly what this issue is proposing - that we fix our Mac side to behave exactly as it does (most often) on a real Mac. I'm not sure what the argument would be against that - I thought that was the entire point of the project? And it's all done withing the keymapper... |
I'll acknowledge there is a small technical issue here that changing the sequencing might potentially allow apps to override "General GUI" in the future in negative ways - ways that would break the consistency of the "Mac side" experience. Though that is clearly not what is requested here. To that objection I'd simply point out that we own the file. Making sure someone doesn't come along later and add a I don't really see that becoming a huge issue, and it's also something we could easily police with software if we were truly worried... just off the top of my head, split General GUI into:
Things like app-switching behavior could remain in the OS-level keymap (at the top of the stack)... things that were looser conventions that sometimes apps need to override could be moved into "common conventions" at the bottom. That's not the only solution, but would be an easy one - if we were super afraid that just managing this during PR review was going to be problematic. |
Worse yet right now we're super consistent.
All these are allowed to potentially override General GUI (and in some cases do) - why is Sublime Text 4 excluded from the party? It's clear there are plenty of things in "General GUI" right now that are not OS level... because we already allow some applications to override them... like "RC-Left" (just to give one example). |
Sorry I get passionate and wordy about things. :) |
Seems this is not consistent across time and the larger matter (going full screen) requires a new issue, which I'm making now. |
Welcome to the club. It's good to get fired up sometimes. You must type at least 100wpm too. You're absolutely right that the goal is to provide the same consistency we enjoy while using an actual Mac. And Kinto has generally done a remarkable job at that. Anyway. As we all acknowledge in different ways, there are collisions and inconsistencies when trying to bring Mac shortcuts into Linux/Windows. But for the moment there is a simple solution to this kind of overlap that is stopping the Sublime override from working. The "General GUI" block should be at the very end of the config file. There's really very little overlap with other blocks, even the terminal block has only needed a couple of overrides, everything else in that block works fine, hence there is no conflict with the general block, so reversing the order shouldn't be an issue. So there's no good reason that I know of not to move everything above "General GUI" until a more flexible method of precedence can be developed. It's not really going to harm the "General GUI" shortcuts. Unless I'm really missing something. And leave a note at the end of the file that no new keymaps for specific apps should go at the end of the file, but rather somewhere above "General GUI". To avoid this kind of failure to override a general shortcut. There should actually be a clearly designated area somewhere in the config file where users are encouraged to place their own custom app keymaps. When I put mine in I just sort of picked a spot with somewhat related apps. Like when I stuck the Finder Mods in right above the browsers keymaps. Yeah, people may make mistakes when adding custom shortcuts and somehow step on a general shortcut, but our job is just to avoid those mistakes in the default config file so things at least start out making sense. And come up with a better solution for protecting specific system-wide shortcuts later. Keep it simple. Re-order the blocks with "General GUI" last and everything will be fine. For now. |
To be clear I don't think #709 is a blocker for this issue. |
I’ll try & get around to doing more testing later & re-arrange the code blocks to see what I think. I can’t really get as wordy at the moment in my response but I’ve mostly read your argument & yes the point of Kinto is to be mac accurate & for the user to not need to concern themselves w/ which distro or de they are using. |
Re-arranging should have no visible/noticeable effect at all unless you already have other broken/overlapping keystrokes (below General GUI) - in which case they would start working... otherwise (if there is no combo overlap) the order shouldn't change any behavior. |
Describe the bug
There are conflicting combos:
And a valid Sublime combo (added myself):
I'm not sure what to do about this. They are both full screen so should we add a small keymap for Sublime in FRONT of the General GUI keymap to grab that keystroke when it's inside Sublime?
Right now keymaps are evaluated in the order they are defined, so it's finding the combo in General GUI and stopping there, but Alt-F10 isn't the combo that Sublime needs.
Expected behavior
The Sublime Text combo works.
The text was updated successfully, but these errors were encountered: