1/*
2 * gdkdisplay.h
3 *
4 * Copyright 2001 Sun Microsystems Inc.
5 *
6 * Erwann Chenede <erwann.chenede@sun.com>
7 *
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either
11 * version 2 of the License, or (at your option) any later version.
12 *
13 * This library is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Library General Public License for more details.
17 *
18 * You should have received a copy of the GNU Library General Public
19 * License along with this library. If not, see <http://www.gnu.org/licenses/>.
20 */
21
22#ifndef __GDK_DISPLAY_H__
23#define __GDK_DISPLAY_H__
24
25#if !defined (__GDK_H_INSIDE__) && !defined (GTK_COMPILATION)
26#error "Only <gdk/gdk.h> can be included directly."
27#endif
28
29#include <gdk/gdkversionmacros.h>
30#include <gdk/gdktypes.h>
31#include <gdk/gdkevents.h>
32#include <gdk/gdkseat.h>
33#include <gdk/gdkmonitor.h>
34
35G_BEGIN_DECLS
36
37#define GDK_TYPE_DISPLAY (gdk_display_get_type ())
38#define GDK_DISPLAY(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), GDK_TYPE_DISPLAY, GdkDisplay))
39#define GDK_IS_DISPLAY(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), GDK_TYPE_DISPLAY))
40
41GDK_AVAILABLE_IN_ALL
42GType gdk_display_get_type (void) G_GNUC_CONST;
43GDK_AVAILABLE_IN_ALL
44GdkDisplay *gdk_display_open (const char *display_name);
45
46GDK_AVAILABLE_IN_ALL
47const char * gdk_display_get_name (GdkDisplay *display);
48
49GDK_AVAILABLE_IN_ALL
50gboolean gdk_display_device_is_grabbed (GdkDisplay *display,
51 GdkDevice *device);
52GDK_AVAILABLE_IN_ALL
53void gdk_display_beep (GdkDisplay *display);
54GDK_AVAILABLE_IN_ALL
55void gdk_display_sync (GdkDisplay *display);
56GDK_AVAILABLE_IN_ALL
57void gdk_display_flush (GdkDisplay *display);
58
59GDK_AVAILABLE_IN_ALL
60void gdk_display_close (GdkDisplay *display);
61GDK_AVAILABLE_IN_ALL
62gboolean gdk_display_is_closed (GdkDisplay *display);
63
64GDK_AVAILABLE_IN_ALL
65gboolean gdk_display_is_composited (GdkDisplay *display);
66GDK_AVAILABLE_IN_ALL
67gboolean gdk_display_is_rgba (GdkDisplay *display);
68GDK_AVAILABLE_IN_ALL
69gboolean gdk_display_supports_input_shapes (GdkDisplay *display);
70
71GDK_AVAILABLE_IN_4_4
72gboolean gdk_display_prepare_gl (GdkDisplay *self,
73 GError **error);
74GDK_AVAILABLE_IN_4_6
75GdkGLContext *gdk_display_create_gl_context(GdkDisplay *self,
76 GError **error);
77
78GDK_AVAILABLE_IN_ALL
79GdkDisplay *gdk_display_get_default (void);
80
81GDK_AVAILABLE_IN_ALL
82GdkClipboard * gdk_display_get_clipboard (GdkDisplay *display);
83GDK_AVAILABLE_IN_ALL
84GdkClipboard * gdk_display_get_primary_clipboard (GdkDisplay *display);
85
86GDK_AVAILABLE_IN_ALL
87void gdk_display_notify_startup_complete (GdkDisplay *display,
88 const char *startup_id);
89GDK_AVAILABLE_IN_ALL
90const char * gdk_display_get_startup_notification_id (GdkDisplay *display);
91
92GDK_AVAILABLE_IN_ALL
93GdkAppLaunchContext *gdk_display_get_app_launch_context (GdkDisplay *display);
94
95GDK_AVAILABLE_IN_ALL
96GdkSeat * gdk_display_get_default_seat (GdkDisplay *display);
97
98GDK_AVAILABLE_IN_ALL
99GList * gdk_display_list_seats (GdkDisplay *display);
100
101GDK_AVAILABLE_IN_ALL
102GListModel * gdk_display_get_monitors (GdkDisplay *self) G_GNUC_PURE;
103GDK_AVAILABLE_IN_ALL
104GdkMonitor * gdk_display_get_monitor_at_surface (GdkDisplay *display,
105 GdkSurface *surface);
106
107GDK_AVAILABLE_IN_ALL
108void gdk_display_put_event (GdkDisplay *display,
109 GdkEvent *event);
110
111GDK_AVAILABLE_IN_ALL
112gboolean gdk_display_map_keyval (GdkDisplay *display,
113 guint keyval,
114 GdkKeymapKey **keys,
115 int *n_keys);
116
117GDK_AVAILABLE_IN_ALL
118gboolean gdk_display_map_keycode (GdkDisplay *display,
119 guint keycode,
120 GdkKeymapKey **keys,
121 guint **keyvals,
122 int *n_entries);
123
124GDK_AVAILABLE_IN_ALL
125gboolean gdk_display_translate_key (GdkDisplay *display,
126 guint keycode,
127 GdkModifierType state,
128 int group,
129 guint *keyval,
130 int *effective_group,
131 int *level,
132 GdkModifierType *consumed);
133
134GDK_AVAILABLE_IN_ALL
135gboolean gdk_display_get_setting (GdkDisplay *display,
136 const char *name,
137 GValue *value);
138
139
140
141G_END_DECLS
142
143#endif /* __GDK_DISPLAY_H__ */
144

source code of gtk/gdk/gdkdisplay.h