Stack And tile shortcuts/improvements

The user guide calls it “control”, “alt” and “opt”, because that’s what the menu shortcuts in the GUI say,e.g. ALT+Q to quit, OPT+ALT+G for the TextSearch add-on. The user guide goes with the defaults, if you change the command key from ALT to CTRL, you have to subsitute ALT<->CTRL mentally… :slight_smile:

I think we once proposed to have “CMD” instead of the “ALT” in the shortcuts icons, but can’t remember why that wasn’t done.

All that said, for me with a German keymap it works very well as is. It’s the exact same experience as under Linux or Windows, just with the menu shortcuts being ALT, not CTRL (which I could change in Haiku, but won’t).

1 Like

Yes, it works for the left side of the keyboard. But you can trigger Stack and Tile with AltGr, and shortcuts with the right Windows key. It seems in reality very few people use these right-side keys and so no one really notices? But that’s how it is currently.

I do. I also use Alt Gr as a “Compose” key in Windows to map to graphics that are not natively on the keyboard and that requires an ALT+CODE sequence. For example, I have -, –, — all mapped to the “-” key accessible thru Alt Gr “-” and Ctrl Alt Gr “-”.

On a side note. In my initial proposal I mentioned the IBM Model M and the Sun keyboards for a reason. The IBM Model M because it has no “Win” key and the Sun keyboards because their Type 5-7 keyboards are the perfect keyboards to support to test most available keyboard functions that are out there. If Haiku can support an IBM Model M and Sun Typ 5-7 as intended, it will support most keyboards.

https://deskthority.net/wiki/Super_key
https://deskthority.net/wiki/Alt_key
https://deskthority.net/wiki/Alt_Gr_key
https://deskthority.net/wiki/Compose_key
https://deskthority.net/wiki/Option_key
https://deskthority.net/wiki/Sun_Type_6

1 Like

And that is plainly wrong. Please read the deskthoroty links in my above post. It describes why the current naming in Haiku is wrong. It is probably the root of the confusion and needs to be corrected. In my guideline proposal I have included “Do not copy bad behavior.”. This is bad behavior that needs to be eradicated.

Control, Alt (or Option) and Super (“Win”, “Command”, “Meta” etc) is the commonly used terminology. To my knowledge there exists no keyboard with a “control”, “alt”, and “opt” layout.

2 Likes

Well, I disagree. As long as the GUI of an app states a menu item is invoked wth ALT+W, the user guide says that and is correct in doing so.

And the GUI menu code shows Alt or Ctrl because that is the actual key names used for Command on 99% of keyboards Haiku users will use (depending of course on whether the user has selected Alt or Ctrl as the Command key.) So even though it is B_COMMAND_KEY in the code I don’t think it should necessarily be switched to CMD in the menu graphics.

I haven’t tested any Mac keyboards with Haiku yet (though I do have one and will try it when I can), but as long as the default mapping there is to have Command be B_COMMAND_KEY then I think we are fine. Of course most people will use Windows keyboards.

While we are discussing this the main gripe I have about our keyboard shortcuts is that the Twitcher is Ctrl-Tab in the default layout, just so that it becomes Alt-Tab when people switch to Windows mode. No OS uses Ctrl-Tab for this (and in fact Ctrl-Tab has some nice in-application switching on several applications like Firefox or VSCode) and IMO we should find some way to make it always Alt-Tab no matter what the user selects for the command key. Of course I did look into this before but changing it isn’t easy with the current code which basically hard-codes a lot of the logic. It might not be doable in a nice way without adding that keyboard shortcut abstraction layer I mentioned earlier in this thread. Anyhow this is already getting even more off topic I suppose.

Did you ready any of the links I recommended?

I don’t see how they relate to my answer to Adrien about why the user guide decribes accurately the status quo of the Haiku GUI.

I doubt he’s arguing the user guide should not reflect what the GUI is currently showing.

Option key

In Haiku there is no key “Alt” in Windows or Linux sense. In Haiku “Option” is the same as “Option(Alt/AltGr)” in MacOS or “AltGr” in Windows and Linux. And “Option” cannot be used by itself for shortcuts with printable characters, because those are used for 3th level of keyboard layout, needed for input characters used by other languages. Also “Option(AltGr)+Shift+PrintableCharacter” cannot be used for shortcuts (“AltGr+Shift” is used by 4th level of keyboard keymap).
If Haiku GUI or documentation reports shortcuts with “Opt” or “Alt” and printable characters this is wrong and this is a bug.

Command key

Command key is the same as Command key in MacOS or Win key in Windows or Super key or OS key in Linux. And by itself should be used only for OS shortcuts.

Control key

Control key is the same as in other OS’s. And by itself should be used only for applications shortcuts.

1 Like

The information from this thread has been excellent! It clearly shows that the current implementation is a mess, is not compatible with any existing keyboard norm and that no one seems to really understand it. The first thing I have to do is to correct the naming and usage of the modifier keys. If @PulkoMandy’s information is correct, it is bad behavior inherited from BeOS that needs to be corrected.

I wanted to avoid changing to much, since more changes means more work. But in this case it must be done.

1 Like

If the name of the modifier keys change from commands, shift, option and control, please give me a heads up so I can update the corresponding documentation and settings in Emacs.

Thanks in advance.

The command key (called B_COMMAND_KEY in the API) is shown as ALT both in the GUI (shortcuts in menus) and the userguide (because the userguide matches the GUI). But it is shown as CMD in keymap preferences.

1 Like

Now its clear. Those ALT entries need to be corrected to CMD. Or maybe the Haiku team has any other ideas?

1 Like

Can we in Haiku emulate ALT (plain Left Alt or Right Alt) key with CMD+OPT?

No! Alt should be named ALT (“PC” naming) or OPT (Apple naming).

Ctrl = CTRL (Control).
Alt = ALT (Alternate) or OPT (Option).
Cmd (Command), Win, Meta, Amiga etc = SUP (super).
Alt Gr = ALT GR (Alt Graph).

Alt != CMD.

Note that the ALT and SUP (Command, “Win”) keys are switched between “PC” style keyboards and Apple style keyboards.

I’ve done keyboard layouts for those systems, and I’m speaking from experience with how keyboards work. The only difference between Mac and PC physical keyboards is that the ALT (OPTION) and WIN (COMMAND) keys are swapped.

If anyone knows better, correct it.

I’m not saying “ALT == CMD”!
I say there is an error in the Haiku GUI and documentation: the CMD key is called ALT.

We don’t meed to mimic Windows or Mac. I think that Alt = Command is fine. Maybe someone will make Haiku native keyboard where Alt key will be labeled as Cmd and no Alt key at all.

I’m not advocating for copying neither Windows nor Mac. That is something you have made up.

I’m advocating for not copying bad behavior (the key mappings inherited from BeOS) and naming the keys after how they are named on the keyboards.

I think you are talking about using the “PC” ALT key as the “Command” key on an Apple keyboard, where it is used for Cut/Copy/Paste etc. I see no problem with that, which I have said several times in this thread. But do not call the ALT key “Command”. Call it ALT, like it is labeled on the keyboard. Not doing so is confusing for everybody.

1 Like

Alt = Command is fine

No. That is wrong.