1 /* GTK - The GIMP Toolkit
2  * Copyright (C) 2011 Red Hat, Inc.
3  *
4  * Authors: Alexander Larsson <alexl@gnome.org>
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library. If not, see <http://www.gnu.org/licenses/>.
18  */
19 
20 #ifndef __GTK_WIN32_THEME_PART_H__
21 #define __GTK_WIN32_THEME_PART_H__
22 
23 #include "gtkcssparserprivate.h"
24 
25 G_BEGIN_DECLS
26 
27 typedef struct _GtkWin32Theme GtkWin32Theme;
28 
29 #define GTK_WIN32_THEME_SYMBOLIC_COLOR_NAME "-gtk-win32-color"
30 
31 GtkWin32Theme *         gtk_win32_theme_lookup          (const char     *class_name);
32 GtkWin32Theme *         gtk_win32_theme_parse           (GtkCssParser   *parser);
33 
34 GtkWin32Theme *         gtk_win32_theme_ref             (GtkWin32Theme  *theme);
35 void                    gtk_win32_theme_unref           (GtkWin32Theme  *theme);
36 
37 gboolean                gtk_win32_theme_equal           (GtkWin32Theme  *theme1,
38                                                          GtkWin32Theme  *theme2);
39 
40 void                    gtk_win32_theme_print           (GtkWin32Theme  *theme,
41                                                          GString        *string);
42 
43 cairo_surface_t *       gtk_win32_theme_create_surface  (GtkWin32Theme *theme,
44                                                          int            xp_part,
45                                                          int            state,
46                                                          int            margins[4],
47                                                          int            width,
48                                                          int            height,
49 							 int           *x_offs_out,
50 							 int           *y_offs_out);
51 
52 void                    gtk_win32_theme_get_part_border (GtkWin32Theme  *theme,
53                                                          int             part,
54                                                          int             state,
55                                                          GtkBorder      *out_border);
56 void                    gtk_win32_theme_get_part_size   (GtkWin32Theme  *theme,
57                                                          int             part,
58                                                          int             state,
59                                                          int            *width,
60                                                          int            *height);
61 int                     gtk_win32_theme_get_size        (GtkWin32Theme  *theme,
62 			                                 int             id);
63 void                    gtk_win32_theme_get_color       (GtkWin32Theme  *theme,
64                                                          gint            id,
65                                                          GdkRGBA        *color);
66 
67 G_END_DECLS
68 
69 #endif /* __GTK_WIN32_THEME_PART_H__ */
70