ColorChooserDialog

A dialog for choosing a color.

An example GtkColorChooserDialog

gtk.color_chooser_dialog.ColorChooserDialog implements the gtk.color_chooser.ColorChooser interface and does not provide much API of its own.

To create a gtk.color_chooser_dialog.ColorChooserDialog, use gtk.color_chooser_dialog.ColorChooserDialog.new_.

To change the initially selected color, use gtk.color_chooser.ColorChooser.setRgba. To get the selected color use gtk.color_chooser.ColorChooser.getRgba.

gtk.color_chooser_dialog.ColorChooserDialog has been deprecated in favor of gtk.color_dialog.ColorDialog.

CSS nodes

gtk.color_chooser_dialog.ColorChooserDialog has a single CSS node with the name window and style class .colorchooser.

More...

Constructors

this
this(string title, gtk.window.Window parent)

Creates a new gtk.color_chooser_dialog.ColorChooserDialog.

Mixed In Members

From mixin ColorChooserT!()

addPalette
void addPalette(gtk.types.Orientation orientation, int colorsPerLine, gdk.rgba.RGBA[] colors)

Adds a palette to the color chooser.

getRgba
void getRgba(gdk.rgba.RGBA color)

Gets the currently-selected color.

getUseAlpha
bool getUseAlpha()

Returns whether the color chooser shows the alpha channel.

setRgba
void setRgba(gdk.rgba.RGBA color)

Sets the color.

setUseAlpha
void setUseAlpha(bool useAlpha)

Sets whether or not the color chooser should use the alpha channel.

connectColorActivated
ulong connectColorActivated(T callback, Flag!"After" after)

Connect to ColorActivated signal.

Inherited Members

From Dialog

addActionWidget
void addActionWidget(gtk.widget.Widget child, int responseId)

Adds an activatable widget to the action area of a gtk.dialog.Dialog.

addButton
gtk.widget.Widget addButton(string buttonText, int responseId)

Adds a button with the given text.

getContentArea
gtk.box.Box getContentArea()

Returns the content area of dialog.

getHeaderBar
gtk.header_bar.HeaderBar getHeaderBar()

Returns the header bar of dialog.

getResponseForWidget
int getResponseForWidget(gtk.widget.Widget widget)

Gets the response id of a widget in the action area of a dialog.

getWidgetForResponse
gtk.widget.Widget getWidgetForResponse(int responseId)

Gets the widget button that uses the given response ID in the action area of a dialog.

response
void response(int responseId)

Emits the ::response signal with the given response ID.

setDefaultResponse
void setDefaultResponse(int responseId)

Sets the default widget for the dialog based on the response ID.

setResponseSensitive
void setResponseSensitive(int responseId, bool setting)

A convenient way to sensitize/desensitize dialog buttons.

connectClose
ulong connectClose(T callback, Flag!"After" after)

Connect to Close signal.

connectResponse
ulong connectResponse(T callback, Flag!"After" after)

Connect to Response signal.

From ColorChooser

addPalette
void addPalette(gtk.types.Orientation orientation, int colorsPerLine, gdk.rgba.RGBA[] colors)

Adds a palette to the color chooser.

getRgba
void getRgba(gdk.rgba.RGBA color)

Gets the currently-selected color.

getUseAlpha
bool getUseAlpha()

Returns whether the color chooser shows the alpha channel.

setRgba
void setRgba(gdk.rgba.RGBA color)

Sets the color.

setUseAlpha
void setUseAlpha(bool useAlpha)

Sets whether or not the color chooser should use the alpha channel.

connectColorActivated
ulong connectColorActivated(T callback, Flag!"After" after)

Connect to ColorActivated signal.

Detailed Description

Deprecated: Use gtk.color_dialog.ColorDialog instead