The ColorButton is a widget in the form of a small button
containing a swatch representing the current selected
color. When the button is clicked, a ColorSelection dialog
will open, allowing the user to select a color. The swatch
will be updated to reflect the new color when the user finishes.
getAlpha
public int getAlpha()
Returns the current alpha value.
getColor
public Color getColor()
Returns the current color value.
getEventListenerClass
public Class getEventListenerClass(String signal)
- getEventListenerClass in interface Button
getEventType
public EventType getEventType(String signal)
- getEventType in interface Button
getTitle
public String getTitle()
Returns the title from the ColorSelectionDialog.
getUseAlpha
public boolean getUseAlpha()
Returns whether or not the ColorButton is using the alpha channel.
gtk_color_button_get_alpha
protected static final int gtk_color_button_get_alpha(Handle button)
gtk_color_button_get_color
protected static final Handle gtk_color_button_get_color(Handle button)
gtk_color_button_get_title
protected static final String gtk_color_button_get_title(Handle button)
gtk_color_button_get_type
protected static final int gtk_color_button_get_type()
gtk_color_button_get_use_alpha
protected static final boolean gtk_color_button_get_use_alpha(Handle button)
gtk_color_button_new
protected static final Handle gtk_color_button_new()
gtk_color_button_new_with_color
protected static final Handle gtk_color_button_new_with_color(Handle color)
gtk_color_button_set_alpha
protected static final void gtk_color_button_set_alpha(Handle button,
int alpha)
gtk_color_button_set_color
protected static final void gtk_color_button_set_color(Handle button,
Handle color)
gtk_color_button_set_title
protected static final void gtk_color_button_set_title(Handle button,
String title)
gtk_color_button_set_use_alpha
protected static final void gtk_color_button_set_use_alpha(Handle button,
boolean useAlpha)
setAlpha
public void setAlpha(int alpha)
Sets the current opacity to be alpha
alpha
-
setColor
public void setColor(Color color)
Set the current color for the widget.
color
-
setTitle
public void setTitle(String title)
Sets the color for the ColorSelectionDialog.
title
-
setUseAlpha
public void setUseAlpha(boolean useAlpha)
Sets whether or not the ColorButton should use the alpha channel.
useAlpha
-