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

Fix for comment keymap on spanish keyboards #326

Merged
merged 4 commits into from
Jan 12, 2025
Merged

Conversation

tmhglnd
Copy link
Contributor

@tmhglnd tmhglnd commented Jan 9, 2025

I've had several encounters with people who have a spanish keyboard layout, where the cmd-/ keymap to (un)comment doesn't work, because they need to type cmd shift 7.

I'm proposing this fix (that worked for me in the mercury editor on my site) where I just added the actual keycombination shift-cmd-7 and shift-alt-7 (as alternative).

I've also added alt-/ and ctrl-/ as extra alternatives. The alt-/ mainly because I'm used to using alt in Mercury to avoid clashes with other commands. The ctrl-/ is maybe not so necessary but also doesn't hurt I guess.

My fix here hasn't been tested on a Spanish keyboard yet, so I'm happy to hear feedback from users with such a keyboard.

@tmhglnd
Copy link
Contributor Author

tmhglnd commented Jan 9, 2025

Hmm, there seems to be a "code style issue" found, but there is no clear indication what my style issue is. So not sure how to fix this specifically.

@tmhglnd
Copy link
Contributor Author

tmhglnd commented Jan 9, 2025

Okay, seems fixed now, the error was just because I use ' instead of ".

@munshkr
Copy link
Owner

munshkr commented Jan 9, 2025

Thanks! I can test later today, I have a Spanish keyboard in one of my notebooks :)

@munshkr munshkr merged commit c0008e1 into munshkr:main Jan 12, 2025
2 checks passed
@munshkr
Copy link
Owner

munshkr commented Jan 12, 2025

Thanks! I did test it and works great. I have a feeling this might cause issues for other non-spanish and non-english keyboard layouts though, but let's see if anyone complains and review it if that's the case.

@tmhglnd tmhglnd deleted the keymap-fix branch January 12, 2025 22:15
@tmhglnd
Copy link
Contributor Author

tmhglnd commented Jan 12, 2025

Yeah, maybe adding these explicit shortkeys could lead to issues on other language keyboards. Let's see.

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

Successfully merging this pull request may close these issues.

2 participants