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

UI shows the wrong keyboard shortcut with "when": "isRPackage" or when RStudio Keymap is enabled #2150

Open
juliasilge opened this issue Jan 29, 2024 · 4 comments
Labels
area: ui Issues related to UI category.

Comments

@juliasilge
Copy link
Contributor

We have at least one keyboard short specific to R packages that overrides a VS Code default:

{
"command": "r.packageCheck",
"key": "ctrl+shift+e",
"mac": "cmd+shift+e",
"when": "isRPackage"
},

During usability testing with @andrie we noticed that the UI does not reflect that override:

wrong-shortcut

I don't know how hard-coded these are and whether we might consider removing them or otherwise dealing with this. It does seem bad that you see that shortcut suggested when that is not what it will do.

@juliasilge juliasilge changed the title R or maybe UI: UI shows the wrong keyboard shortcut with "when": "isRPackage" UI or maybe R: UI shows the wrong keyboard shortcut with "when": "isRPackage" Jan 29, 2024
@jennybc
Copy link
Member

jennybc commented Jan 29, 2024

I can't tell from this screenshot, where I just see Shiny-related files. Just to confirm: the current workspace is an R package? If you actually press Ctrl + Shift + E, do you get devtools::check()?

@andrie
Copy link

andrie commented Jan 29, 2024

Yes, Shift + Ctrl + E triggers devtools::check() - which is what I would expect.

But that same keyboard shortcut is the default VS-code key for switching to the files pane.

@jennybc
Copy link
Member

jennybc commented Jan 29, 2024

This is a bit of "passing the buck" but I wonder if VS Code has hard-wired that UI (the hint about the keyboard shortcut) when really it shouldn't?

@juliasilge juliasilge added this to the Release Candidate milestone Feb 20, 2024
@wesm wesm added the area: ui Issues related to UI category. label Feb 29, 2024
@juliasilge juliasilge changed the title UI or maybe R: UI shows the wrong keyboard shortcut with "when": "isRPackage" UI shows the wrong keyboard shortcut with "when": "isRPackage" or when RStudio Keymap is enabled Aug 27, 2024
@juliasilge
Copy link
Contributor Author

juliasilge commented Aug 27, 2024

We have collected a number of issues that are related to this problem where the UI always shows a built-in keybinding, even when that keybinding does not apply to that action. The user might end up looking at the UI and trying that keybinding, but it does something completely different. So far this has come up in situations like "when": "isRPackage" or when the RStudio Keymap is enabled. Let's use this issue to track this problem and close the others.

Related:

If we tackle and totally resolve #3993, that will not solve this issue, which is kind of the opposite problem.

This happens in VS Code itself, but it feels worse in Positron because we bundle more extensions and have more @builtin extensions that are needed to use Positron functionality.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: ui Issues related to UI category.
Projects
None yet
Development

No branches or pull requests

4 participants