Overview of the GDA widgets

This section contains an overview of what can be done with the widgets provided by the GDA UI library. It contains short explanations of the basic fonctionality and use of each widget.

GnomeDbLogin widget

The GnomeDbLogin widget provides a custom way of visually connecting your application to a GDA provider. It can be added to any container widget, so that you can create, for example, a dialog box, and then add the GnomeDbLogin widget to it.

At initialization, it reads the GDA configuration file ($HOME/.gnome/gdalib), and provides a combo box containing all user-configured data sources. The user just have to select the data source and provide his/her username and password.

You know when a connection is open by connecting to the "open" signal, which is emitted when a valid connection has been selected and opened by the user.

GnomeDbLoginDlg widget

This is a convenience widget which simply contains a GnomeDbLogin widget. It is a subclass of GnomeDialog, so you'll expect it to have a common look&feel with the rest of your application.

This widget not only does it contain the GnomeDbLogin widget, but it catches itself the containee's signals, so if you use it, you should connect to the GnomeDbLoginDlg signals instead of the GnomeDbLogin ones.

GnomeDbBrowser widget

This is a very complete widget that allows to browse the entire database, from tables and views to users and stored procedures. The most simple case where you'll want to use this widget is to create a container and add the GnomeDbBrowser widget to it. Simply doing this will bring a complete database browser to your application.

GnomeDbGrid widget

This is the most used widget in the library. It provides a way to visually inspect a Gda_Recordset's contents. The database access part responsibility is taken entirely by the widget. You just have to pass it valid recordsets to show.

GnomeDbCombo widget

This widget is a very useful one. It is mainly used in data input screens, providing a way by which the user can select a value from a list of values for a given field.

It works mainly as the GnomeDbGrid widget, since it works based on the Gda_Recordset's you pass to it, but in this case, you must specify which of the columns in the recordset is to be shown.

GnomeDbList widget

The GnomeDbList widget lets you show a list of values for a given field in a recordset. It also lets you decorate the list with icons, resulting in a well looking widget to be included in your database access screens.

GnomeDbReport widget

The GnomeDbReport widget provides a way of presenting to the user customizable reports based on data coming from a Gda_Connection.

The report structure is stored in XML format, which makes it possible for sharing data with other unrelated applications. This widget just reads this XML file, gets the specified data from a database and presents it to the user based on the format instructions specified by the report structure.

GnomeDbError widget

The GnomeDbError widget provides a way to browse through all the errors occured for a given Gda_Connection object. You can use it to inform the user whenever an error occurs, or as an informational widget.

GnomeDbErrorDlg widget

As the GnomeDbLoginDlg widget, the GnomeDbErrorDlg widget is just a convenience GnomeDialog subclass which just contains a GnomeDbError widget.