1 /* GDK - The GIMP Drawing Kit
2 * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
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.
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.
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.
21 * Modified by the GTK+ Team and others 1997-2000. See the AUTHORS
22 * file for a list of people on the GTK+ Team. See the ChangeLog
23 * files for a list of changes. These files are distributed with
24 * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
27 #ifndef __GDK_WINDOW_IMPL_H__
28 #define __GDK_WINDOW_IMPL_H__
30 #include <gdk/gdkwindow.h>
34 #define GDK_TYPE_WINDOW_IMPL (gdk_window_impl_get_type ())
35 #define GDK_WINDOW_IMPL(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GDK_TYPE_WINDOW_IMPL, GdkWindowImpl))
36 #define GDK_IS_WINDOW_IMPL(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GDK_TYPE_WINDOW_IMPL))
37 #define GDK_WINDOW_IMPL_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), GDK_TYPE_WINDOW_IMPL, GdkWindowImplIface))
39 typedef struct _GdkWindowImpl GdkWindowImpl; /* dummy */
40 typedef struct _GdkWindowImplIface GdkWindowImplIface;
42 struct _GdkWindowImplIface
44 GTypeInterface g_iface;
46 void (* show) (GdkWindow *window,
47 gboolean already_mapped);
48 void (* hide) (GdkWindow *window);
49 void (* withdraw) (GdkWindow *window);
50 void (* raise) (GdkWindow *window);
51 void (* lower) (GdkWindow *window);
52 void (* restack_under) (GdkWindow *window,
53 GList *native_siblings);
55 void (* move_resize) (GdkWindow *window,
61 void (* set_background) (GdkWindow *window,
62 const GdkColor *color);
63 void (* set_back_pixmap) (GdkWindow *window,
66 GdkEventMask (* get_events) (GdkWindow *window);
67 void (* set_events) (GdkWindow *window,
68 GdkEventMask event_mask);
70 gboolean (* reparent) (GdkWindow *window,
71 GdkWindow *new_parent,
74 void (* clear_region) (GdkWindow *window,
76 gboolean send_expose);
78 void (* set_cursor) (GdkWindow *window,
81 void (* get_geometry) (GdkWindow *window,
87 gint (* get_root_coords) (GdkWindow *window,
92 gint (* get_deskrelative_origin) (GdkWindow *window,
95 gboolean (* get_pointer) (GdkWindow *window,
98 GdkModifierType *mask);
100 void (* shape_combine_region) (GdkWindow *window,
101 const GdkRegion *shape_region,
104 void (* input_shape_combine_region) (GdkWindow *window,
105 const GdkRegion *shape_region,
109 gboolean (* set_static_gravities) (GdkWindow *window,
110 gboolean use_static);
112 /* Called before processing updates for a window. This gives the windowing
113 * layer a chance to save the region for later use in avoiding duplicate
114 * exposes. The return value indicates whether the function has a saved
115 * the region; if the result is TRUE, then the windowing layer is responsible
116 * for destroying the region later.
118 gboolean (* queue_antiexpose) (GdkWindow *window,
119 GdkRegion *update_area);
120 void (* queue_translation) (GdkWindow *window,
126 /* Called to do the windowing system specific part of gdk_window_destroy(),
128 * window: The window being destroyed
129 * recursing: If TRUE, then this is being called because a parent
130 * was destroyed. This generally means that the call to the windowing system
131 * to destroy the window can be omitted, since it will be destroyed as a result
132 * of the parent being destroyed. Unless @foreign_destroy
134 * foreign_destroy: If TRUE, the window or a parent was destroyed by some external
135 * agency. The window has already been destroyed and no windowing
136 * system calls should be made. (This may never happen for some
137 * windowing systems.)
139 void (* destroy) (GdkWindow *window,
141 gboolean foreign_destroy);
143 void (* input_window_destroy) (GdkWindow *window);
144 void (* input_window_crossing)(GdkWindow *window,
148 /* Interface Functions */
149 GType gdk_window_impl_get_type (void) G_GNUC_CONST;
151 /* private definitions from gdkwindow.h */
153 struct _GdkWindowRedirect
155 GdkWindowObject *redirected;
171 #endif /* __GDK_WINDOW_IMPL_H__ */