<!-- ##### SECTION Title ##### -->
GnomeColorPicker

<!-- ##### SECTION Short_Description ##### -->
Widget for selecting colors.

<!-- ##### SECTION Long_Description ##### -->
<para>
This widget provides color selection facilities to your application.
The widget appears as a button which contains a "color swatch" of the
currently selected color. When the button is pressed, the widget
presents the user with a color selection dialog where the color can be
selected. </para>

<para>You can select the color to be displayed in a number of ways:
floating point values for the red, green and blue channels,
integers in the range 0 to 65,535, or integers in the range 0 to 255,
depending on your needs.</para>

<informalexample>
  <programlisting>
void color_picked_callback(GtkWidget *w, guint r, guint g, guint b, guint a, gpointer data)
{
	g_print("User selected color (rgba): %d %d %d %d\n", r, g, b, a);
	/* save colors to configuration file, or use them some other way */
}
...
GtkWidget *cp;

/* create a color picker, set a default color */
cp = gnome_color_picker_new();
#gnome_color_picker_set_i8(GNOME_COLOR_PICKER(cp),
			  255, 0, 0, 0);

/* connect a function to our widget */
gtk_signal_connect(GTK_OBJECT(cp), "color_set",
		   GTK_SIGNAL_FUNC(color_picked_callback), NULL);
...
/* retrieve color from our widget, someplace else in code */
gdouble r, g, b, a;
#gnome_color_picker_get_d(GNOME_COLOR_PICKER(cp),
			 &amp;r, &amp;g, &amp;b, &amp;a);
g_print("Color (rgba): %%g %%g %%g %%g\n", r, g, b, a);
  </programlisting>
</informalexample> 

<!-- ##### SECTION See_Also ##### -->
<para>

</para>

<!-- ##### STRUCT GnomeColorPicker ##### -->
<para>

</para>


<!-- ##### FUNCTION gnome_color_picker_new ##### -->
<para>

</para>

@Returns: 


<!-- ##### FUNCTION gnome_color_picker_set_d ##### -->
<para>

</para>

@cp: 
@r: 
@g: 
@b: 
@a: 


<!-- ##### FUNCTION gnome_color_picker_get_d ##### -->
<para>

</para>

@cp: 
@r: 
@g: 
@b: 
@a: 


<!-- ##### FUNCTION gnome_color_picker_set_i8 ##### -->
<para>

</para>

@cp: 
@r: 
@g: 
@b: 
@a: 


<!-- ##### FUNCTION gnome_color_picker_get_i8 ##### -->
<para>

</para>

@cp: 
@r: 
@g: 
@b: 
@a: 


<!-- ##### FUNCTION gnome_color_picker_set_i16 ##### -->
<para>

</para>

@cp: 
@r: 
@g: 
@b: 
@a: 


<!-- ##### FUNCTION gnome_color_picker_get_i16 ##### -->
<para>

</para>

@cp: 
@r: 
@g: 
@b: 
@a: 


<!-- ##### FUNCTION gnome_color_picker_set_dither ##### -->
<para>

</para>

@cp: 
@dither: 


<!-- ##### FUNCTION gnome_color_picker_set_use_alpha ##### -->
<para>

</para>

@cp: 
@use_alpha: 


<!-- ##### FUNCTION gnome_color_picker_set_title ##### -->
<para>

</para>

@cp: 
@title: 


<!-- ##### SIGNAL GnomeColorPicker::color-set ##### -->
<para>
This signal is emitted when the user changes the color on the color
selector.  The values passed to this signal are the red, green, blue
and alpha channels selected in integer form in the range 0 to 65535.
</para>

@colorpicker: The object which received the signal.
@arg1: Red color component, values are in [0, 65535]
@arg2: Green color component, values are in [0, 65535]
@arg3: Blue color component, values are in [0, 65535]
@arg4: Alpha component, values are in [0, 65535]
@user_data: User data set when the signal handler was connected.
@Returns:

<!--
Local variables:
mode: sgml
sgml-parent-document: ("../gnomeui-docs.sgml" "book" "sect1" "")
End:  
-->
