1 /* GDK - The GIMP Drawing Kit
2 * Copyright (C) 2002 Hans Breuer
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.
20 #include <gdkscreen.h>
21 #include "gdkprivate-win32.h" /* _gdk_parent_root */
22 #include "gdk.h" /* gdk_screen_width(), ... */
24 static GdkColormap *default_colormap = NULL;
27 gdk_screen_get_display (GdkScreen *screen)
29 return gdk_display_get_default ();
33 gdk_screen_get_screen_num (GdkScreen *screen)
39 gdk_screen_get_root_window (GdkScreen *screen)
41 return _gdk_parent_root;
45 gdk_screen_get_default_colormap (GdkScreen *screen)
47 return default_colormap;
51 gdk_screen_set_default_colormap (GdkScreen *screen,
52 GdkColormap *colormap)
54 default_colormap = colormap;
58 gdk_screen_get_n_monitors (GdkScreen *screen)
60 g_return_val_if_fail (GDK_IS_SCREEN (screen), 1);
66 gdk_screen_get_monitor_geometry (GdkScreen *screen,
72 dest->width = gdk_screen_width ();
73 dest->height = gdk_screen_height ();
77 gdk_screen_get_number (GdkScreen *screen)
79 g_return_val_if_fail (GDK_IS_SCREEN (screen), 0);
85 _gdk_windowing_substitute_screen_number (gchar *display_name,
88 return g_strdup (display_name);
92 gdk_screen_make_display_name (GdkScreen *screen)