Skip to content
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

Use "Command" key rather than "Control" for global keybinds on macOS #13482

Closed
1 task
frenzibyte opened this issue Jun 13, 2021 · 6 comments
Closed
1 task

Comments

@frenzibyte
Copy link
Member

frenzibyte commented Jun 13, 2021


macOS users are used to using the Command key (superkey/windows key) for shortcuts normally activated with control, i suggest that osu! should check what platform its running on and switch the keys on macOS

Originally posted by @TMinusBlastedRocket in #13481

@bdach
Copy link
Collaborator

bdach commented Jun 13, 2021

This is already the case to a degree, is it not? At least framework seems to define platform actions in such a way.

@frenzibyte
Copy link
Member Author

frenzibyte commented Jun 13, 2021

Yep I've specifically mentioned "global keybinds" in the title as that's the place where this hasn't been done yet.

@peppy
Copy link
Member

peppy commented Jun 14, 2021

Can a list be provided here of which keys are currently an issue? I'm not sure if we should be changing all of them, so we should at least document which should be changed so someone attempting this gets it right.

@frenzibyte
Copy link
Member Author

Reading on the Apple Human Interface Guidelines, it states the following in the "Defining Keyboard Shortcuts" section:

As much as possible, avoid using the Control key as a modifier. The Control key is already used extensively throughout the system. To avoid possible conflicts, use it only when necessary.

So we may actually have to replace all of them with the Command key, as the Control key should remain for system-level keybinds only. That includes all of the global keybinds using that modifier:

new KeyBinding(new[] { InputKey.Control, InputKey.Alt, InputKey.R }, GlobalAction.ResetInputSettings),
new KeyBinding(new[] { InputKey.Control, InputKey.T }, GlobalAction.ToggleToolbar),
new KeyBinding(new[] { InputKey.Control, InputKey.O }, GlobalAction.ToggleSettings),
new KeyBinding(new[] { InputKey.Control, InputKey.D }, GlobalAction.ToggleBeatmapListing),
new KeyBinding(new[] { InputKey.Control, InputKey.N }, GlobalAction.ToggleNotifications),
new KeyBinding(new[] { InputKey.Control, InputKey.Shift, InputKey.S }, GlobalAction.ToggleSkinEditor),

new KeyBinding(new[] { InputKey.Control, InputKey.Shift, InputKey.R }, GlobalAction.RandomSkin),

new KeyBinding(new[] { InputKey.Control, InputKey.Shift, InputKey.A }, GlobalAction.EditorVerifyMode),

new KeyBinding(new[] { InputKey.Control, InputKey.Tilde }, GlobalAction.QuickExit),
new KeyBinding(new[] { InputKey.Control, InputKey.Plus }, GlobalAction.IncreaseScrollSpeed),
new KeyBinding(new[] { InputKey.Control, InputKey.Minus }, GlobalAction.DecreaseScrollSpeed),

new KeyBinding(new[] { InputKey.Control, InputKey.F4 }, GlobalAction.ToggleMute),

While it currently doesn't make much sense to change some of them, the current combinations used for the global keybinds are known to be over the place, and it may be better to mark that as a dependency for this, so nothing feels weird/incorrect when applying this guideline to the combinations.

But also while thinking about this, the key combination for switching rulesets (Control+Num) would have to change as well, to completely follow the guidelines there. Command+Num may not be right... Alt+Num? Alt+Shift+Num? not completely sure.

@peppy
Copy link
Member

peppy commented Jun 14, 2021

I think you're missing the point. All those global bindings are system keys. Also they are not used by macOS in any way, unless you count text manipulation (which doesn't work in a game in the first place).

Rather than blindly following a guide, I'd recommend actually understanding which bindings macOS uses the control key for. We aren't changing the ones that are not going to conflict with our application.

@peppy
Copy link
Member

peppy commented Jun 14, 2021

Going to close this until the user actually says which keys they are finding troubling. Kinda pointless in this state.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants