Ben's patches to tower.[ch]
[pspp-builds.git] / lib / gtksheet / gsheet-hetero-column.h
1 /* GtkSheet widget for Gtk+.
2  * Copyright (C) 2006 Free Software Foundation
3
4  * This library is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Lesser General Public
6  * License as published by the Free Software Foundation; either
7  * version 2.1 of the License, or (at your option) any later version.
8  *
9  * This library is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12  * Lesser General Public License for more details.
13  *
14  * You should have received a copy of the GNU Lesser General Public
15  * License along with this library; if not, write to the Free Software
16  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
17  */
18
19 #ifndef __G_SHEET_HETERO_COLUMN_H__
20 #define __G_SHEET_HETERO_COLUMN_H__
21
22 #include <glib-object.h>
23 #include <glib.h>
24
25
26 #ifdef __cplusplus
27 extern "C" {
28 #endif /* __cplusplus */
29
30
31 #define G_TYPE_SHEET_HETERO_COLUMN (g_sheet_hetero_column_get_type ())
32
33 #define G_SHEET_HETERO_COLUMN(obj)    G_TYPE_CHECK_INSTANCE_CAST (obj, G_TYPE_SHEET_HETERO_COLUMN, GSheetHeteroColumn )
34 #define G_SHEET_HETERO_COLUMN_CLASS(klass)  G_TYPE_CHECK_CLASS_CAST (klass, g_sheet_hetero_column_get_type (), GSheetHeteroColumnClass)
35 #define G_IS_SHEET_HETERO_COLUMN(obj)  G_TYPE_CHECK_INSTANCE_TYPE (obj, G_TYPE_SHEET_HETERO_COLUMN)
36
37
38   struct GSheetHeteroColumnUnit
39   {
40     GtkSheetButton button;
41
42     gint width;
43     gboolean is_sensitive;
44   };
45
46
47   struct _GSheetHeteroColumn{
48     GObject parent;
49
50     gint n_columns;
51     gint default_width;
52
53     struct GSheetHeteroColumnUnit *col;
54
55   };
56
57   struct _GSheetHeteroColumnClass
58   {
59     GObjectClass parent_class;
60   };
61
62
63
64
65   /* create a new column */
66   GObject * g_sheet_hetero_column_new (gint default_width, gint n_columns);
67
68   GType g_sheet_hetero_column_get_type (void);
69
70
71   typedef struct _GSheetHeteroColumn GSheetHeteroColumn;
72   typedef struct _GSheetHeteroColumnClass GSheetHeteroColumnClass;
73
74
75   void g_sheet_hetero_column_set_button_label (GSheetHeteroColumn *geo,
76                                                 glong i, const gchar *label);
77
78   void g_sheet_hetero_column_set_width (GSheetHeteroColumn *geo,
79                                              glong i, gint size);
80
81 #ifdef __cplusplus
82 }
83 #endif /* __cplusplus */
84
85 #endif /* __G_SHEET_HETERO_COLUMN_H__ */
86
87