getMark: Access LaTeX Marks

View source: R/marks.R

getMarkR Documentation

Access LaTeX Marks

Description

getMark() allows access a location within LaTeX output relative to the rendering in R.

addMark() allows third-party packages to add marks to the rendering in R.

Usage

getMark(name)
addMark(name, devx, devy, vpx=NA, vpy=NA, vpPath=NULL)

Arguments

name

The name of a mark.

devx, devy

The location of the mark on the device (in inches).

vpx, vpy

The location of the mark relative to the viewport in which the mark was rendered.

vpPath

The viewport path to the viewport in which the mark was rendered.

Details

Some LaTeX packages, e.g., see zrefPackage, allow positions within text to be saved with a label. This function allows those saved locations to be accessed, e.g., to add further drawing relative to those locations.

Value

getMark returns a list containing the location (and viewport) information for the mark.

Warning

The saved locations are only relative to the current device size. Resizing the device, or copying between devices will result in incorrect locations.

A call to addMark() using an existing mark name will overwrite the previous mark information.

Author(s)

Paul Murrell


xdvir documentation built on Aug. 8, 2025, 7:12 p.m.