Skip to content
This repository has been archived by the owner on Sep 21, 2023. It is now read-only.

grcatlin/rs.ui

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

rs.ui

rs.ui modifies RStudio files such that they point to css files rs.ui generates. Doing this allows the UI of RStudio to be customized. rs.ui backs up the un-modded RStudio files such that the original RStudio setup can be restored.

Here's an example of a normal-dark mode RStudio theme, wherein the borders are always a blue-ish color: Screenshot 2023-03-06 at 12 54 45 PM With rs.ui, you can have something like this in seconds: Screenshot 2023-03-06 at 12 57 19 PM

Usage

rs.ui can be installed with the following command:

devtools::install_github("grcatlin/rs.ui")

The basic flow of rs.ui is to call rs.ui(), then reboot or reload RStudio.

library(rs.ui)
rs.ui(main_color = "#205d89")

Notice only the editor is modified at this point, you need to restart RStudio or reload it from here. Screenshot 2023-03-06 at 12 59 13 PM Upon restart Screenshot 2023-03-06 at 1 01 25 PM

From here, you will only need to use the rs.ui library again if you want to change the theme or restore RStudio!

Exact Theme or Theme Generation? Both!

main_color

If provided a main_color, rs.ui generates a custom theme based off this color by calculating tints/shades and analogous colors. If rs.ui generates a theme you enjoy, it can be exported with the export parameter so it can be shared!

theme_def

If provided a valid theme_def, no generation takes place and rs.ui writes css files according to the provided theme_def. This option was added to allow finer control and sharing between rs.ui users.

Examples

rs.ui(main_color = "#504066") Screenshot 2023-03-06 at 1 05 08 PM

rs.ui(main_color = "#5f8065") Screenshot 2023-03-06 at 1 05 38 PM

rs.ui(main_color = "#545255") Screenshot 2023-03-06 at 1 06 30 PM

rs.ui(theme_def = theme_def_ex) Screenshot 2023-03-06 at 1 07 30 PM

my_theme = read.csv("theme.csv")
rs.ui(theme_def = my_theme)

Screenshot 2023-03-06 at 1 14 42 PM

Caveats

At the moment, only MacOS is supported but it is possible to do the same on Windows and/or Linux.

Thanks for Stopping By!

Major shout-out goes to rileytwo's darkstudio which served as the basis for this project. I hope you enjoy this (I think) cool, but mostly useless, package! 💝

About

Custom RStudio Themes

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published