sprinkle_justify {pixiedust}R Documentation

Change the Caption in a Dust Table

Description

The justification of the table determines the horizontal placing of the table on the page.

Usage

sprinkle_justify(x, justify = getOption("pixie_justify", "center"), ...)

## Default S3 method:
sprinkle_justify(x, justify = getOption("pixie_justify", "center"), ...)

## S3 method for class 'dust_list'
sprinkle_justify(x, justify = getOption("pixie_justify", "center"), ...)

Arguments

x

An object of class dust

justify

character string giving the justification of the entire table on the page. May be any one of "center", "left", or "right".

...

Additional arguments to pass to other methods. Currently ignored.

Details

For HTML tables, the values "center", "left", and "right" all justify the table as expected. It is important to note, however, that "left" and "right" will cause subsequent elements to be rendered next to the table, not below it. To render the table with left alignment without this side effect, use "none".

In LaTeX output, both "right" and "left" justify to the left. This may change in the future if I find a resolution. Using "none" also results in left justification.

Functional Requirements

  1. Change the justify attribute of the dust object.

  2. Cast an error if x is not a dust object.

  3. Cast an error if justify is not one of "center", "none", "left", or "right".

  4. Ignore capitalization of the justify argument.

Author(s)

Benjamin Nutter

See Also

dust, sprinkle


[Package pixiedust version 0.9.4 Index]