column_header_buffer: Return or set column_header_buffer attributes

Description Usage Arguments Value Examples

View source: R/properties.R

Description

These property functions modify and return the column header buffers of a rtf_doc object. These are stored as a named vector. Names should be top and bottom. This attribute adds rows to the top or bottom of the table column headers to pad it from the titles above or the table below.

Usage

1
2
3
4
5

Arguments

x

A rtf_doc object

...

Additonal arguments passed to method dispatch. Should include argument top and bottom with numeric elements.

value

A named vector detailing the top and bottom buffer.

Value

For column_header_buffer, the column_header_buffer attribute of the supplied rtf_doc. For `column_header_buffer<-`() and set_column_header_buffer(), the modified object.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
library(huxtable)
ht <- huxtable(
  column1 = 1:5,
  column2 = letters[1:5]
)
rtf <- rtf_doc(ht, list(hf_line("aTitle")))

column_header_buffer(rtf)
# Returns c(top = 0, bottom = 0), the default

column_header_buffer(rtf) <- c(bottom = 1)
# Sets the bottom column_header_buffer to 1

pharmaRTF documentation built on Sept. 28, 2021, 5:08 p.m.