Any way to change colors in Rstudio to something other than default options?

后端 未结 6 496
隐瞒了意图╮
隐瞒了意图╮ 2021-01-30 11:46

Is there anyway to change the color schemes for Rstudio? It comes with 6 or 7 default, pre-packaged

6条回答
  •  自闭症患者
    2021-01-30 12:20

    There's a much faster way to deal with this and 100% doable.

    1. Open RStudio with your favourite Editor theme and open an .R script

    2. Inspect the Source layout (Right-click>Inspect) and Ctrl + f an unique class selector such as .ace_comment. In the matched CSS rules box in the side pane copy an attribute as unique as possible (i.e. color: #0088FF; I use Cobalt theme).

    3. Go to RStudio's install path and dive into /www/rstudio/. As jorloff rightly said, you'll find a bunch of files like this: VERYUGLYNAME.cache.css. Open all of them with your favourite text editor as administrator.

    4. Find in files: Ctrl+ Shift + f (in sublime text) and type the unique attribute value you previously chosed. BOOM, there you have it.

    5. Now delight yourself editing your crazy style, but remember to back it up first!

    As Jonathan said, RStudio's editor is based on ACE themes, so all clases have the ace_ prefix. Take your time inspecting and understanding the editor hierarchy. I recommend you to take some time inspecting the html code to understand its structure. The editor starts in id="rstudio_source_text_editor"

    I'm using RStudio Desktop 0.99.892 Release for Windows

提交回复
热议问题