Skip to contents

bm_split_layout() extracts print-and-play components from a layout.

Usage

bm_split_layout(page, ..., layout = "button_shy_cards", bleed = FALSE)

Arguments

page

A bittermelon::bm_pixmap() object representing a print-and-play layout page. Often the output from pdf_render_bm_pixmap().

...

Ignored for now.

layout

Either a layout preset name in layout_names() or a data frame with layout data (as returned by layout_grid()).

bleed

Include the bleed (if available).

See also

bm_crop_layout() to just crop a single component

Examples

if (FALSE) # User not expected to have this PDF file
if (requireNamespace("bittermelon", quietly = TRUE)) {
  input <- "A Nice Cuppa - PNP.pdf"
  page <- pdf_render_bm_pixmap(input, page = 4L, dpi = 75)
  cards <- bm_split_layout(page, layout = "button_shy_cards")
  grid::grid.raster(cards[[1L]])
}
 # \dontrun{}