pushMask {gridSVG}R Documentation

Apply a masking context to the current viewport.

Description

This function is intended to be used similarly to grid.clip. The key difference is that instead of applying a new clipping context to the viewport, we apply a new masking context.

Usage

pushMask(mask = NULL, label = NULL, name = NULL, draw = TRUE)
popMask()

Arguments

mask

A mask object, used as the definition of an opacity mask.

label

A label for a defined reference.

name

A character identifier for the grob applying the masking context.

draw

A logical value indicating whether graphics output should be produced.

Details

If label is specified, uses a mask that has been supplied to registerMask. If mask is specified it will be used as the new masking context for the current viewport. If both are specified, it will attempt to define the mask with the given label, as well as applying the mask as the new masking context for the current viewport.

popMask is an alias for popContext.

Value

A pushMask grob. The value is returned invisibly.

Author(s)

Simon Potter

See Also

mask, registerMask, grid.mask, popContext.


[Package gridSVG version 1.7-5 Index]