About Key Bindings in RStudio

Hello,

I'm trying to set RStudio as my main IDE. I've been searching but couldn't find a solution. I wonder if it's possible to the following in RStudio:

  • Copy and cut whole line, without selecting it (Ctrl+X: cut the line where the cursor is)
  • Search documents in working directory. (Ctrl+P in VSCode.)
  • Comment/Uncomment selected lines in a code chunk in Rmarkdown via a keyboard shortcut
  • Add python code block in Rmarkdown with a keyboard shortcut (like Ctrl+Alt+I for R code blocks)

Regards,

This has not been implemented -- you might consider filing a feature request at Issues · rstudio/rstudio · GitHub.

This is usually done via the "fuzzy finder", with Ctrl + .. Note that this navigates both function definitions as well as files located in the active project.

Lines and be commented + uncommented with Ctrl + Alt + C.

There isn't a preset keybinding for this, but you could add your own keybinding via Tools -> Modify Keyboard Shortcuts, with a binding for the Insert Chunk Python command.

Thanks for the reply,

Comment Uncomment doesn't work in RMarkdown code chunks, is this normal?

It seems to work for me (macOS 11.0.1; RStudio 1.4.1069). Would you mind filing this as a bug report at Issues · rstudio/rstudio · GitHub, with some extra context on what exactly you're seeing?

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.