Added two new signals to GtkSpinButton, "input" and "output", to make the

* gtk/gtkspinbutton.[c,h] gtk/testgtk.c: Added two new signals to
	GtkSpinButton, "input" and "output", to make the output more flexible.
 	The user has to provide a mapping between adjustment->value and the
 	output string (and vice versa, if the spin button is editable).
	See testgtk for examples.
This commit is contained in:
Stefan Jeske
1999-02-28 16:04:47 +00:00
parent e84df313c4
commit 209f5d5cd4
11 changed files with 463 additions and 105 deletions

View File

@ -47,6 +47,7 @@ extern "C" {
#define GTK_IS_SPIN_BUTTON(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_SPIN_BUTTON))
#define GTK_IS_SPIN_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_SPIN_BUTTON))
#define INPUT_ERROR -1
typedef enum
{
@ -101,6 +102,10 @@ struct _GtkSpinButton
struct _GtkSpinButtonClass
{
GtkEntryClass parent_class;
gint (*input) (GtkSpinButton *spin_button,
gfloat *new_value);
gint (*output) (GtkSpinButton *spin_button);
};