1 /* GDK - The GIMP Drawing Kit
2  * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
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 /*
21  * Modified by the GTK+ Team and others 1997-2000.  See the AUTHORS
22  * file for a list of people on the GTK+ Team.
23  */
24 
25 /*
26  * GTK+ DirectFB backend
27  * Copyright (C) 2001-2002  convergence integrated media GmbH
28  * Copyright (C) 2002       convergence GmbH
29  * Written by Denis Oliver Kropp <dok@convergence.de> and
30  *            Sven Neumann <sven@convergence.de>
31  */
32 
33 #ifndef __GDK_DIRECTFB_H__
34 #define __GDK_DIRECTFB_H__
35 
36 /* This define disables some experimental code
37  */
38 #define GDK_DIRECTFB_NO_EXPERIMENTS
39 
40 #include <cairo.h>
41 #include <directfb.h>
42 #include "gdk/gdkprivate.h"
43 
44 
45 extern GdkWindow * _gdk_parent_root;
46 
47 G_BEGIN_DECLS
48 
49 #define GDK_ROOT_WINDOW()      _gdk_parent_root
50 
51 #define GDK_WINDOW_DFB_ID(win) (GDK_WINDOW_IMPL_DIRECTFB (GDK_WINDOW_OBJECT (win)->impl)->dfb_id)
52 
53 
54 /* used for the --transparent-unfocused hack */
55 extern gboolean            gdk_directfb_apply_focus_opacity;
56 
57 /* used for the --enable-color-keying hack */
58 extern gboolean            gdk_directfb_enable_color_keying;
59 extern DFBColor            gdk_directfb_bg_color;
60 extern DFBColor            gdk_directfb_bg_color_key;
61 
62 /* to disable antialiasing */
63 extern gboolean            gdk_directfb_monochrome_fonts;
64 
65 
66 /* GTK+-DirectFB specific functions */
67 
68 void        gdk_directfb_window_set_opacity (GdkWindow *window,
69                                              guchar     opacity);
70 
71 #ifndef GDK_DISABLE_DEPRECATED
72 GdkWindow * gdk_directfb_window_new         (GdkWindow             *parent,
73                                              GdkWindowAttr         *attributes,
74                                              gint                   attributes_mask,
75                                              DFBWindowCapabilities  window_caps,
76                                              DFBWindowOptions       window_options,
77                                              DFBSurfaceCapabilities surface_caps);
78 #endif /* GDK_DISABLE_DEPRECATED */
79 
80 GdkVisual * gdk_directfb_visual_by_format   (DFBSurfacePixelFormat  pixel_format);
81 
82 IDirectFBWindow  *gdk_directfb_window_lookup (GdkWindow *window);
83 IDirectFBSurface *gdk_directfb_surface_lookup (GdkWindow *window);
84 
85 GdkWindow *gdk_directfb_create_child_window (GdkWindow        *parent,
86                                              IDirectFBSurface *subsurface);
87 
88 
89 G_END_DECLS
90 
91 #endif /* __GDK_DIRECTFB_H__ */
92