![]() |
![]() |
![]() |
Libgnomedb 3.0 Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Implemented Interfaces | Properties |
GnomeDbEntryComboGnomeDbEntryCombo — A combo box to choose a value from a GdaParameterList |
GnomeDbEntryCombo; GnomeDbEntryComboClass; GnomeDbEntryComboPriv; GtkWidget * gnome_db_entry_combo_new (GdaParameterList *paramlist, GdaParameterListSource *source); gboolean gnome_db_entry_combo_set_values (GnomeDbEntryCombo *combo, GSList *values); GSList * gnome_db_entry_combo_get_values (GnomeDbEntryCombo *combo); GSList * gnome_db_entry_combo_get_all_values (GnomeDbEntryCombo *combo); void gnome_db_entry_combo_set_values_orig (GnomeDbEntryCombo *combo, GSList *values); GSList * gnome_db_entry_combo_get_values_orig (GnomeDbEntryCombo *combo); void gnome_db_entry_combo_set_values_default (GnomeDbEntryCombo *combo, GSList *values);
GObject +----GInitiallyUnowned +----GtkObject +----GtkWidget +----GtkContainer +----GtkBin +----GtkViewport +----GnomeDbEntryShell +----GnomeDbEntryCombo
GnomeDbEntryCombo implements GtkBuildable, AtkImplementorIface and GnomeDbDataEntry.
This widget allows the user to select a row from a GdaDataModel object, and set one or several values from that row. Specifically, it uses a GdaParameterListNode (within a GdaParameterList object), and synchonizes the values of the GdaParameter objects in that GdaParameterListNode.
typedef struct { GnomeDbEntryShellClass parent_class; } GnomeDbEntryComboClass;
GtkWidget * gnome_db_entry_combo_new (GdaParameterList *paramlist, GdaParameterListSource *source);
Creates a new GnomeDbEntryCombo widget. The widget is a combo box which displays a selectable list of items (the items come from the 'source->data_model' data model)
The widget allows the value setting of one or more GdaParameter objects (one for each 'source->nodes') while proposing potentially "more readable" choices.
|
a GdaParameterList object |
|
a GdaParameterListSource structure, part of paramlist
|
Returns : |
the new widget |
gboolean gnome_db_entry_combo_set_values (GnomeDbEntryCombo *combo, GSList *values);
Sets the values of combo
to the specified ones. None of the
values provided in the list is modified.
values
holds a list of GValue values, one for each parameter that is present in the node
argument
of the gnome_db_entry_combo_new()
function which created combo
.
An error can occur when there is no corresponding value(s) to be displayed for the provided values.
If values
is NULL
, then the entry itself is set to NULL;
|
a GnomeDbEntryCombo widet |
|
a list of GValue values, or NULL
|
Returns : |
TRUE if no error occurred. |
GSList * gnome_db_entry_combo_get_values (GnomeDbEntryCombo *combo);
Get the values stored within combo
. The returned values are the ones
within combo
, so they must not be freed afterwards, however the returned
list has to be freed afterwards.
|
a GnomeDbEntryCombo widet |
Returns : |
a new list of values |
GSList * gnome_db_entry_combo_get_all_values (GnomeDbEntryCombo *combo);
Get a list of all the values in combo
's data model's selected row. The list
must be freed by the caller.
|
a GnomeDbEntryCombo widet |
Returns : |
a new list of values |
void gnome_db_entry_combo_set_values_orig (GnomeDbEntryCombo *combo, GSList *values);
Sets the original values of combo
to the specified ones. None of the
values provided in the list is modified.
|
a GnomeDbEntryCombo widet |
|
a list of GValue values |
GSList * gnome_db_entry_combo_get_values_orig (GnomeDbEntryCombo *combo);
Get the original values stored within combo
. The returned values are the ones
within combo
, so they must not be freed afterwards; the list has to be freed afterwards.
|
a GnomeDbEntryCombo widet |
Returns : |
a new list of values |
void gnome_db_entry_combo_set_values_default (GnomeDbEntryCombo *combo, GSList *values);
Sets the default values of combo
to the specified ones. None of the
values provided in the list is modified.
|
a GnomeDbEntryCombo widet |
|
a list of GValue values |
"set-default-if-invalid"
property"set-default-if-invalid" gboolean : Read / Write
Default value: FALSE