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(editor): common macos shortcuts for next and previous respected #513

Merged
merged 1 commit into from
Jun 12, 2024

Conversation

joncfoo
Copy link
Contributor

@joncfoo joncfoo commented Jun 12, 2024

Problem:

On macOS, next and previous tab for documents/tabs within applications are bound to Cmd-Shift-[ and Cmd-Shift-]. Pressing these while in the editor changes tabs but invokes the delimiter insertion code leaving behind unwanted delimiters when coming back to the editor.

Solution:

Only run the delimiter handling code if the Cmd button is not pressed. This is detectable via use of the meta key in the browser.

Problem:

On macOS, next and previous tab for documents/tabs within applications
are bound to Cmd-Shift-[ and Cmd-Shift-]. Pressing these while in the
editor changes tabs but invokes the delimiter insertion code.

Solution:

Only run the delimiter handling code if the `Cmd` button is not held
pressed.  This is detectable via use of the `meta` key in the browser.
@kaikalii kaikalii merged commit 6e5986b into uiua-lang:main Jun 12, 2024
1 check passed
@joncfoo joncfoo deleted the mac-editor-shortcuts branch June 12, 2024 05:35
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