header_footer_height: Return or set header/footer height

Description Usage Arguments Value Examples

Description

These property functions modify or return the header_height/footer_height attribute of a rtf_doc object. The header/footer height is the default amount of space allocated to the header/footer from the margin. If the content of the header/footer exceeds this amount of space, it will be expanded.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11

Arguments

x

A rtf_doc object

...

Additonal arguments passed to method dispatch

value

A numeric value to set the header_height/footer_height

Value

For header_height()/footer_height(), the header_height/footer_height attribute of thesupplied rtf_doc object. For `header_height<-()`/ `footer_height<-`() and set_header_height()/ set_footer_height(), 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")))

header_height(rtf)
# Returns 0.5, the default

footer_height(rtf) <- 1
# Sets footer_height to 1

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