Debian Codegraph @

engines/redmond/src/redmond_gtk2_engine.c

raw symbols SCIP
1 /* Redmond95 - a cairo based GTK+ engine
2 * Copyright (C) 2001 Red Hat, Inc.
3 * Copyright (C) 2006 Andrew Johnson <[email protected]>
4 *
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
9 *
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 *
19 * Project contact: <[email protected]>
20 *
21 *
22 * Written by Owen Taylor <[email protected]>
23 * modified by Andrew Johnson <[email protected]>
24 *
25 */
26
27
28 #include "redmond_gtk2_engine.h"cxx . . $ `<file>/engines/redmond/src/redmond_gtk2_engine.h`/
29 #include "redmond_gtk2_drawing.h"cxx . . $ `<file>/engines/redmond/src/redmond_gtk2_drawing.h`/
30 #include "redmond_gtk2_misc.h"cxx . . $ `<file>/engines/redmond/src/redmond_gtk2_misc.h`/
31
32 /**********************************/
33 /* Register & Initialize RC Style */
34 /**********************************/
35
36 G_DEFINE_DYNAMIC_TYPEcxx . . $ `<external>/10799355765420305551/gtypemodule.h:100:9`! (RedmondRcStyle, redmond_rc_style, GTK_TYPE_RC_STYLEcxx . . $ `<external>/4336590719910009705/gtkrc.h:45:9`!)
37
38 /* Create an empty style suitable to this RC style */
39 static GtkStylecxx . . $ GtkStyle# *
40 redmond_rc_style_create_stylecxx . . $ redmond_rc_style_create_style(bfadec5fb9641ad1). (GtkRcStylecxx . . $ GtkRcStyle# * rc_style)
41 {
42 return GTK_STYLEcxx . . $ `<external>/9172685273831718662/gtkstyle.h:42:9`! (g_object_new (REDMOND_TYPE_STYLEcxx . . $ `engines/redmond/src/redmond_gtk2_engine.h:64:9`!, NULLcxx . . $ `/usr/lib/gcc/x86_64-linux-gnu/15/include/stddef.h:419:9`!));;
43 }
44
45 static void
46 redmond_rc_style_initcxx . . $ redmond_rc_style_init(6d31f79ffba53da6). (RedmondRcStylecxx . . $ RedmondRcStyle# *rc_style)
47 {
48 }
49
50 static void
51 redmond_rc_style_class_initcxx . . $ redmond_rc_style_class_init(1d118fc4f0a0e70d). (RedmondRcStyleClasscxx . . $ RedmondRcStyleClass# * klass)
52 {
53 GtkRcStyleClasscxx . . $ GtkRcStyleClass# *rc_style_class = GTK_RC_STYLE_CLASScxx . . $ `<external>/4336590719910009705/gtkrc.h:47:9`! (klass);
54
55 rc_style_class->create_stylecxx . . $ _GtkRcStyleClass#create_style. = redmond_rc_style_create_stylecxx . . $ redmond_rc_style_create_style(bfadec5fb9641ad1).;
56 }
57
58 static void
59 redmond_rc_style_class_finalizecxx . . $ redmond_rc_style_class_finalize(1d118fc4f0a0e70d). (RedmondRcStyleClasscxx . . $ RedmondRcStyleClass# * klass)
60 {
61 }
62
63 /***************************************/
64 /* Register & Initialize Drawing Style */
65 /***************************************/
66
67 G_DEFINE_DYNAMIC_TYPEcxx . . $ `<external>/10799355765420305551/gtypemodule.h:100:9`! (RedmondStyle, redmond_style, GTK_TYPE_STYLEcxx . . $ `<external>/9172685273831718662/gtkstyle.h:41:9`!)
68
69 static void
70 redmond_simple_hatch_mask_patterncxx . . $ redmond_simple_hatch_mask_pattern(5cabfec48930dca8).(CairoPatterncxx . . $ CairoPattern# *pattern)
71 {
72 cairo_tcxx . . $ cairo_t# * cr;
73 cairo_surface_tcxx . . $ cairo_surface_t# *surface;
74
75 pattern->scalecxx . . $ $anonymous_type_869d4fa2f25cb9b0_5#scale. = GE_DIRECTION_NONEcxx . . $ GE_DIRECTION_NONE.;
76 pattern->translatecxx . . $ $anonymous_type_869d4fa2f25cb9b0_5#translate. = GE_DIRECTION_NONEcxx . . $ GE_DIRECTION_NONE.;
77
78 surface = cairo_image_surface_createcxx . . $ cairo_image_surface_create(f5323823c5d32b71).(CAIRO_FORMAT_A8cxx . . $ CAIRO_FORMAT_A8., 2, 2);
79
80 cr = cairo_createcxx . . $ cairo_create(b6f0039b687ec546).(surface);
81
82 cairo_set_source_rgbacxx . . $ cairo_set_source_rgba(1653902e9f448da4).(cr, 0, 0, 0, 0);
83 cairo_rectanglecxx . . $ cairo_rectangle(1653902e9f448da4). (cr, 0, 0, 2, 2);
84 cairo_fillcxx . . $ cairo_fill(21788b7825b29bf). (cr);
85
86 cairo_set_source_rgbacxx . . $ cairo_set_source_rgba(1653902e9f448da4).(cr, 1, 1, 1, 1);
87 cairo_rectanglecxx . . $ cairo_rectangle(1653902e9f448da4). (cr, 1, 0, 1, 1);
88 cairo_fillcxx . . $ cairo_fill(21788b7825b29bf). (cr);
89
90 cairo_rectanglecxx . . $ cairo_rectangle(1653902e9f448da4). (cr, 0, 1, 1, 1);
91 cairo_fillcxx . . $ cairo_fill(21788b7825b29bf). (cr);
92
93 cairo_destroycxx . . $ cairo_destroy(21788b7825b29bf).(cr);
94
95 pattern->handlecxx . . $ $anonymous_type_869d4fa2f25cb9b0_5#handle. = cairo_pattern_create_for_surfacecxx . . $ cairo_pattern_create_for_surface(50d60da38c69f49a). (surface);
96 cairo_surface_destroycxx . . $ cairo_surface_destroy(2fa2b40fabeeffa2).(surface);
97
98 cairo_pattern_set_extendcxx . . $ cairo_pattern_set_extend(7370c5455ab683a). (pattern->handlecxx . . $ $anonymous_type_869d4fa2f25cb9b0_5#handle., CAIRO_EXTEND_REPEATcxx . . $ CAIRO_EXTEND_REPEAT.);
99 }
100
101 static void
102 redmond_style_realizecxx . . $ redmond_style_realize(3ec9a091b8b7be68). (GtkStylecxx . . $ GtkStyle# * style)
103 {
104 RedmondStylecxx . . $ RedmondStyle# *redmond_style = REDMOND_STYLEcxx . . $ `engines/redmond/src/redmond_gtk2_engine.h:65:9`! (style);
105 int i;
106
107 GTK_STYLE_CLASScxx . . $ `<external>/9172685273831718662/gtkstyle.h:43:9`! (redmond_style_parent_class)->realizecxx . . $ _GtkStyleClass#realize. (style);
108
109 ge_gtk_style_to_cairo_color_cubecxx . . $ ge_gtk_style_to_cairo_color_cube(6168c5f1c4d21448). (style, &redmond_style->color_cubecxx . . $ $anonymous_type_3526fd27f7c83458_2#color_cube.);
110
111 redmond_simple_hatch_mask_patterncxx . . $ redmond_simple_hatch_mask_pattern(5cabfec48930dca8).(&redmond_style->hatch_maskcxx . . $ $anonymous_type_3526fd27f7c83458_2#hatch_mask.);
112
113 for (i = 0; i < 5; i++)
114 {
115 ge_shade_colorcxx . . $ ge_shade_color(ddf08f49ed67ac13).(&(redmond_style->color_cubecxx . . $ $anonymous_type_3526fd27f7c83458_2#color_cube..bgcxx . . $ $anonymous_type_869d4fa2f25cb9b0_1#bg.[i]), 0.3, &(redmond_style->black_bordercxx . . $ $anonymous_type_3526fd27f7c83458_2#black_border.[i]));
116
117 redmond_style->bg_colorcxx . . $ $anonymous_type_3526fd27f7c83458_2#bg_color.[i] = ge_cairo_color_patterncxx . . $ ge_cairo_color_pattern(c935febe058a2d2f).(&(redmond_style->color_cubecxx . . $ $anonymous_type_3526fd27f7c83458_2#color_cube..bgcxx . . $ $anonymous_type_869d4fa2f25cb9b0_1#bg.[i]));
118
119 redmond_style->bg_imagecxx . . $ $anonymous_type_3526fd27f7c83458_2#bg_image.[i] = NULLcxx . . $ `/usr/lib/gcc/x86_64-linux-gnu/15/include/stddef.h:419:9`!;
120
121 if ((style->bg_pixmapcxx . . $ _GtkStyle#bg_pixmap.[i]) && (style->bg_pixmapcxx . . $ _GtkStyle#bg_pixmap.[i] != (GdkPixmapcxx . . $ GdkPixmap#*) GDK_PARENT_RELATIVEcxx . . $ `<external>/737998189045937472/gdktypes.h:59:9`!))
122 {
123 redmond_style->bg_imagecxx . . $ $anonymous_type_3526fd27f7c83458_2#bg_image.[i] = ge_cairo_pixmap_patterncxx . . $ ge_cairo_pixmap_pattern(cb7010e22ad68fd2).(style->bg_pixmapcxx . . $ _GtkStyle#bg_pixmap.[i]);
124 }
125 }
126 }
127
128 static void
129 redmond_style_unrealizecxx . . $ redmond_style_unrealize(3ec9a091b8b7be68). (GtkStylecxx . . $ GtkStyle# * style)
130 {
131 RedmondStylecxx . . $ RedmondStyle# *redmond_style = REDMOND_STYLEcxx . . $ `engines/redmond/src/redmond_gtk2_engine.h:65:9`! (style);
132 int i;
133
134 cairo_pattern_destroycxx . . $ cairo_pattern_destroy(f75fcc8819286708).(redmond_style->hatch_maskcxx . . $ $anonymous_type_3526fd27f7c83458_2#hatch_mask..handlecxx . . $ $anonymous_type_869d4fa2f25cb9b0_5#handle.);
135
136 for (i = 0; i < 5; i++)
137 {
138 ge_cairo_pattern_destroycxx . . $ ge_cairo_pattern_destroy(5cabfec48930dca8).(redmond_style->bg_colorcxx . . $ $anonymous_type_3526fd27f7c83458_2#bg_color.[i]);
139 ge_cairo_pattern_destroycxx . . $ ge_cairo_pattern_destroy(5cabfec48930dca8).(redmond_style->bg_imagecxx . . $ $anonymous_type_3526fd27f7c83458_2#bg_image.[i]);
140 }
141
142 GTK_STYLE_CLASScxx . . $ `<external>/9172685273831718662/gtkstyle.h:43:9`! (redmond_style_parent_class)->unrealizecxx . . $ _GtkStyleClass#unrealize. (style);
143 }
144
145 static void
146 redmond_style_initcxx . . $ redmond_style_init(fde13fef92970f11). (RedmondStylecxx . . $ RedmondStyle# *style)
147 {
148 }
149
150 static void
151 redmond_style_class_initcxx . . $ redmond_style_class_init(5dd10102551d985a). (RedmondStyleClasscxx . . $ RedmondStyleClass# * klass)
152 {
153 GtkStyleClasscxx . . $ GtkStyleClass# *style_class = GTK_STYLE_CLASScxx . . $ `<external>/9172685273831718662/gtkstyle.h:43:9`! (klass);
154
155 style_class->realizecxx . . $ _GtkStyleClass#realize. = redmond_style_realizecxx . . $ redmond_style_realize(3ec9a091b8b7be68).;
156 style_class->unrealizecxx . . $ _GtkStyleClass#unrealize. = redmond_style_unrealizecxx . . $ redmond_style_unrealize(3ec9a091b8b7be68).;
157
158 style_class->draw_hlinecxx . . $ _GtkStyleClass#draw_hline. = redmond_draw_hlinecxx . . $ redmond_draw_hline(8560bb68e408b10a).;
159 style_class->draw_vlinecxx . . $ _GtkStyleClass#draw_vline. = redmond_draw_vlinecxx . . $ redmond_draw_vline(8560bb68e408b10a).;
160 style_class->draw_arrowcxx . . $ _GtkStyleClass#draw_arrow. = redmond_draw_arrowcxx . . $ redmond_draw_arrow(422be73dba64f040).;
161 style_class->draw_boxcxx . . $ _GtkStyleClass#draw_box. = redmond_draw_boxcxx . . $ redmond_draw_box(735e120c49b17d11).;
162 style_class->draw_checkcxx . . $ _GtkStyleClass#draw_check. = redmond_draw_checkcxx . . $ redmond_draw_check(735e120c49b17d11).;
163 style_class->draw_optioncxx . . $ _GtkStyleClass#draw_option. = redmond_draw_optioncxx . . $ redmond_draw_option(735e120c49b17d11).;
164 style_class->draw_tabcxx . . $ _GtkStyleClass#draw_tab. = redmond_draw_tabcxx . . $ redmond_draw_tab(735e120c49b17d11).;
165 style_class->draw_slidercxx . . $ _GtkStyleClass#draw_slider. = redmond_draw_slidercxx . . $ redmond_draw_slider(30bf754f222a37c2).;
166 style_class->draw_shadowcxx . . $ _GtkStyleClass#draw_shadow. = redmond_draw_shadowcxx . . $ redmond_draw_shadow(735e120c49b17d11).;
167 style_class->draw_extensioncxx . . $ _GtkStyleClass#draw_extension. = redmond_draw_extensioncxx . . $ redmond_draw_extension(ab7d29722d577c46).;
168 style_class->draw_handlecxx . . $ _GtkStyleClass#draw_handle. = redmond_draw_handlecxx . . $ redmond_draw_handle(30bf754f222a37c2).;
169 }
170
171 static void
172 redmond_style_class_finalizecxx . . $ redmond_style_class_finalize(5dd10102551d985a). (RedmondStyleClasscxx . . $ RedmondStyleClass# * klass)
173 {
174 }
175
176 /****************/
177 /* Engine Hooks */
178 /****************/
179 GE_EXPORTcxx . . $ `engines/support/general-support.h:60:10`! void
180 theme_initcxx . . $ theme_init(cfedfc7ad5df8b05). (GTypeModulecxx . . $ GTypeModule# * module)
181 {
182 redmond_rc_style_register_typecxx . . $ redmond_rc_style_register_type(cfedfc7ad5df8b05). (module);
183 redmond_style_register_typecxx . . $ redmond_style_register_type(cfedfc7ad5df8b05). (module);
184 }
185
186 GE_EXPORTcxx . . $ `engines/support/general-support.h:60:10`! void
187 theme_exitcxx . . $ theme_exit(49f6e7a06ebc5aa8). (void)
188 {
189 }
190
191 GE_EXPORTcxx . . $ `engines/support/general-support.h:60:10`! GtkRcStylecxx . . $ GtkRcStyle# *
192 theme_create_rc_stylecxx . . $ theme_create_rc_style(4ddf6d0bd176bf93). (void)
193 {
194 void *ptr;
195 ptr = GTK_RC_STYLEcxx . . $ `<external>/4336590719910009705/gtkrc.h:46:9`! (g_object_new (REDMOND_TYPE_RC_STYLEcxx . . $ `engines/redmond/src/redmond_gtk2_engine.h:41:9`!, NULLcxx . . $ `/usr/lib/gcc/x86_64-linux-gnu/15/include/stddef.h:419:9`!));
196 return (GtkRcStylecxx . . $ GtkRcStyle# *)ptr;
197 }