Skip to contents

The same native grid geometry powers previews and all three export formats. SVG and PDF retain vector paths, including outlined package-name glyphs; uploaded PNG/JPEG figures remain embedded raster images. Rendering finishes in a temporary file beside the destination before replacing it, so a failed export preserves any previous file. Export restores the previously selected graphics device.

Usage

hex_export(design, filename, width = 1600L)

Arguments

design

A hex_design() object.

filename

Destination ending in .png, .svg or .pdf.

width

PNG width in pixels; vector masters use a six-inch canvas.

Value

The destination path, invisibly.

Examples

if (capabilities("cairo")) {
  f <- tempfile(fileext = ".svg")
  hex_export(hex_design("phenoscapR"), f)
}