1/*
2 * gdkscreen.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_SCREEN_H__
23#define __GDK_SCREEN_H__
24
25#if !defined (__GDK_H_INSIDE__) && !defined (GDK_COMPILATION)
26#error "Only <gdk/gdk.h> can be included directly."
27#endif
28
29#include <cairo.h>
30#include <gdk/gdkversionmacros.h>
31#include <gdk/gdktypes.h>
32#include <gdk/gdkdisplay.h>
33
34G_BEGIN_DECLS
35
36#define GDK_TYPE_SCREEN (gdk_screen_get_type ())
37#define GDK_SCREEN(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), GDK_TYPE_SCREEN, GdkScreen))
38#define GDK_IS_SCREEN(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), GDK_TYPE_SCREEN))
39
40
41GDK_AVAILABLE_IN_ALL
42GType gdk_screen_get_type (void) G_GNUC_CONST;
43
44GDK_AVAILABLE_IN_ALL
45GdkVisual * gdk_screen_get_system_visual (GdkScreen *screen);
46GDK_AVAILABLE_IN_ALL
47GdkVisual * gdk_screen_get_rgba_visual (GdkScreen *screen);
48GDK_AVAILABLE_IN_ALL
49gboolean gdk_screen_is_composited (GdkScreen *screen);
50
51GDK_AVAILABLE_IN_ALL
52GdkWindow * gdk_screen_get_root_window (GdkScreen *screen);
53GDK_AVAILABLE_IN_ALL
54GdkDisplay * gdk_screen_get_display (GdkScreen *screen);
55GDK_DEPRECATED_IN_3_22
56gint gdk_screen_get_number (GdkScreen *screen);
57GDK_DEPRECATED_IN_3_22
58gint gdk_screen_get_width (GdkScreen *screen);
59GDK_DEPRECATED_IN_3_22
60gint gdk_screen_get_height (GdkScreen *screen);
61GDK_DEPRECATED_IN_3_22
62gint gdk_screen_get_width_mm (GdkScreen *screen);
63GDK_DEPRECATED_IN_3_22
64gint gdk_screen_get_height_mm (GdkScreen *screen);
65
66GDK_AVAILABLE_IN_ALL
67GList * gdk_screen_list_visuals (GdkScreen *screen);
68GDK_AVAILABLE_IN_ALL
69GList * gdk_screen_get_toplevel_windows (GdkScreen *screen);
70GDK_DEPRECATED_IN_3_22
71gchar * gdk_screen_make_display_name (GdkScreen *screen);
72
73GDK_DEPRECATED_IN_3_22_FOR(gdk_display_get_n_monitors)
74gint gdk_screen_get_n_monitors (GdkScreen *screen);
75GDK_DEPRECATED_IN_3_22_FOR(gdk_display_get_primary_monitor)
76gint gdk_screen_get_primary_monitor (GdkScreen *screen);
77GDK_DEPRECATED_IN_3_22_FOR(gdk_monitor_get_geometry)
78void gdk_screen_get_monitor_geometry (GdkScreen *screen,
79 gint monitor_num,
80 GdkRectangle *dest);
81GDK_DEPRECATED_IN_3_22_FOR(gdk_monitor_get_workarea)
82void gdk_screen_get_monitor_workarea (GdkScreen *screen,
83 gint monitor_num,
84 GdkRectangle *dest);
85
86GDK_DEPRECATED_IN_3_22_FOR(gdk_display_get_monitor_at_point)
87gint gdk_screen_get_monitor_at_point (GdkScreen *screen,
88 gint x,
89 gint y);
90GDK_DEPRECATED_IN_3_22_FOR(gdk_display_get_monitor_at_window)
91gint gdk_screen_get_monitor_at_window (GdkScreen *screen,
92 GdkWindow *window);
93GDK_DEPRECATED_IN_3_22_FOR(gdk_monitor_get_width_mm)
94gint gdk_screen_get_monitor_width_mm (GdkScreen *screen,
95 gint monitor_num);
96GDK_DEPRECATED_IN_3_22_FOR(gdk_monitor_get_height_mm)
97gint gdk_screen_get_monitor_height_mm (GdkScreen *screen,
98 gint monitor_num);
99GDK_DEPRECATED_IN_3_22_FOR(gdk_monitor_get_model)
100gchar * gdk_screen_get_monitor_plug_name (GdkScreen *screen,
101 gint monitor_num);
102GDK_DEPRECATED_IN_3_22_FOR(gdk_monitor_get_scale_factor)
103gint gdk_screen_get_monitor_scale_factor (GdkScreen *screen,
104 gint monitor_num);
105
106GDK_AVAILABLE_IN_ALL
107GdkScreen *gdk_screen_get_default (void);
108
109GDK_AVAILABLE_IN_ALL
110gboolean gdk_screen_get_setting (GdkScreen *screen,
111 const gchar *name,
112 GValue *value);
113
114GDK_AVAILABLE_IN_ALL
115void gdk_screen_set_font_options (GdkScreen *screen,
116 const cairo_font_options_t *options);
117GDK_AVAILABLE_IN_ALL
118const cairo_font_options_t *gdk_screen_get_font_options (GdkScreen *screen);
119
120GDK_AVAILABLE_IN_ALL
121void gdk_screen_set_resolution (GdkScreen *screen,
122 gdouble dpi);
123GDK_AVAILABLE_IN_ALL
124gdouble gdk_screen_get_resolution (GdkScreen *screen);
125
126GDK_DEPRECATED_IN_3_22
127GdkWindow *gdk_screen_get_active_window (GdkScreen *screen);
128GDK_AVAILABLE_IN_ALL
129GList *gdk_screen_get_window_stack (GdkScreen *screen);
130
131G_END_DECLS
132
133#endif /* __GDK_SCREEN_H__ */
134

source code of include/gtk-3.0/gdk/gdkscreen.h