diff --git a/inst/package-sticker/logo.png b/inst/package-sticker/logo.png new file mode 100644 index 0000000..570d91f Binary files /dev/null and b/inst/package-sticker/logo.png differ diff --git a/inst/package-sticker/package-sticker.R b/inst/package-sticker/package-sticker.R new file mode 100644 index 0000000..9eea3e2 --- /dev/null +++ b/inst/package-sticker/package-sticker.R @@ -0,0 +1,48 @@ +#' +#' Create an Hexagonal Sticker for the Package +#' + + +# install.packages(c("png", "ggplot2", "hexSticker", "grid", "ggpubr")) + + +rlogo <- png::readPNG(here::here("inst", "package-sticker", "logo.png")) +rlogo <- grid::rasterGrob(rlogo, interpolate = TRUE) + +p <- ggplot2::ggplot() + + ggplot2::annotation_custom(rlogo, xmin = -Inf, xmax = Inf, ymin = -Inf, + ymax = Inf) + + ggplot2::theme_void() + + ggpubr::theme_transparent() + +hexSticker::sticker( + + subplot = p, + package = "calendar", + filename = here::here("man", "figures", "logo.png"), + dpi = 600, + + p_size = 35.0, # Title + u_size = 8.0, # URL + p_family = "Aller_Rg", + + p_color = "#ffffff", # Title + h_fill = "#3c3836", # Background + h_color = "#aa0000", # Border + u_color = "#ffffff", # URL + + p_x = 1.00, # Title + p_y = 0.60, # Title + s_x = 1.00, # Subplot + s_y = 1.05, # Subplot + + s_width = 1.25, # Subplot + s_height = 1.25, # Subplot + + url = "https://frbcesab.github.io/calendar", + + spotlight = TRUE, + l_alpha = 0.10, + l_width = 4, + l_height = 4 +) diff --git a/man/figures/logo.png b/man/figures/logo.png index 0e8fd7f..2b1284f 100644 Binary files a/man/figures/logo.png and b/man/figures/logo.png differ