colorSchemeTree {RGtkViewers}R Documentation

Create tree for color scheme

Description

These functions create a GtkTree for the color scheme or list of color schemes. colorSchemeTree works on a single ColorScheme. colorSchemesTree arranges the color schemes into groups and shows these groups as sub-trees. By default, the groups it uses are the unique class names of the color schemes. colorSchemesBySize use colorSchemesTree but groups the schemes by the number of colors they support. This makes it easier to select a scheme with a particular number of colors.

Usage

colorSchemeTree(scheme, tree = gtkTree())
colorSchemesTree(schemes, top = gtkTree(), schemeCallback = NULL, group
= class, groupId = function(x,y) class(x)[1] == y)
colorSchemesBySize(schemes, top = gtkTree(), schemeCallback = NULL)

Arguments

scheme the ColorScheme to display.
tree a GtkTree object to which to append the items.
schemes the list of color scheme objects.
top the tree into which to append the new schemes items.
schemeCallback the function that is registered with the GtkTreeItem representing a color scheme. This is invoked with two arguments: a list of length 2 and a GtkWidget giving the tree item. The list contains the ColorScheme object and its name.
group a function that identifies the different `types' of schemes. This is used to group the schemes by class or by number or any other criterion. This is a function that takes a single argument which is the scheme.
groupId a function used to identify the schemes within a particlar group. This is a function of two arguments, the first being the scheme and the second being the value by which they are being grouped.

Value

An object of class GtkTree.

Author(s)

Duncan Temple Lang <duncan@research.bell-labs.com>

References

http://www.omegahat.org/RGtk, http://www.ggobi.org http://www.ggobi.org/data/colorschemes.xml http://www.gtk.org

See Also

colorSchemesView

Examples



[Package RGtkViewers version 0.7-4 Index]