From 3ec166dda4a4a89928d24fea770313fbc574f1c2 Mon Sep 17 00:00:00 2001 From: JanMarvin Date: Mon, 29 Jan 2024 11:28:24 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20JanMarvi?= =?UTF-8?q?n/openxlsx2@096cfddaf232cc6d37756ebb58265cf1ef378ffc=20?= =?UTF-8?q?=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- dev/pkgdown.yml | 2 +- dev/reference/comment_internal.html | 13 ++++ dev/reference/create_sparklines.html | 90 +++++++++++++++++++++------- dev/reference/properties-wb.html | 2 +- dev/search.json | 2 +- 5 files changed, 86 insertions(+), 23 deletions(-) diff --git a/dev/pkgdown.yml b/dev/pkgdown.yml index 2d8ed815d..a10a7f133 100644 --- a/dev/pkgdown.yml +++ b/dev/pkgdown.yml @@ -8,7 +8,7 @@ articles: openxlsx2_charts_manual: openxlsx2_charts_manual.html openxlsx2_formulas_manual: openxlsx2_formulas_manual.html openxlsx2_style_manual: openxlsx2_style_manual.html -last_built: 2024-01-28T16:21Z +last_built: 2024-01-29T11:27Z urls: reference: https://janmarvin.github.io/openxlsx2/reference article: https://janmarvin.github.io/openxlsx2/articles diff --git a/dev/reference/comment_internal.html b/dev/reference/comment_internal.html index 2a6bc58cb..2a640633a 100644 --- a/dev/reference/comment_internal.html +++ b/dev/reference/comment_internal.html @@ -142,6 +142,19 @@

Examples# Works with formatted text also. formatted_text <- fmt_txt("bar", underline = TRUE) wb$add_comment(dims = "B5", comment = formatted_text) +# With background color +wb$add_comment(dims = "B7", comment = formatted_text, color = wb_color("green")) +# With background image. File extension must be png or jpeg, not jpg? +tmp <- tempfile(fileext = ".png") +png(file = tmp, bg = "transparent") +plot(1:10) +rect(1, 5, 3, 7, col = "white") +dev.off() +#> agg_png +#> 2 + +c1 <- wb_comment(text = "this is a comment", author = "", visible = TRUE) +wb$add_comment(dims = "B12", comment = c1, file = tmp)