]> Pileus Git - ~andy/gtk/blob - gtk/a11y/gailcellparent.h
gail: No need to include modules/other in CFLAGS anymore
[~andy/gtk] / gtk / a11y / gailcellparent.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 __GAIL_CELL_PARENT_H__
22 #define __GAIL_CELL_PARENT_H__
23
24 #include <atk/atk.h>
25 #include "gailcell.h"
26
27 G_BEGIN_DECLS
28
29 /*
30  * The GailCellParent interface should be supported by any object which
31  * 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 GailTreeView where the children GailCell
34  * need help from the GailTreeView in order to implement 
35  * atk_component_get_extents
36  */
37
38 #define GAIL_TYPE_CELL_PARENT            (gail_cell_parent_get_type ())
39 #define GAIL_IS_CELL_PARENT(obj)         G_TYPE_CHECK_INSTANCE_TYPE ((obj), GAIL_TYPE_CELL_PARENT)
40 #define GAIL_CELL_PARENT(obj)            G_TYPE_CHECK_INSTANCE_CAST ((obj), GAIL_TYPE_CELL_PARENT, GailCellParent)
41 #define GAIL_CELL_PARENT_GET_IFACE(obj)  (G_TYPE_INSTANCE_GET_INTERFACE ((obj), GAIL_TYPE_CELL_PARENT, GailCellParentIface))
42
43 #ifndef _TYPEDEF_GAIL_CELL_PARENT_
44 #define _TYPEDEF_GAIL_CELL_PARENT_
45 typedef struct _GailCellParent GailCellParent;
46 #endif
47 typedef struct _GailCellParentIface GailCellParentIface;
48
49 struct _GailCellParentIface
50 {
51   GTypeInterface parent;
52   void                  ( *get_cell_extents)      (GailCellParent        *parent,
53                                                    GailCell              *cell,
54                                                    gint                  *x,
55                                                    gint                  *y,
56                                                    gint                  *width,
57                                                    gint                  *height,
58                                                    AtkCoordType          coord_type);
59   void                  ( *get_cell_area)         (GailCellParent        *parent,
60                                                    GailCell              *cell,
61                                                    GdkRectangle          *cell_rect);
62   gboolean              ( *grab_focus)            (GailCellParent        *parent,
63                                                    GailCell              *cell);
64 };
65
66 GType  gail_cell_parent_get_type               (void);
67
68 void   gail_cell_parent_get_cell_extents       (GailCellParent        *parent,
69                                                 GailCell              *cell,
70                                                 gint                  *x,
71                                                 gint                  *y,
72                                                 gint                  *width,
73                                                 gint                  *height,
74                                                 AtkCoordType          coord_type
75 );
76 void  gail_cell_parent_get_cell_area           (GailCellParent        *parent,
77                                                 GailCell              *cell,
78                                                 GdkRectangle          *cell_rect);
79 gboolean gail_cell_parent_grab_focus           (GailCellParent        *parent,
80                                                 GailCell              *cell);
81
82 G_END_DECLS
83
84 #endif /* __GAIL_CELL_PARENT_H__ */