grid.edit {grid}R Documentation

Edit the Description of a Grid Graphical Object

Description

Changes the value of one or more elements of the list structure within a graphical object and redraws the graphical object.

Usage

grid.edit(grob, ..., redraw=TRUE)

Arguments

grob An object of class "grob".
... Zero or more element-specifiers, plus a single new value or a list of new values. The new value is required. Each specifier may be a single character or numeric value.
redraw A logical value to indicate whether to redraw the graphical object.

Details

This function acts on the graphical object specified by grob and the element-specifiers. It sets the values in the list structure of that graphical object which correspond to the new values. If redraw is TRUE it then redraws everything to reflect the change.

Before redrawing, it calls the generic function edit.details, dispatching on the class of the list structure within the graphical object, so that further consequences of the editing (such as editing children of the graphical object) can occur.

Value

None.

Author(s)

Paul Murrell

See Also

grid.grob

Examples

grid.newpage()
xa <- grid.xaxis(vp=viewport(width=.5, height=.5))
grid.edit(xa, gp=gpar(col="red"))
grid.edit(xa, "ticks", gp=gpar(col="green"))

[Package Contents]