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

gdkRgbFindColor

gdkRgbFindColor


Description

colormap should be the colormap for the graphics context and drawable you're using to draw. If you're drawing to a GtkWidget, call gtkWidgetGetColormap.

Usage

gdkRgbFindColor(colormap, color)

Arguments

colormap

a GdkColormap

color

a GdkColor

Details

color should have its red, green, and blue fields initialized; gdkRgbFindColor will fill in the pixel field with the best matching pixel from a color cube. The color is then ready to be used for drawing, e.g. you can call gdkGCSetForeground which expects pixel to be initialized.

In many cases, you can avoid this whole issue by calling gdkGCSetRgbFgColor or gdkGCSetRgbBgColor, which do not expect pixel to be initialized in advance. If you use those functions, there's no need for gdkRgbFindColor.

Author(s)

Derived by RGtkGen from GTK+ documentation


RGtk2

R Bindings for Gtk 2.8.0 and Above

v2.20.36
GPL
Authors
Michael Lawrence <michafla@gene.com> and Duncan Temple Lang <duncan@wald.ucdavis.edu>
Initial release

We don't support your browser anymore

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