coloured_text: Colour specific text in a html document

View source: R/coloured_text.R

coloured_textR Documentation

Colour specific text in a html document

Description

Colour specific text in a html document

Usage

coloured_text(colour, ...)

Arguments

colour

colour to use for the content

...

content to be coloured

Details

In quarto/Rmarkdown documents, use the function in an inline R chunk (`r coloured_text(...)`) or in an R chunk with the result set to asis

Examples

coloured_text("red", "This text should be red")
# also works with multiple contents
coloured_text("red", "This text should be red", "this one too")
# For multiple colours, use multiple calls to the function:
coloured_text("red", "this is red,")
coloured_text("blue", "and this is blue!")

CTU-Bern/CTUtemplate documentation built on Feb. 27, 2025, 7:21 p.m.