rtf_read_figure: Read Figures into Binary Files

View source: R/rtf_read.R

rtf_read_figureR Documentation

Read Figures into Binary Files

Description

Supported format is listed in r2rtf:::fig_format().

Usage

rtf_read_figure(file)

Arguments

file

A character vector of figure file paths.

Value

a list of binary data vector returned by readBin

Specification

The contents of this section are shown in PDF user manual only.

Examples

## Not run: 

# Read in PNG file in binary format
file <- tempfile("figure", fileext = ".png")
png(file)
plot(1:10)
dev.off()


rtf_read_figure(file)

# Read in EMF file in binary format
library(devEMF)
file <- tempfile("figure", fileext = ".emf")
emf(file)
plot(1:10)
dev.off()

rtf_read_figure(file)

## End(Not run)

r2rtf documentation built on Oct. 25, 2023, 9:07 a.m.