Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

Cairo.capture

Capture contents of an image backend or a display list snapshot.


Description

Cairo.capture is essentially the same as dev.capture(native=TRUE) with the exception that it works where dev.capture doesn't such as onSave callbacks.

Cairo.snapshot is very similar to recordPlot except it also allows to retrieve the last snapshot.

Usage

Cairo.capture(device = dev.cur())
Cairo.snapshot(device = dev.cur(), last=FALSE)

Arguments

device

device number or an object of the class Cairo (as obtained from the Cairo function).

last

logical, if FALSE then a new snapshot is created (exactly the same as recordPlot()), if TRUE then the last known snapshot is retrieved, if NA then a snapshot is created first, but if the display list is empty last snapshot is retrieved instead.

Value

Cairo.capture: object of the class nativeRaster.

Cairo.snapshot: object of the class recordedplot.

Author(s)

Simon Urbanek


Cairo

R Graphics Device using Cairo Graphics Library for Creating High-Quality Bitmap (PNG, JPEG, TIFF), Vector (PDF, SVG, PostScript) and Display (X11 and Win32) Output

v1.5-12.2
GPL-2
Authors
Simon Urbanek <Simon.Urbanek@r-project.org>, Jeffrey Horner <jeff.horner@vanderbilt.edu>
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.