1/* ATK - Accessibility Toolkit
2 * Copyright 2001 Sun Microsystems Inc.
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; either
7 * version 2 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 * Library General Public License for more details.
13 *
14 * You should have received a copy of the GNU Library General Public
15 * License along with this library; if not, write to the
16 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17 * Boston, MA 02111-1307, USA.
18 */
19
20#ifndef __ATK_TABLE_H__
21#define __ATK_TABLE_H__
22
23#if defined(ATK_DISABLE_SINGLE_INCLUDES) && !defined(__ATK_H_INSIDE__) && !defined(ATK_COMPILATION)
24#error "Only <atk/atk.h> can be included directly."
25#endif
26
27#include <atk/atkobject.h>
28
29G_BEGIN_DECLS
30
31#define ATK_TYPE_TABLE (atk_table_get_type ())
32#define ATK_IS_TABLE(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_TABLE)
33#define ATK_TABLE(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_TABLE, AtkTable)
34#define ATK_TABLE_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_TABLE, AtkTableIface))
35
36#ifndef _TYPEDEF_ATK_TABLE_
37#define _TYPEDEF_ATK_TABLE_
38typedef struct _AtkTable AtkTable;
39#endif
40typedef struct _AtkTableIface AtkTableIface;
41
42struct _AtkTableIface
43{
44 GTypeInterface parent;
45
46 AtkObject *(*ref_at) (AtkTable *table,
47 gint row,
48 gint column);
49 gint (*get_index_at) (AtkTable *table,
50 gint row,
51 gint column);
52 gint (*get_column_at_index) (AtkTable *table,
53 gint index_);
54 gint (*get_row_at_index) (AtkTable *table,
55 gint index_);
56 gint (*get_n_columns) (AtkTable *table);
57 gint (*get_n_rows) (AtkTable *table);
58 gint (*get_column_extent_at) (AtkTable *table,
59 gint row,
60 gint column);
61 gint (*get_row_extent_at) (AtkTable *table,
62 gint row,
63 gint column);
64 AtkObject *(*get_caption) (AtkTable *table);
65 const gchar *(*get_column_description) (AtkTable *table,
66 gint column);
67 AtkObject *(*get_column_header) (AtkTable *table,
68 gint column);
69 const gchar *(*get_row_description) (AtkTable *table,
70 gint row);
71 AtkObject *(*get_row_header) (AtkTable *table,
72 gint row);
73 AtkObject *(*get_summary) (AtkTable *table);
74 void (*set_caption) (AtkTable *table,
75 AtkObject *caption);
76 void (*set_column_description) (AtkTable *table,
77 gint column,
78 const gchar *description);
79 void (*set_column_header) (AtkTable *table,
80 gint column,
81 AtkObject *header);
82 void (*set_row_description) (AtkTable *table,
83 gint row,
84 const gchar *description);
85 void (*set_row_header) (AtkTable *table,
86 gint row,
87 AtkObject *header);
88 void (*set_summary) (AtkTable *table,
89 AtkObject *accessible);
90 gint (*get_selected_columns) (AtkTable *table,
91 gint **selected);
92 gint (*get_selected_rows) (AtkTable *table,
93 gint **selected);
94 gboolean (*is_column_selected) (AtkTable *table,
95 gint column);
96 gboolean (*is_row_selected) (AtkTable *table,
97 gint row);
98 gboolean (*is_selected) (AtkTable *table,
99 gint row,
100 gint column);
101 gboolean (*add_row_selection) (AtkTable *table,
102 gint row);
103 gboolean (*remove_row_selection) (AtkTable *table,
104 gint row);
105 gboolean (*add_column_selection) (AtkTable *table,
106 gint column);
107 gboolean (*remove_column_selection) (AtkTable *table,
108 gint column);
109
110 /*
111 * signal handlers
112 */
113 void (*row_inserted) (AtkTable *table,
114 gint row,
115 gint num_inserted);
116 void (*column_inserted) (AtkTable *table,
117 gint column,
118 gint num_inserted);
119 void (*row_deleted) (AtkTable *table,
120 gint row,
121 gint num_deleted);
122 void (*column_deleted) (AtkTable *table,
123 gint column,
124 gint num_deleted);
125 void (*row_reordered) (AtkTable *table);
126 void (*column_reordered) (AtkTable *table);
127 void (*model_changed) (AtkTable *table);
128};
129
130ATK_AVAILABLE_IN_ALL
131GType atk_table_get_type (void);
132
133ATK_AVAILABLE_IN_ALL
134AtkObject *atk_table_ref_at (AtkTable *table,
135 gint row,
136 gint column);
137ATK_DEPRECATED_IN_2_12_FOR (atk_table_ref_at)
138gint atk_table_get_index_at (AtkTable *table,
139 gint row,
140 gint column);
141ATK_DEPRECATED_IN_2_12
142gint atk_table_get_column_at_index (AtkTable *table,
143 gint index_);
144ATK_DEPRECATED_IN_2_12
145gint atk_table_get_row_at_index (AtkTable *table,
146 gint index_);
147ATK_AVAILABLE_IN_ALL
148gint atk_table_get_n_columns (AtkTable *table);
149ATK_AVAILABLE_IN_ALL
150gint atk_table_get_n_rows (AtkTable *table);
151ATK_AVAILABLE_IN_ALL
152gint atk_table_get_column_extent_at (AtkTable *table,
153 gint row,
154 gint column);
155ATK_AVAILABLE_IN_ALL
156gint atk_table_get_row_extent_at (AtkTable *table,
157 gint row,
158 gint column);
159ATK_AVAILABLE_IN_ALL
160AtkObject *
161atk_table_get_caption (AtkTable *table);
162ATK_AVAILABLE_IN_ALL
163const gchar *atk_table_get_column_description (AtkTable *table,
164 gint column);
165ATK_AVAILABLE_IN_ALL
166AtkObject *atk_table_get_column_header (AtkTable *table,
167 gint column);
168ATK_AVAILABLE_IN_ALL
169const gchar *atk_table_get_row_description (AtkTable *table,
170 gint row);
171ATK_AVAILABLE_IN_ALL
172AtkObject *atk_table_get_row_header (AtkTable *table,
173 gint row);
174ATK_AVAILABLE_IN_ALL
175AtkObject *atk_table_get_summary (AtkTable *table);
176ATK_AVAILABLE_IN_ALL
177void atk_table_set_caption (AtkTable *table,
178 AtkObject *caption);
179ATK_AVAILABLE_IN_ALL
180void atk_table_set_column_description (AtkTable *table,
181 gint column,
182 const gchar *description);
183ATK_AVAILABLE_IN_ALL
184void atk_table_set_column_header (AtkTable *table,
185 gint column,
186 AtkObject *header);
187ATK_AVAILABLE_IN_ALL
188void atk_table_set_row_description (AtkTable *table,
189 gint row,
190 const gchar *description);
191ATK_AVAILABLE_IN_ALL
192void atk_table_set_row_header (AtkTable *table,
193 gint row,
194 AtkObject *header);
195ATK_AVAILABLE_IN_ALL
196void atk_table_set_summary (AtkTable *table,
197 AtkObject *accessible);
198ATK_AVAILABLE_IN_ALL
199gint atk_table_get_selected_columns (AtkTable *table,
200 gint **selected);
201ATK_AVAILABLE_IN_ALL
202gint atk_table_get_selected_rows (AtkTable *table,
203 gint **selected);
204ATK_AVAILABLE_IN_ALL
205gboolean atk_table_is_column_selected (AtkTable *table,
206 gint column);
207ATK_AVAILABLE_IN_ALL
208gboolean atk_table_is_row_selected (AtkTable *table,
209 gint row);
210ATK_AVAILABLE_IN_ALL
211gboolean atk_table_is_selected (AtkTable *table,
212 gint row,
213 gint column);
214ATK_AVAILABLE_IN_ALL
215gboolean atk_table_add_row_selection (AtkTable *table,
216 gint row);
217ATK_AVAILABLE_IN_ALL
218gboolean atk_table_remove_row_selection (AtkTable *table,
219 gint row);
220ATK_AVAILABLE_IN_ALL
221gboolean atk_table_add_column_selection (AtkTable *table,
222 gint column);
223ATK_AVAILABLE_IN_ALL
224gboolean atk_table_remove_column_selection (AtkTable *table,
225 gint column);
226
227G_END_DECLS
228
229#endif /* __ATK_TABLE_H__ */
230

source code of include/atk-1.0/atk/atktable.h