linebreaker: Place a LaTeX \\makecell{} macro around some text

View source: R/utils-linebreaker.R

linebreakerR Documentation

Place a LaTeX ⁠\\makecell{}⁠ macro around some text

Description

Place a LaTeX ⁠\\makecell{}⁠ macro around some text

Usage

linebreaker(x, align = c("l", "c", "r"), ...)

Arguments

x

A vector of character strings

align

Choose from "l", "c" or "r" for "left", "center", and "right" respectively

...

Arguments passed to kableExtra::linebreak()

Details

This function is a wrapper around kableExtra::linebreak() which itself does not wrap the makecell macro around strings without the linebreak character. For table headers, this needs to be done to keep all headers aligned the same way with respect to each other.

Value

A vector of modified character strings or NULL if x is NULL or NA if x is NA. Any empty strings will remain the same, without wrapping text


pacific-hake/hake-assessment documentation built on Jan. 14, 2025, 9:12 p.m.