Skip to contents

Static renderers use the normal layout and paint pipeline and do not start an event loop or write to a terminal.

Usage

render_text(x, width = 80, height = 24, trim = TRUE)

render_lines(x, width = 80, height = 24, trim = TRUE)

Arguments

x

A widget, Screen, App, or ScreenBuffer.

width, height

Frame size in cells.

trim

Remove trailing spaces from each line?

Value

render_text() returns one string separated by newlines; render_lines() returns one string per row.

Examples

render_text(panel(label("Finished"), title = "Job"), width = 20, height = 5)
#> [1] "╭ Job ─────────────╮\n│ Finished         │\n╰──────────────────╯\n\n"