5 ms·
> It is a literal (as in both printed on the key and referenced in the OS/docs) key on a Mac keyboard with, you're just confused by the fact it also has another
by camgunz 3y ago
> It is a literal (as in both printed on the key and referenced in the OS/docs) key on a Mac keyboard with, you're just confused by the fact it also has another name.
I feel like we're in a weird place in this discussion. AFAICT no keyboard Apple currently ships labels Option as Alt, though it is true they have shipped keyboards with this in the past. There's no need to condescend, or maybe you were just referring to PC keyboards and trying to bail yourself out here?
> Like what? If you just move 4 keys all the things will know, that's a system-wide rebinding.
Web apps don't know. Swap Control/Option and load up Google Docs. The binds they list don't take into account the swap, though the new binds work correctly. Also in iTerm2 Pointer settings the Cmd/Control/Option icons don't update. Etc. etc. etc.
> You've only provided a single example Ctrl-C example
My point is that it's always gonna be a little imperfect and maybe a lot of work. Let's say you did want to basically make iTerm2 function like xterm in Linux; what that means is Ctrl-C is cancel and copy/paste is done w/ the mouse. Well, you can't get rid of Command-C for copy, and you can't get the "copy on select" behavior either, so that's a bust. Let's abandon a Linux-alike and just add an App Shortcut for ^C -> Copy. Some terminals are smart enough to use Copy when something's selected and use Cancel otherwise, but Vim's isn't :(. Also if you have anything bound to Ctrl-C in those apps you lose the app's bind, and you don't always have a way to get it back. Pasting is another problem: if you bind ^V -> Paste, any terminal app that uses ^V as a keybinding (Vim again) will instead get whatever's in your clipboard.
> But also, if you recognize there are many clashes that need to be resolved via rebinding, then this "rebinding 4 keys is more work than rebinding 3." doesn't make sense, guess that's why you're confused again. Alt is germane precisely because rebinding 4 keys isn't enough since default keybinds work differently with these modifiers.
> it's easy to rebind the few terminal Ctrl keys to Cmd without moving those 4 keys around, and resolve only those direct clashes
You can't have it both ways. Either rebinding is easy or there are many clashes.
> But on a PC Alt is used for some common operations, so if you move Ctrl to the more convenient thumb location, you'll have to deal with moving some of those keybinds, so resolve clashes that potentially touch more apps/keybinds than just terminal keybinds
Great, the Alt you were talking about is for PC keyboards. That's what I thought; dunno why we had to go deep into like, API docs for macOS. Sometimes people goof! That's OK! Now I see what you meant here. Yeah but like, welcome to more rebinds across more apps.
---
AFAIK people use Karabiner to pretty good success here. I've never tried it. Maybe it makes everything easier, or maybe you've got one more fiddly thing to maintain.
[0]: https://www.apple.com/shop/product/MK2A3LL/A/magic-keyboard-us-english https://www.apple.com/shop/product/MK2A3LL/A/magic-keyboard-...
[1]: https://www.apple.com/ipad-keyboards/ https://www.apple.com/ipad-keyboards/
- eviks 3y agoYeah, the fact that you've never tried Karabiner explains a lot of why you keep wrongly insisting things are impossible > Swap Control/Option ... the new binds work correctly That means the web app knows. Or do you want it to show the wrong keycap labels instead of the correct key function names? > Well, you can't get rid of Command-C for copy You can. Depending on the terminal you can do it either in the app or in Karabiner > can't get the "copy on select" behavior Think that's also possible, maybe not in iTerm, though how is this relevant when we're talking about keybinds? Obviously you can't have two functions per key 100% (below 100% you can have context-dependency like selection), so I don't understand what your perfect baseline is? No matter where control physically is you'll still have this issue that you can't use it to copy and cancel in the same context, so the fact that you'd need to resolve a conflict in Cmd is not an argument for any position. > but Vim's isn't But you can detect vim and use Cmd+C to pass Ctrl+C to it, so you'd retain vim's dumb behaviour just like you'd have with the original Ctrl+C, so there is no functional improvement, just ergonomic one (though this is more complicated) >lose the app's bind, and you don't always have a way to get it back you can always send the original Ctrl+C key event instead of "Copy" with a different keybind, so you'd retain that function > You can't have it both ways. Either rebinding is easy or there are many clashes. I can: 1. It's relatively easy in one case of the terminal app where you move Ctrl+X keybinds to Cmd+X and resolve a few conflicts 2. There are many clashes if you do it another way and move keys around at the OS level. And the amount of clashes is OS-dependent, and the reason it is due to Alt (including Mac's Alt) > Great, the Alt you were talking about is for PC keyboards. That's what I thought; dunno why we had to go deep into like, API docs for macOS. Sometimes people goof! That's OK! Now I see what you meant here. Unfortunately, you're still confused, but trying to persist in your mistake too hard to notice. I meant both keys (Mac's Alt and Win's Alt), and the fact that they serve different functions on different OS explains how "defaults matter even if you change them", that's how Alt (includings Mac's) is relevant (also, it's not API docs, it's general user keyboard shortcuts help, why do you need to make even these things up?)
- camgunz 3y agoJust as a meta point here, you're really digging in to something that's pretty trivial. We're way to the right of the comments about... honestly I don't even know what. You're being condescending, sarcastic and pedantic. I'm not really even sure what you're trying to convince me of; can you plainly state your argument? Maybe you're deep into score points in an internet argument mode; if so I respectfully suggest pulling up a little. > Yeah, the fact that you've never tried Karabiner explains a lot of why you keep wrongly insisting things are impossible Huh I don't think I said anything's impossible. I've said things will clash or will be a lot of work, but in software all things are possible. I've been trying to define parameters around what you're saying. This is why I've been saying stuff like "if rebinding is an option then why do key layouts matter", which you've yet to explain. If installing 3rd party software and spending tons of time configuring it is an option, I think key layouts matter even less. I'm confused because you've yet to take a clear position on anything, instead you take small, generally inaccurate swipes at trivial stuff I write. >> Swap Control/Option ... the new binds work correctly > That means the web app knows. No, it means the OS is passing different key codes to the browser. > Or do you want it to show the wrong keycap labels instead of the correct key function names? When I swap Ctrl and Option, I want Google Docs to show Option when it would have shown Ctrl. That's how I'd know the webapp "knows". But it doesn't, hence why I listed it as a drawback of rebinding. >> Well, you can't get rid of Command-C for copy > You can. Depending on the terminal you can do it either in the app or in Karabiner How do I do this in iTerm2, a super popular terminal emulator for macOS? It only has a keybinding option for Paste and that only lets you create a bind. I don't see how I would use this to disable Command-C for copy. Again I'm not saying it's impossible--I thing I feel like I now have to say. You could hex edit the binary! You could redirect gamma rays to minute parts of your hard drive! I'm saying in the finite amount of time I'd want to spend on something like this, it doesn't seem straightforward. >> can't get the "copy on select" behavior > Think that's also possible, maybe not in iTerm, though how is this relevant when we're talking about keybinds? Isn't the whole point to "rebind it to make your experience 100% consistent"? You must have meant "consistent with other OSes". The reason Linux does copy on select is that's its solve for "Ctrl-C is cancel". > No matter where control physically is you'll still have this issue that you can't use it to copy and cancel in the same context... Phew! It took a while but, this is what I've been saying. Glad we agree. > ...so the fact that you'd need to resolve a conflict in Cmd is not an argument for any position It's the whole problem! macOS solves the "Ctrl-C is cancel" problem in terminals by having a whole different key for it. If you scooch it over to Cmd you'll find a host of problems that are irritating to resolve, which we're currently discussing, albeit in a super awkward way. > But you can detect vim and use Cmd+C to pass Ctrl+C to it, so you'd retain vim's dumb behaviour Woof this is a hot take. Vim's behavior isn't "dumb", it just isn't anticipating your super weird rebinding strategy. Also I don't know what you mean by "detect vim". >>lose the app's bind, and you don't always have a way to get it back > you can always send the original Ctrl+C key event instead of "Copy" with a different keybind, so you'd retain that function Of course; there's always something you can do. That's why I said "My point is that it's always gonna be a little imperfect and maybe a lot of work." But, in this case I don't think it's super straightforward. If you bind Cmd+S to Copy and then open up VLC you'll see there's no shortcut to save a playlist. Dunno what you would do about that. > 1. It's relatively easy in one case of the terminal app where you move Ctrl+X keybinds to Cmd+X and resolve a few conflicts I can't see a way to do any of this in iTerm2 or Terminal.app. > 2. There are many clashes if you do it another way and move keys around at the OS level. And the amount of clashes is OS-dependent, and the reason it is due to Alt (including Mac's Alt) Agree, but since this doesn't seem possible in the most popular terminal apps for macOS, I think this is what most people are forced into. > (also, it's not API docs, it's general user keyboard shortcuts help, why do you need to make even these things up?) Sorry then, what did you mean by "docs" here: "It is a literal (as in both printed on the key and referenced in the OS/docs) key on a Mac keyboard". I'm not making anything up; I'm genuinely trying to understand what you're saying, which after you being wrong, self-contradictory, and moving the goalposts for days seems to be: "Cmd's position is more convenient for the operations other OSes use Ctrl for, and you can spend a lot of time in Karabiner if you want it to function consistently with other OSes".