Commit f53a9d1
authored
Use new Quarto context keys in keyboard shortcuts (#5451)
Addresses #1955 together with
quarto-dev/quarto#608
The Quarto PR provides new context keys for the main language of a
Quarto document (for example, R or Python) and we can consume those to
provide keyboard shortcuts.
There are really only a couple of R ones that we want right now which
means that there is no real change here in an R `.qmd` in behavior
compared to what is in the RStudio Keymap. 🙈 However, I think this is
still worth getting in since we've gone to the trouble of figuring it
out, it lets us offer these without the RStudio Keymap being on, we can
offer them _only_ in R `.qmd` files (right now, these also show up in
Python `.qmd` files if you have the RStudio Keymap on), and we can use
this infrastructure in the future.
I did remove these from the RStudio Keymap just to clean things up, but
it wouldn't hurt _a lot_ to keep them, if there is some reason I am not
thinking of? If we do want to remove them, we'll need to do a Quarto
release and update the bundled Quarto VS Code extension version in this
PR to keep these keybindings functional.
### QA Notes
With the new version of the Quarto extension (updated here), you can use
the keyboard shortcuts for the pipe and assignment operator in R Quarto
documents but not Python ones:
- <kbd>Alt</kbd>+<kbd>-</kbd> to get you `<-`
- <kbd>Cmd/Ctrl</kbd>+<kbd>Shift</kbd>+<kbd>M</kbd> to get you `|>`1 parent 54cbc06 commit f53a9d1
File tree
3 files changed
+5
-21
lines changed- extensions
- positron-rstudio-keymap
- positron-r
3 files changed
+5
-21
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
370 | 370 | | |
371 | 371 | | |
372 | 372 | | |
373 | | - | |
| 373 | + | |
374 | 374 | | |
375 | 375 | | |
376 | 376 | | |
| |||
382 | 382 | | |
383 | 383 | | |
384 | 384 | | |
385 | | - | |
| 385 | + | |
386 | 386 | | |
387 | 387 | | |
388 | 388 | | |
| |||
466 | 466 | | |
467 | 467 | | |
468 | 468 | | |
469 | | - | |
| 469 | + | |
470 | 470 | | |
471 | 471 | | |
472 | 472 | | |
| |||
476 | 476 | | |
477 | 477 | | |
478 | 478 | | |
479 | | - | |
| 479 | + | |
480 | 480 | | |
481 | 481 | | |
482 | 482 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
178 | 178 | | |
179 | 179 | | |
180 | 180 | | |
181 | | - | |
182 | | - | |
183 | | - | |
184 | | - | |
185 | | - | |
186 | | - | |
187 | | - | |
188 | | - | |
189 | | - | |
190 | | - | |
191 | | - | |
192 | | - | |
193 | | - | |
194 | | - | |
195 | | - | |
196 | | - | |
197 | 181 | | |
198 | 182 | | |
199 | 183 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
208 | 208 | | |
209 | 209 | | |
210 | 210 | | |
211 | | - | |
| 211 | + | |
212 | 212 | | |
213 | 213 | | |
214 | 214 | | |
| |||
0 commit comments