Skip to contents

Modify / get the default colors of the workbook.

Usage

wb_set_base_colors(wb, theme = "Office", ...)

wb_get_base_colors(wb, xml = FALSE, plot = TRUE)

Arguments

wb

A workbook object

theme

a predefined color theme

...

optional parameters

xml

Logical if xml string should be returned

plot

Logical if a barplot of the colors should be returned

Details

Theme must be any of the following: "Aspect", "Blue", "Blue II", "Blue Green", "Blue Warm", "Greyscale", "Green", "Green Yellow", "Marquee", "Median", "Office", "Office 2007 - 2010", "Office 2013 - 2022", "Orange", "Orange Red", "Paper", "Red", "Red Orange", "Red Violet", "Slipstream", "Violet", "Violet II", "Yellow", "Yellow Orange"

Examples

wb <- wb_workbook()
wb$get_base_colors()
#> $Office
#>      a:dk1      a:lt1      a:dk2      a:lt2  a:accent1  a:accent2  a:accent3 
#>  "#000000"  "#FFFFFF"  "#0E2841"  "#E8E8E8"  "#156082"  "#E97132"  "#196B24" 
#>  a:accent4  a:accent5  a:accent6    a:hlink a:folHlink 
#>  "#0F9ED5"  "#A02B93"  "#4EA72E"  "#467886"  "#96607D" 
#> 
wb$set_base_colors(theme = 3)
wb$set_base_colors(theme = "Violet II")
wb$get_base_colours()
#> $`Violet II`
#>      a:dk1      a:lt1      a:dk2      a:lt2  a:accent1  a:accent2  a:accent3 
#>  "#000000"  "#FFFFFF"  "#632E62"  "#EAE5EB"  "#92278F"  "#9B57D3"  "#755DD9" 
#>  a:accent4  a:accent5  a:accent6    a:hlink a:folHlink 
#>  "#665EB8"  "#45A5ED"  "#5982DB"  "#0066FF"  "#666699" 
#>