EMailIdentityComboBox

EMailIdentityComboBox — Combo box of mail identities

Synopsis

#include <e-util/e-util.h>

struct              EMailIdentityComboBox;
GtkWidget *         e_mail_identity_combo_box_new       (ESourceRegistry *registry);
void                e_mail_identity_combo_box_refresh   (EMailIdentityComboBox *combo_box);
ESourceRegistry *   e_mail_identity_combo_box_get_registry
                                                        (EMailIdentityComboBox *combo_box);
gboolean            e_mail_identity_combo_box_get_allow_none
                                                        (EMailIdentityComboBox *combo_box);
void                e_mail_identity_combo_box_set_allow_none
                                                        (EMailIdentityComboBox *combo_box,
                                                         gboolean allow_none);

Description

EMailIdentity is a combo box of available mail identities, as described by ESource instances with an ESourceMailIdentity extension. For convenience, the combo box model's "id-column" is populated with ESource "uid" strings.

Details

struct EMailIdentityComboBox

struct EMailIdentityComboBox {
	GtkComboBox parent;
	EMailIdentityComboBoxPrivate *priv;
};

Contains only private data that should be read and manipulated using the functions below.


e_mail_identity_combo_box_new ()

GtkWidget *         e_mail_identity_combo_box_new       (ESourceRegistry *registry);

Creates a new EMailIdentityComboBox widget using ESource instances in registry.

registry :

an ESourceRegistry

Returns :

a new EMailIdentityComboBox

e_mail_identity_combo_box_refresh ()

void                e_mail_identity_combo_box_refresh   (EMailIdentityComboBox *combo_box);

Rebuilds the combo box model with an updated list of ESource instances that describe a mail identity, without disrupting the previously active item (if possible).

This function is called automatically in response to ESourceRegistry signals which are pertinent to the combo_box.

combo_box :

an EMailIdentityComboBox

e_mail_identity_combo_box_get_registry ()

ESourceRegistry *   e_mail_identity_combo_box_get_registry
                                                        (EMailIdentityComboBox *combo_box);

Returns the ESourceRegistry passed to e_mail_identity_combo_box_new().

combo_box :

an EMailIdentityComboBox

Returns :

an ESourceRegistry

e_mail_identity_combo_box_get_allow_none ()

gboolean            e_mail_identity_combo_box_get_allow_none
                                                        (EMailIdentityComboBox *combo_box);

Returns whether to append the mail identity list with a "None" item for use cases where the user may wish to opt out of choosing a mail identity.

combo_box :

an EMailIdentityComboBox

Returns :

whether to include a "None" option

e_mail_identity_combo_box_set_allow_none ()

void                e_mail_identity_combo_box_set_allow_none
                                                        (EMailIdentityComboBox *combo_box,
                                                         gboolean allow_none);

Sets whether to append the mail identity list with a "None" item for use cases where the user may wish to opt out of choosing a mail identity.

Changing this property will automatically rebuild the combo box model.

combo_box :

an EMailIdentityComboBox

allow_none :

whether to include a "None" option