declare function arguments as (void) rather than ()
[platform/upstream/atk.git] / atk / atktable.c
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 Lesser 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  * 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
16  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17  * Boston, MA 02111-1307, USA.
18  */
19
20 #include "atktable.h"
21 #include "atkmarshal.h"
22
23 enum {
24   ROW_INSERTED,
25   ROW_DELETED,
26   COLUMN_INSERTED,
27   COLUMN_DELETED,
28   ROW_REORDERED,
29   COLUMN_REORDERED,
30   MODEL_CHANGED,
31   LAST_SIGNAL
32 };
33
34 static void  atk_table_base_init (gpointer *g_class);
35
36 static guint atk_table_signals[LAST_SIGNAL] = { 0 };
37
38 GType
39 atk_table_get_type (void)
40 {
41   static GType type = 0;
42   
43   if (!type) {
44     GTypeInfo tinfo =
45     {
46       sizeof (AtkTableIface),
47       (GBaseInitFunc) atk_table_base_init,
48       (GBaseFinalizeFunc) NULL,
49       
50     };
51     
52     type = g_type_register_static (G_TYPE_INTERFACE, "AtkTable", &tinfo, 0);
53   }
54   
55   return type;
56 }
57
58
59 static void
60 atk_table_base_init (gpointer *g_class)
61 {
62   static gboolean initialized = FALSE;
63   
64   if (!initialized)
65     {
66       atk_table_signals[ROW_INSERTED] =
67         g_signal_new ("row_inserted",
68                       ATK_TYPE_TABLE,
69                       G_SIGNAL_RUN_LAST,
70                       G_STRUCT_OFFSET (AtkTableIface, row_inserted),
71                       (GSignalAccumulator) NULL, NULL,
72                       atk_marshal_VOID__INT_INT,
73                       G_TYPE_NONE,
74                       2, G_TYPE_INT, G_TYPE_INT);
75       atk_table_signals[COLUMN_INSERTED] =
76         g_signal_new ("column_inserted",
77                       ATK_TYPE_TABLE,
78                       G_SIGNAL_RUN_LAST,
79                       G_STRUCT_OFFSET (AtkTableIface, column_inserted),
80                       (GSignalAccumulator) NULL, NULL,
81                       atk_marshal_VOID__INT_INT,
82                       G_TYPE_NONE,
83                       2, G_TYPE_INT, G_TYPE_INT);
84       atk_table_signals[ROW_DELETED] =
85         g_signal_new ("row_deleted",
86                       ATK_TYPE_TABLE,
87                       G_SIGNAL_RUN_LAST,
88                       G_STRUCT_OFFSET (AtkTableIface, row_deleted),
89                       (GSignalAccumulator) NULL, NULL,
90                       atk_marshal_VOID__INT_INT,
91                       G_TYPE_NONE,
92                       2, G_TYPE_INT, G_TYPE_INT);
93       atk_table_signals[COLUMN_DELETED] =
94         g_signal_new ("column_deleted",
95                       ATK_TYPE_TABLE,
96                       G_SIGNAL_RUN_LAST,
97                       G_STRUCT_OFFSET (AtkTableIface, column_deleted),
98                       (GSignalAccumulator) NULL, NULL,
99                       atk_marshal_VOID__INT_INT,
100                       G_TYPE_NONE,
101                       2, G_TYPE_INT, G_TYPE_INT);
102       atk_table_signals[ROW_REORDERED] =
103         g_signal_new ("row_reordered",
104                       ATK_TYPE_TABLE,
105                       G_SIGNAL_RUN_LAST,
106                       G_STRUCT_OFFSET (AtkTableIface, row_reordered),
107                       (GSignalAccumulator) NULL, NULL,
108                       g_cclosure_marshal_VOID__VOID,
109                       G_TYPE_NONE,
110                       0);
111       atk_table_signals[COLUMN_REORDERED] =
112         g_signal_new ("column_reordered",
113                       ATK_TYPE_TABLE,
114                       G_SIGNAL_RUN_LAST,
115                       G_STRUCT_OFFSET (AtkTableIface, column_reordered),
116                       (GSignalAccumulator) NULL, NULL,
117                       g_cclosure_marshal_VOID__VOID,
118                       G_TYPE_NONE,
119                       0);
120       atk_table_signals[MODEL_CHANGED] =
121         g_signal_new ("model_changed",
122                       ATK_TYPE_TABLE,
123                       G_SIGNAL_RUN_LAST,
124                       G_STRUCT_OFFSET (AtkTableIface, model_changed),
125                       (GSignalAccumulator) NULL, NULL,
126                       g_cclosure_marshal_VOID__VOID,
127                       G_TYPE_NONE, 0);
128
129       initialized = TRUE;
130     }
131 }
132
133 /**
134  * atk_table_ref_at:
135  * @table: a GObject instance that implements AtkTableIface
136  * @row: a #gint representing a row in @table
137  * @column: a #gint representing a column in @table
138  *
139  * Get a reference to the table cell at @row, @column.
140  *
141  * Returns: a AtkObject* representing the referred to accessible
142  **/
143 AtkObject*
144 atk_table_ref_at (AtkTable *table,
145                   gint     row,
146                   gint     column)
147 {
148   AtkTableIface *iface;
149
150   g_return_val_if_fail (ATK_IS_TABLE (table), NULL);
151
152   iface = ATK_TABLE_GET_IFACE (table);
153
154   if (iface->ref_at)
155     return (iface->ref_at) (table, row, column);
156   else
157     return NULL;
158 }
159
160 /**
161  * atk_table_get_index_at:
162  * @table: a GObject instance that implements AtkTableIface
163  * @row: a #gint representing a row in @table
164  * @column: a #gint representing a column in @table
165  *
166  * Gets a #gint representing the index at the specified @row and @column.
167  * The value -1 is returned if the object at row,column is not a child
168  * of table or table does not implement this interface.
169  *
170  * Returns: a #gint representing the index at specified position 
171  **/
172 gint
173 atk_table_get_index_at (AtkTable *table,
174                         gint     row,
175                         gint     column)
176 {
177   AtkTableIface *iface;
178
179   g_return_val_if_fail (ATK_IS_TABLE (table), -1);
180   g_return_val_if_fail (row >= 0, -1);
181   g_return_val_if_fail (column >= 0, -1);
182
183   iface = ATK_TABLE_GET_IFACE (table);
184
185   if (iface->get_index_at)
186     return (iface->get_index_at) (table, row, column);
187   else
188     return -1;
189 }
190
191 /**
192  * atk_table_get_row_at_index:
193  * @table: a GObject instance that implements AtkTableInterface
194  * @index: a #gint representing an index in @table
195  *
196  * Gets a #gint representing the row at the specified @index, or -1
197  * if the table does not implement this interface
198  *
199  * Returns: a gint representing the row at the specified index.
200  **/
201 gint
202 atk_table_get_row_at_index (AtkTable *table,
203                             gint     index)
204 {
205   AtkTableIface *iface;
206
207   g_return_val_if_fail (ATK_IS_TABLE (table), -1);
208
209   iface = ATK_TABLE_GET_IFACE (table);
210
211   if (iface->get_row_at_index)
212     return (iface->get_row_at_index) (table, index);
213   else
214     return -1;
215 }
216
217 /**
218  * atk_table_get_column_at_index:
219  * @table: a GObject instance that implements AtkTableInterface
220  * @index: a #gint representing an index in @table
221  *
222  * Gets a #gint representing the column at the specified @index, or -1
223  * if the table does not implement this interface
224  *
225  * Returns: a gint representing the column at the specified index.
226  **/
227 gint
228 atk_table_get_column_at_index (AtkTable *table,
229                                gint     index)
230 {
231   AtkTableIface *iface;
232
233   g_return_val_if_fail (ATK_IS_TABLE (table), 0);
234
235   iface = ATK_TABLE_GET_IFACE (table);
236
237   if (iface->get_column_at_index)
238     return (iface->get_column_at_index) (table, index);
239   else
240     return -1;
241 }
242
243 /**
244  * atk_table_get_caption:
245  * @table: a GObject instance that implements AtkTableInterface
246  *
247  * Gets the caption for the @table.
248  *
249  * Returns: a AtkObject* representing the table caption, or %NULL
250  * if value does not implement this interface.
251  **/
252 AtkObject*
253 atk_table_get_caption (AtkTable *table)
254 {
255   AtkTableIface *iface;
256
257   g_return_val_if_fail (ATK_IS_TABLE (table), NULL);
258
259   iface = ATK_TABLE_GET_IFACE (table);
260
261   if (iface->get_caption)
262     return (iface->get_caption) (table);
263   else
264     return NULL;
265 }
266
267 /**
268  * atk_table_get_n_columns:
269  * @table: a GObject instance that implements AtkTableIface
270  *
271  * Gets the number of columns in the table.
272  *
273  * Returns: a gint representing the number of columns, or 0
274  * if value does not implement this interface.
275  **/
276 gint
277 atk_table_get_n_columns (AtkTable *table)
278 {
279   AtkTableIface *iface;
280
281   g_return_val_if_fail (ATK_IS_TABLE (table), 0);
282
283   iface = ATK_TABLE_GET_IFACE (table);
284
285   if (iface->get_n_columns)
286     return (iface->get_n_columns) (table);
287   else
288     return 0;
289 }
290
291 /**
292  * atk_table_get_column_description:
293  * @table: a GObject instance that implements AtkTableIface
294  * @column: a #gint representing a column in @table
295  *
296  * Gets the description text of the specified @column in the table
297  *
298  * Returns: a gchar* representing the column description, or %NULL
299  * if value does not implement this interface.
300  **/
301 G_CONST_RETURN gchar*
302 atk_table_get_column_description (AtkTable *table,
303                                   gint     column)
304 {
305   AtkTableIface *iface;
306
307   g_return_val_if_fail (ATK_IS_TABLE (table), NULL);
308
309   iface = ATK_TABLE_GET_IFACE (table);
310
311   if (iface->get_column_description)
312     return (iface->get_column_description) (table, column);
313   else
314     return NULL;
315 }
316
317 /**
318  * atk_table_get_column_extent_at:
319  * @table: a GObject instance that implements AtkTableIface
320  * @row: a #gint representing a row in @table
321  * @column: a #gint representing a column in @table
322  *
323  * Gets the number of columns occupied by the accessible object
324  * at the specified @row and @column in the @table.
325  *
326  * Returns: a gint representing the column extent at specified position, or 0
327  * if value does not implement this interface.
328  **/
329 gint
330 atk_table_get_column_extent_at (AtkTable *table,
331                                 gint     row,
332                                 gint     column)
333 {
334   AtkTableIface *iface;
335
336   g_return_val_if_fail (ATK_IS_TABLE (table), 0);
337
338   iface = ATK_TABLE_GET_IFACE (table);
339
340   if (iface->get_column_extent_at)
341     return (iface->get_column_extent_at) (table, row, column);
342   else
343     return 0;
344 }
345
346 /**
347  * atk_table_get_column_header:
348  * @table: a GObject instance that implements AtkTableIface
349  * @column: a #gint representing a column in the table
350  *
351  * Gets the column header of a specified column in an accessible table.
352  *
353  * Returns: a AtkObject* representing the specified column header, or
354  * %NULL if value does not implement this interface.
355  **/
356 AtkObject*
357 atk_table_get_column_header (AtkTable *table, gint column)
358 {
359   AtkTableIface *iface;
360
361   g_return_val_if_fail (ATK_IS_TABLE (table), NULL);
362
363   iface = ATK_TABLE_GET_IFACE (table);
364
365   if (iface->get_column_header)
366     return (iface->get_column_header) (table, column);
367   else
368     return NULL;
369 }
370
371 /**
372  * atk_table_get_n_rows:
373  * @table: a GObject instance that implements AtkTableIface
374  *
375  * Gets the number of rows in the table.
376  *
377  * Returns: a gint representing the number of rows, or 0
378  * if value does not implement this interface.
379  **/
380 gint
381 atk_table_get_n_rows (AtkTable *table)
382 {
383   AtkTableIface *iface;
384
385   g_return_val_if_fail (ATK_IS_TABLE (table), 0);
386
387   iface = ATK_TABLE_GET_IFACE (table);
388
389   if (iface->get_n_rows)
390     return (iface->get_n_rows) (table);
391   else
392     return 0;
393 }
394
395 /**
396  * atk_table_get_row_description:
397  * @table: a GObject instance that implements AtkTableIface
398  * @row: a #gint representing a row in @table
399  *
400  * Gets the description text of the specified row in the table
401  *
402  * Returns: a gchar* representing the row description, or %NULL
403  * if value does not implement this interface.
404  **/
405 G_CONST_RETURN gchar*
406 atk_table_get_row_description (AtkTable *table,
407                                gint      row)
408 {
409   AtkTableIface *iface;
410
411   g_return_val_if_fail (ATK_IS_TABLE (table), NULL);
412
413   iface = ATK_TABLE_GET_IFACE (table);
414
415   if (iface->get_row_description)
416     return (iface->get_row_description) (table, row);
417   else
418     return NULL;
419 }
420
421 /**
422  * atk_table_get_row_extent_at:
423  * @table: a GObject instance that implements AtkTableIface
424  * @row: a #gint representing a row in @table
425  * @column: a #gint representing a column in @table
426  *
427  * Gets the number of rows occupied by the accessible object
428  * at a specified @row and @column in the @table.
429  *
430  * Returns: a gint representing the row extent at specified position, or 0
431  * if value does not implement this interface.
432  **/
433 gint
434 atk_table_get_row_extent_at (AtkTable *table,
435                              gint     row,
436                              gint     column)
437 {
438   AtkTableIface *iface;
439
440   g_return_val_if_fail (ATK_IS_TABLE (table), 0);
441
442   iface = ATK_TABLE_GET_IFACE (table);
443
444   if (iface->get_row_extent_at)
445     return (iface->get_row_extent_at) (table, row, column);
446   else
447     return 0;
448 }
449
450 /**
451  * atk_table_get_row_header:
452  * @table: a GObject instance that implements AtkTableIface
453  * @row: a #gint representing a row in the table
454  *
455  * Gets the row header of a specified row in an accessible table.
456  *
457  * Returns: a AtkObject* representing the specified row header, or
458  * %NULL if value does not implement this interface.
459  **/
460 AtkObject*
461 atk_table_get_row_header (AtkTable *table, gint row)
462 {
463   AtkTableIface *iface;
464
465   g_return_val_if_fail (ATK_IS_TABLE (table), NULL);
466
467   iface = ATK_TABLE_GET_IFACE (table);
468
469   if (iface->get_row_header)
470     return (iface->get_row_header) (table, row);
471   else
472     return NULL;
473 }
474
475 /**
476  * atk_table_get_summary:
477  * @table: a GObject instance that implements AtkTableIface
478  *
479  * Gets the summary description of the table.
480  *
481  * Returns: a AtkObject* representing a summary description of the table,
482  * or zero if value does not implement this interface.
483  **/
484 AtkObject*
485 atk_table_get_summary (AtkTable *table)
486 {
487   AtkTableIface *iface;
488
489   g_return_val_if_fail (ATK_IS_TABLE (table), NULL);
490
491   iface = ATK_TABLE_GET_IFACE (table);
492
493   if (iface->get_summary)
494     return (iface->get_summary) (table);
495   else
496     return NULL;
497 }
498
499 /**
500  * atk_table_get_selected_rows:
501  * @table: a GObject instance that implements AtkTableIface
502  * @selected: a #gint** that is to contain the selected row numbers
503  *
504  * Gets the selected rows of the table by initializing **selected with 
505  * the selected row numbers. This array should be freed by the caller.
506  *
507  * Returns: a gint representing the number of selected rows,
508  * or zero if value does not implement this interface.
509  **/
510 gint
511 atk_table_get_selected_rows (AtkTable *table, gint **selected)
512 {
513   AtkTableIface *iface;
514
515   g_return_val_if_fail (ATK_IS_TABLE (table), 0);
516
517   iface = ATK_TABLE_GET_IFACE (table);
518
519   if (iface->get_selected_rows)
520     return (iface->get_selected_rows) (table, selected);
521   else
522     return 0;
523 }
524
525 /**
526  * atk_table_get_selected_columns:
527  * @table: a GObject instance that implements AtkTableIface
528  * @selected: a #gint** that is to contain the selected columns numbers
529  *
530  * Gets the selected columns of the table by initializing **selected with 
531  * the selected column numbers. This array should be freed by the caller.
532  *
533  * Returns: a gint representing the number of selected columns,
534  * or %0 if value does not implement this interface.
535  **/
536 gint 
537 atk_table_get_selected_columns (AtkTable *table, gint **selected)
538 {
539   AtkTableIface *iface;
540
541   g_return_val_if_fail (ATK_IS_TABLE (table), 0);
542
543   iface = ATK_TABLE_GET_IFACE (table);
544
545   if (iface->get_selected_columns)
546     return (iface->get_selected_columns) (table, selected);
547   else
548     return 0;
549 }
550
551 /**
552  * atk_table_is_column_selected:
553  * @table: a GObject instance that implements AtkTableIface
554  * @column: a #gint representing a column in @table
555  *
556  * Gets a boolean value indicating whether the specified @column
557  * is selected
558  *
559  * Returns: a gboolean representing if the column is selected, or 0
560  * if value does not implement this interface.
561  **/
562 gboolean
563 atk_table_is_column_selected (AtkTable *table,
564                               gint     column)
565 {
566   AtkTableIface *iface;
567
568   g_return_val_if_fail (ATK_IS_TABLE (table), FALSE);
569
570   iface = ATK_TABLE_GET_IFACE (table);
571
572   if (iface->is_column_selected)
573     return (iface->is_column_selected) (table, column);
574   else
575     return FALSE;
576 }
577
578 /**
579  * atk_table_is_row_selected:
580  * @table: a GObject instance that implements AtkTableIface
581  * @row: a #gint representing a row in @table
582  *
583  * Gets a boolean value indicating whether the specified @row
584  * is selected
585  *
586  * Returns: a gboolean representing if the row is selected, or 0
587  * if value does not implement this interface.
588  **/
589 gboolean
590 atk_table_is_row_selected (AtkTable *table,
591                            gint     row)
592 {
593   AtkTableIface *iface;
594
595   g_return_val_if_fail (ATK_IS_TABLE (table), FALSE);
596
597   iface = ATK_TABLE_GET_IFACE (table);
598
599   if (iface->is_row_selected)
600     return (iface->is_row_selected) (table, row);
601   else
602     return FALSE;
603 }
604
605 /**
606  * atk_table_is_selected:
607  * @table: a GObject instance that implements AtkTableIface
608  * @row: a #gint representing a row in @table
609  * @column: a #gint representing a column in @table
610  *
611  * Gets a boolean value indicating whether the accessible object
612  * at the specified @row and @column is selected
613  *
614  * Returns: a gboolean representing if the cell is selected, or 0
615  * if value does not implement this interface.
616  **/
617 gboolean
618 atk_table_is_selected (AtkTable *table,
619                        gint     row,
620                        gint     column)
621 {
622   AtkTableIface *iface;
623
624   g_return_val_if_fail (ATK_IS_TABLE (table), FALSE);
625
626   iface = ATK_TABLE_GET_IFACE (table);
627
628   if (iface->is_selected)
629     return (iface->is_selected) (table, row, column);
630   else
631     return FALSE;
632 }
633
634 /**
635  * atk_table_add_row_selection:
636  * @table: a GObject instance that implements AtkTableIface
637  * @row: a #gint representing a row in @table
638  *
639  * Adds the specified @row to the selection. 
640  *
641  * Returns: a gboolean representing if row was successfully added to selection,
642  * or 0 if value does not implement this interface.
643  **/
644 gboolean
645 atk_table_add_row_selection (AtkTable *table,
646                                  gint     row)
647 {
648   AtkTableIface *iface;
649
650   g_return_val_if_fail (ATK_IS_TABLE (table), FALSE);
651
652   iface = ATK_TABLE_GET_IFACE (table);
653
654   if (iface->add_row_selection)
655     return (iface->add_row_selection) (table, row);
656   else
657     return FALSE;
658 }
659 /**
660  * atk_table_remove_row_selection:
661  * @table: a GObject instance that implements AtkTableIface
662  * @row: a #gint representing a row in @table
663  *
664  * Removes the specified @row from the selection. 
665  *
666  * Returns: a gboolean representing if the row was successfully removed from
667  * the selection, or 0 if value does not implement this interface.
668  **/
669 gboolean
670 atk_table_remove_row_selection (AtkTable *table,
671                                     gint     row)
672 {
673   AtkTableIface *iface;
674
675   g_return_val_if_fail (ATK_IS_TABLE (table), FALSE);
676
677   iface = ATK_TABLE_GET_IFACE (table);
678
679   if (iface->remove_row_selection)
680     return (iface->remove_row_selection) (table, row);
681   else
682     return FALSE;
683 }
684 /**
685  * atk_table_add_column_selection:
686  * @table: a GObject instance that implements AtkTableIface
687  * @column: a #gint representing a column in @table
688  *
689  * Adds the specified @column to the selection. 
690  *
691  * Returns: a gboolean representing if the column was successfully added to 
692  * the selection, or 0 if value does not implement this interface.
693  **/
694 gboolean
695 atk_table_add_column_selection (AtkTable *table,
696                                     gint     column)
697 {
698   AtkTableIface *iface;
699
700   g_return_val_if_fail (ATK_IS_TABLE (table), FALSE);
701
702   iface = ATK_TABLE_GET_IFACE (table);
703
704   if (iface->add_column_selection)
705     return (iface->add_column_selection) (table, column);
706   else
707     return FALSE;
708 }
709 /**
710  * atk_table_remove_column_selection:
711  * @table: a GObject instance that implements AtkTableIface
712  * @column: a #gint representing a column in @table
713  *
714  * Adds the specified @column to the selection. 
715  *
716  * Returns: a gboolean representing if the column was successfully removed from
717  * the selection, or 0 if value does not implement this interface.
718  **/
719 gboolean
720 atk_table_remove_column_selection (AtkTable *table,
721                                            gint     column)
722 {
723   AtkTableIface *iface;
724
725   g_return_val_if_fail (ATK_IS_TABLE (table), FALSE);
726
727   iface = ATK_TABLE_GET_IFACE (table);
728
729   if (iface->remove_column_selection)
730     return (iface->remove_column_selection) (table, column);
731   else
732     return FALSE;
733 }
734
735 /**
736  * atk_table_set_caption:
737  * @table: a GObject instance that implements AtkTableIface
738  * @caption: a #AtkObject representing the caption to set for @table
739  *
740  * Sets the caption for the table.
741  **/
742 void
743 atk_table_set_caption (AtkTable       *table,
744                        AtkObject      *caption)
745 {
746   AtkTableIface *iface;
747
748   g_return_if_fail (ATK_IS_TABLE (table));
749
750   iface = ATK_TABLE_GET_IFACE (table);
751
752   if (iface->set_caption)
753     (iface->set_caption) (table, caption);
754 }
755
756 /**
757  * atk_table_set_column_description:
758  * @table: a GObject instance that implements AtkTableIface
759  * @column: a #gint representing a column in @table
760  * @description: a #gchar representing the description text
761  * to set for the specified @column of the @table
762  *
763  * Sets the description text for the specified @column of the @table.
764  **/
765 void
766 atk_table_set_column_description (AtkTable       *table,
767                                   gint           column,
768                                   const gchar    *description)
769 {
770   AtkTableIface *iface;
771
772   g_return_if_fail (ATK_IS_TABLE (table));
773
774   iface = ATK_TABLE_GET_IFACE (table);
775
776   if (iface->set_column_description)
777     (iface->set_column_description) (table, column, description);
778 }
779
780 /**
781  * atk_table_set_column_header:
782  * @table: a GObject instance that implements AtkTableIface
783  * @column: a #gint representing a column in @table
784  * @header: an #AtkTable
785  *
786  * Sets the specified column header to @header.
787  **/
788 void
789 atk_table_set_column_header (AtkTable  *table,
790                              gint      column,
791                              AtkObject *header)
792 {
793   AtkTableIface *iface;
794
795   g_return_if_fail (ATK_IS_TABLE (table));
796
797   iface = ATK_TABLE_GET_IFACE (table);
798
799   if (iface->set_column_header)
800     (iface->set_column_header) (table, column, header);
801 }
802
803 /**
804  * atk_table_set_row_description:
805  * @table: a GObject instance that implements AtkTableIface
806  * @row: a #gint representing a row in @table
807  * @description: a #gchar representing the description text
808  * to set for the specified @row of @table
809  *
810  * Sets the description text for the specified @row of @table.
811  **/
812 void
813 atk_table_set_row_description (AtkTable       *table,
814                                gint           row,
815                                const gchar    *description)
816 {
817   AtkTableIface *iface;
818
819   g_return_if_fail (ATK_IS_TABLE (table));
820
821   iface = ATK_TABLE_GET_IFACE (table);
822
823   if (iface->set_row_description)
824     (iface->set_row_description) (table, row, description);
825 }
826
827 /**
828  * atk_table_set_row_header:
829  * @table: a GObject instance that implements AtkTableIface
830  * @row: a #gint representing a row in @table
831  * @header: an #AtkTable 
832  *
833  * Sets the specified row header to @header.
834  **/
835 void
836 atk_table_set_row_header (AtkTable  *table,
837                           gint      row,
838                           AtkObject *header)
839 {
840   AtkTableIface *iface;
841
842   g_return_if_fail (ATK_IS_TABLE (table));
843
844   iface = ATK_TABLE_GET_IFACE (table);
845
846   if (iface->set_row_header)
847     (iface->set_row_header) (table, row, header);
848 }
849
850 /**
851  * atk_table_set_summary:
852  * @table: a GObject instance that implements AtkTableIface
853  * @accessible: an #AtkObject representing the summary description
854  * to set for @table
855  *
856  * Sets the summary description of the table.
857  **/
858 void
859 atk_table_set_summary (AtkTable       *table,
860                        AtkObject      *accessible)
861 {
862   AtkTableIface *iface;
863
864   g_return_if_fail (ATK_IS_TABLE (table));
865
866   iface = ATK_TABLE_GET_IFACE (table);
867
868   if (iface->set_summary)
869     (iface->set_summary) (table, accessible);
870 }