]> Pileus Git - ~andy/gtk/blob - gtk/a11y/gtkcellaccessibleparent.h
a11y: Update treeview focused status
[~andy/gtk] / gtk / a11y / gtkcellaccessibleparent.h
1 /* GAIL - The GNOME Accessibility Implementation Library
2  *
3  * Copyright 2001 Sun Microsystems Inc.
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Library General Public
7  * License as published by the Free Software Foundation; either
8  * version 2 of the License, or (at your option) any later version.
9  *
10  * This library is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13  * Library General Public License for more details.
14  *
15  * You should have received a copy of the GNU Library General Public
16  * License along with this library; if not, write to the
17  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18  * Boston, MA 02111-1307, USA.
19  */
20
21 #ifndef __GTK_CELL_ACCESSIBLE_PARENT_H__
22 #define __GTK_CELL_ACCESSIBLE_PARENT_H__
23
24 #include <atk/atk.h>
25 #include "gtkcellaccessible.h"
26
27 G_BEGIN_DECLS
28
29 /*
30  * The GtkCellAccessibleParent interface should be supported by any object
31  * which contains children which are flyweights, i.e. do not have corresponding
32  * widgets and the children need help from their parent to provide
33  * functionality. One example is GtkTreeViewAccessible where the children
34  * GtkCellAccessible need help from the GtkTreeViewAccessible in order to
35  * implement atk_component_get_extents().
36  */
37
38 #define GTK_TYPE_CELL_ACCESSIBLE_PARENT            (_gtk_cell_accessible_parent_get_type ())
39 #define GTK_IS_CELL_ACCESSIBLE_PARENT(obj)         G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_TYPE_CELL_ACCESSIBLE_PARENT)
40 #define GTK_CELL_ACCESSIBLE_PARENT(obj)            G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_CELL_ACCESSIBLE_PARENT, GtkCellAccessibleParent)
41 #define GTK_CELL_ACCESSIBLE_PARENT_GET_IFACE(obj)  (G_TYPE_INSTANCE_GET_INTERFACE ((obj), GTK_TYPE_CELL_ACCESSIBLE_PARENT, GtkCellAccessibleParentIface))
42
43 typedef struct _GtkCellAccessibleParent GtkCellAccessibleParent;
44 typedef struct _GtkCellAccessibleParentIface GtkCellAccessibleParentIface;
45
46 struct _GtkCellAccessibleParentIface
47 {
48   GTypeInterface parent;
49   void     ( *get_cell_extents) (GtkCellAccessibleParent *parent,
50                                  GtkCellAccessible       *cell,
51                                  gint                    *x,
52                                  gint                    *y,
53                                  gint                    *width,
54                                  gint                    *height,
55                                  AtkCoordType             coord_type);
56   void     ( *get_cell_area)    (GtkCellAccessibleParent *parent,
57                                  GtkCellAccessible       *cell,
58                                  GdkRectangle            *cell_rect);
59   gboolean ( *grab_focus)       (GtkCellAccessibleParent *parent,
60                                  GtkCellAccessible       *cell);
61   int      ( *get_child_index)  (GtkCellAccessibleParent *parent,
62                                  GtkCellAccessible       *cell);
63   GtkCellRendererState
64            ( *get_renderer_state) (GtkCellAccessibleParent *parent,
65                                  GtkCellAccessible       *cell);
66   /* actions */
67   void     ( *expand_collapse)  (GtkCellAccessibleParent *parent,
68                                  GtkCellAccessible       *cell);
69   void     ( *activate)         (GtkCellAccessibleParent *parent,
70                                  GtkCellAccessible       *cell);
71   void     ( *edit)             (GtkCellAccessibleParent *parent,
72                                  GtkCellAccessible       *cell);
73 };
74
75 GType    _gtk_cell_accessible_parent_get_type         (void);
76
77 void     _gtk_cell_accessible_parent_get_cell_extents (GtkCellAccessibleParent *parent,
78                                                        GtkCellAccessible       *cell,
79                                                        gint                    *x,
80                                                        gint                    *y,
81                                                        gint                    *width,
82                                                        gint                    *height,
83                                                        AtkCoordType             coord_type);
84 void     _gtk_cell_accessible_parent_get_cell_area    (GtkCellAccessibleParent *parent,
85                                                        GtkCellAccessible       *cell,
86                                                        GdkRectangle            *cell_rect);
87 gboolean _gtk_cell_accessible_parent_grab_focus       (GtkCellAccessibleParent *parent,
88                                                        GtkCellAccessible       *cell);
89 int      _gtk_cell_accessible_parent_get_child_index  (GtkCellAccessibleParent *parent,
90                                                        GtkCellAccessible       *cell);
91 GtkCellRendererState
92          _gtk_cell_accessible_parent_get_renderer_state(GtkCellAccessibleParent *parent,
93                                                        GtkCellAccessible       *cell);
94 void     _gtk_cell_accessible_parent_expand_collapse  (GtkCellAccessibleParent *parent,
95                                                        GtkCellAccessible       *cell);
96 void     _gtk_cell_accessible_parent_activate         (GtkCellAccessibleParent *parent,
97                                                        GtkCellAccessible       *cell);
98 void     _gtk_cell_accessible_parent_edit             (GtkCellAccessibleParent *parent,
99                                                        GtkCellAccessible       *cell);
100
101 G_END_DECLS
102
103 #endif /* __GTK_CELL_ACCESSIBLE_PARENT_H__ */