More honesty about bug 144394, it's not quite fixed yet.
[dia.git] / app / diaunitspinner.h
blobee696784cb25b518bc8b5f5e0376057e4497f81c
1 /* Dia -- an diagram creation/manipulation program
2 * Copyright (C) 1998, 1999 Alexander Larsson
4 * diaunitspinner.[ch] -- a spin button widget for length measurements.
5 * Copyright (C) 1999 James Henstridge
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21 #error "Moved to lib/widgets.[hc]"
23 #ifndef DIAUNITSPINNER_H
24 #define DIAUNITSPINNER_H
26 #include <gtk/gtk.h>
28 #define DIA_UNIT_SPINNER(obj) GTK_CHECK_CAST(obj, dia_unit_spinner_get_type(), DiaUnitSpinner)
29 #define DIA_UNIT_SPINNER_CLASS(klass) GTK_CHECK_CLASS_CAST(klass, dia_unit_spinner_get_type(), DiaUnitSpinnerClass)
30 #define DIA_IS_UNIT_SPINNER(obj) GTK_CHECK_TYPE(obj, dia_unit_spinner_get_type())
32 typedef struct _DiaUnitSpinner DiaUnitSpinner;
33 typedef struct _DiaUnitSpinnerClass DiaUnitSpinnerClass;
35 typedef enum {
36 DIA_UNIT_FEET,
37 DIA_UNIT_METER,
38 DIA_UNIT_DECIMETER,
39 DIA_UNIT_MILLIMETER,
40 DIA_UNIT_POINT,
41 DIA_UNIT_CENTIMETER,
42 DIA_UNIT_INCH,
43 } DiaUnit;
45 struct _DiaUnitSpinner {
46 GtkSpinButton parent;
48 DiaUnit unit_num;
51 struct _DiaUnitSpinnerClass {
52 GtkSpinButtonClass parent_class;
56 GtkType dia_unit_spinner_get_type (void);
57 GtkWidget *dia_unit_spinner_new (GtkAdjustment *adjustment,
58 guint digits,
59 DiaUnit adj_unit);
60 void dia_unit_spinner_set_value (DiaUnitSpinner *self, gfloat val);
61 gfloat dia_unit_spinner_get_value (DiaUnitSpinner *self);
63 #endif