GimpUi.ColorProfileComboBox

g Atk.ImplementorIface Atk.ImplementorIface Gtk.Widget Gtk.Widget Atk.ImplementorIface->Gtk.Widget GObject.GInterface GObject.GInterface GObject.GInterface->Atk.ImplementorIface Gtk.Buildable Gtk.Buildable GObject.GInterface->Gtk.Buildable Gtk.CellEditable Gtk.CellEditable GObject.GInterface->Gtk.CellEditable Gtk.CellLayout Gtk.CellLayout GObject.GInterface->Gtk.CellLayout GObject.InitiallyUnowned GObject.InitiallyUnowned GObject.InitiallyUnowned->Gtk.Widget GObject.Object GObject.Object GObject.Object->GObject.InitiallyUnowned GimpUi.ColorProfileComboBox GimpUi.ColorProfileComboBox Gtk.Bin Gtk.Bin Gtk.ComboBox Gtk.ComboBox Gtk.Bin->Gtk.ComboBox Gtk.Buildable->Gtk.Widget Gtk.CellEditable->Gtk.ComboBox Gtk.CellLayout->Gtk.ComboBox Gtk.ComboBox->GimpUi.ColorProfileComboBox Gtk.Container Gtk.Container Gtk.Container->Gtk.Bin Gtk.Widget->Gtk.Container

Subclasses:

None

Methods

Inherited:

Gtk.ComboBox (40), Gtk.Bin (1), Gtk.Container (35), Gtk.Widget (278), GObject.Object (37), Gtk.Buildable (10), Gtk.CellEditable (3), Gtk.CellLayout (9)

Structs:

Gtk.ContainerClass (5), Gtk.WidgetClass (12), GObject.ObjectClass (5)

class

new (dialog, history)

class

new_with_model (dialog, model)

add_file (file, label)

get_active_file ()

set_active_file (file, label)

set_active_profile (profile)

Virtual Methods

Inherited:

Gtk.ComboBox (2), Gtk.Container (10), Gtk.Widget (82), GObject.Object (7), Gtk.Buildable (10), Gtk.CellEditable (3), Gtk.CellLayout (9)

Properties

Inherited:

Gtk.ComboBox (16), Gtk.Container (3), Gtk.Widget (39), Gtk.CellEditable (1)

Name

Type

Flags

Short Description

dialog

Gtk.Dialog

r/w/co

The dialog to present when selecting profiles from disk

Style Properties

Inherited:

Gtk.ComboBox (4), Gtk.Widget (17)

Signals

Inherited:

Gtk.ComboBox (5), Gtk.Container (4), Gtk.Widget (69), GObject.Object (1), Gtk.CellEditable (2)

Fields

Inherited:

Gtk.ComboBox (5), Gtk.Container (4), Gtk.Widget (69), GObject.Object (1), Gtk.CellEditable (2)

Class Details

class GimpUi.ColorProfileComboBox(**kwargs)
Bases:

Gtk.ComboBox

Abstract:

No

Structure:

GimpUi.ColorProfileComboBoxClass

A combo box for selecting color profiles.

classmethod new(dialog, history)
Parameters:
Returns:

a new GimpUi.ColorProfileComboBox.

Return type:

Gtk.Widget

Create a combo-box widget for selecting color profiles. The combo-box is populated from the file specified as history. This filename is typically created using the following code snippet:

gchar *history = gimp_personal_rc_file ("profilerc"); The recommended dialog type to use is a GimpUi.ColorProfileChooserDialog. If a GimpUi.ColorProfileChooserDialog is passed, GimpUi.ColorProfileComboBox will take complete control over the dialog, which means connecting a Gtk.Dialog ::response() callback by itself, and take care of destroying the dialog when the combo box is destroyed.

If another type of dialog is passed, this has to be implemented separately.

See also GimpUi.ColorProfileComboBox.new_with_model().

New in version 2.4.

classmethod new_with_model(dialog, model)
Parameters:
Returns:

a new GimpUi.ColorProfileComboBox.

Return type:

Gtk.Widget

This constructor is useful when you want to create several combo-boxes for profile selection that all share the same GimpUi.ColorProfileStore. This is for example done in the GIMP Preferences dialog.

See also GimpUi.ColorProfileComboBox.new().

New in version 2.4.

add_file(file, label)
Parameters:
  • file (Gio.File) – file of the profile to add (or None)

  • label (str) – label to use for the profile (may only be None if file is None)

This function delegates to the underlying GimpUi.ColorProfileStore. Please refer to the documentation of GimpUi.ColorProfileStore.add_file() for details.

New in version 2.10.

get_active_file()
Returns:

The file of the currently selected color profile, release using GObject.Object.unref() when it is not any longer needed.

Return type:

Gio.File

New in version 2.10.

set_active_file(file, label)
Parameters:
  • file (Gio.File) – file of the profile to select

  • label (str) – label to use when adding a new entry (can be None)

Selects a color profile from the self and makes it the active item. If the profile is not listed in the self, then it is added with the given label (or file in case that label is None).

New in version 2.10.

set_active_profile(profile)
Parameters:

profile (Gimp.ColorProfile) – a Gimp.ColorProfile to set

Selects a color profile from the self and makes it the active item.

New in version 3.0.

Property Details

GimpUi.ColorProfileComboBox.props.dialog
Name:

dialog

Type:

Gtk.Dialog

Default Value:

None

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

Gtk.Dialog to present when the user selects the “Select color profile from disk…” item.

New in version 2.4.