3 #include "properties.h"
7 #define DEFAULT_HOR_SPACING 5
9 void change_paragraph(GtkWidget
*widget
);
10 void create_general(GtkWidget
*parent
);
11 void create_panel(GtkWidget
*parent
);
12 void create_taskbar(GtkWidget
*parent
);
13 void create_task(GtkWidget
*parent
);
14 void create_clock(GtkWidget
*parent
);
15 void create_systemtray(GtkWidget
*parent
);
16 void create_battery(GtkWidget
*parent
);
17 void create_tooltip(GtkWidget
*parent
);
18 void create_background(GtkWidget
*parent
);
21 GtkWidget
*create_properties()
23 GtkWidget
*view
, *dialog_vbox3
, *button
, *notebook
;
24 GtkTooltips
*tooltips
;
25 GtkWidget
*page_panel
, *page_taskbar
, *page_battery
, *page_clock
, *page_tooltip
, *page_systemtray
, *page_task
, *page_background
;
28 tooltips
= gtk_tooltips_new ();
31 view
= gtk_dialog_new ();
32 gtk_window_set_title (GTK_WINDOW (view
), _("Properties"));
33 gtk_window_set_modal (GTK_WINDOW (view
), TRUE
);
34 gtk_window_set_skip_pager_hint (GTK_WINDOW (view
), TRUE
);
35 gtk_window_set_type_hint (GTK_WINDOW (view
), GDK_WINDOW_TYPE_HINT_DIALOG
);
37 dialog_vbox3
= GTK_DIALOG (view
)->vbox
;
38 gtk_widget_show (dialog_vbox3
);
40 notebook
= gtk_notebook_new ();
41 gtk_widget_show (notebook
);
42 gtk_container_set_border_width(GTK_CONTAINER(notebook
), 5);
43 gtk_box_pack_start (GTK_BOX (dialog_vbox3
), notebook
, TRUE
, TRUE
, 6);
44 gtk_notebook_set_tab_pos (GTK_NOTEBOOK (notebook
), GTK_POS_LEFT
);
46 button
= gtk_button_new_from_stock ("gtk-apply");
47 gtk_widget_show (button
);
48 gtk_dialog_add_action_widget (GTK_DIALOG (view
), button
, GTK_RESPONSE_APPLY
);
49 GTK_WIDGET_SET_FLAGS (button
, GTK_CAN_DEFAULT
);
51 button
= gtk_button_new_from_stock ("gtk-cancel");
52 gtk_widget_show (button
);
53 gtk_dialog_add_action_widget (GTK_DIALOG (view
), button
, GTK_RESPONSE_CANCEL
);
54 GTK_WIDGET_SET_FLAGS (button
, GTK_CAN_DEFAULT
);
56 button
= gtk_button_new_from_stock ("gtk-ok");
57 gtk_widget_show (button
);
58 gtk_dialog_add_action_widget (GTK_DIALOG (view
), button
, GTK_RESPONSE_OK
);
59 GTK_WIDGET_SET_FLAGS (button
, GTK_CAN_DEFAULT
);
63 label = gtk_label_new (_("General"));
64 gtk_widget_show (label);
65 page_general = gtk_vbox_new (FALSE, DEFAULT_HOR_SPACING);
66 gtk_container_set_border_width(GTK_CONTAINER(page_general), 10);
67 gtk_widget_show (page_general);
68 gtk_notebook_append_page (GTK_NOTEBOOK (notebook), page_general, label);
69 create_general(page_general);
71 label
= gtk_label_new (_("Panel"));
72 gtk_widget_show (label
);
73 page_panel
= gtk_vbox_new (FALSE
, DEFAULT_HOR_SPACING
);
74 gtk_container_set_border_width(GTK_CONTAINER(page_panel
), 10);
75 gtk_widget_show (page_panel
);
76 gtk_notebook_append_page (GTK_NOTEBOOK (notebook
), page_panel
, label
);
77 create_panel(page_panel
);
79 label
= gtk_label_new (_("Taskbar"));
80 gtk_widget_show (label
);
81 page_taskbar
= gtk_vbox_new (FALSE
, DEFAULT_HOR_SPACING
);
82 gtk_container_set_border_width(GTK_CONTAINER(page_taskbar
), 10);
83 gtk_widget_show (page_taskbar
);
84 gtk_notebook_append_page (GTK_NOTEBOOK (notebook
), page_taskbar
, label
);
85 create_taskbar(page_taskbar
);
87 label
= gtk_label_new (_("Task"));
88 gtk_widget_show (label
);
89 page_task
= gtk_vbox_new (FALSE
, DEFAULT_HOR_SPACING
);
90 gtk_container_set_border_width(GTK_CONTAINER(page_task
), 10);
91 gtk_widget_show (page_task
);
92 gtk_notebook_append_page (GTK_NOTEBOOK (notebook
), page_task
, label
);
93 create_task(page_task
);
95 label
= gtk_label_new (_("Clock"));
96 gtk_widget_show (label
);
97 page_clock
= gtk_vbox_new (FALSE
, DEFAULT_HOR_SPACING
);
98 gtk_container_set_border_width(GTK_CONTAINER(page_clock
), 10);
99 gtk_widget_show (page_clock
);
100 gtk_notebook_append_page (GTK_NOTEBOOK (notebook
), page_clock
, label
);
101 create_clock(page_clock
);
103 label
= gtk_label_new (_("Notification"));
104 gtk_widget_show (label
);
105 page_systemtray
= gtk_vbox_new (FALSE
, DEFAULT_HOR_SPACING
);
106 gtk_container_set_border_width(GTK_CONTAINER(page_systemtray
), 10);
107 gtk_widget_show (page_systemtray
);
108 gtk_notebook_append_page (GTK_NOTEBOOK (notebook
), page_systemtray
, label
);
109 create_systemtray(page_systemtray
);
111 label
= gtk_label_new (_("Battery"));
112 gtk_widget_show (label
);
113 page_battery
= gtk_vbox_new (FALSE
, DEFAULT_HOR_SPACING
);
114 gtk_container_set_border_width(GTK_CONTAINER(page_battery
), 10);
115 gtk_widget_show (page_battery
);
116 gtk_notebook_append_page (GTK_NOTEBOOK (notebook
), page_battery
, label
);
117 create_battery(page_battery
);
119 label
= gtk_label_new (_("Tooltip"));
120 gtk_widget_show (label
);
121 page_tooltip
= gtk_vbox_new (FALSE
, DEFAULT_HOR_SPACING
);
122 gtk_container_set_border_width(GTK_CONTAINER(page_tooltip
), 10);
123 gtk_widget_show (page_tooltip
);
124 gtk_notebook_append_page (GTK_NOTEBOOK (notebook
), page_tooltip
, label
);
125 create_tooltip(page_tooltip
);
127 label
= gtk_label_new (_("Background"));
128 gtk_widget_show (label
);
129 page_background
= gtk_vbox_new (FALSE
, DEFAULT_HOR_SPACING
);
130 gtk_container_set_border_width(GTK_CONTAINER(page_background
), 10);
131 gtk_widget_show (page_background
);
132 gtk_notebook_append_page (GTK_NOTEBOOK (notebook
), page_background
, label
);
133 create_background(page_background
);
135 printf("create_properties : fin\n");
140 void change_paragraph(GtkWidget
*widget
)
143 hbox
= gtk_hbox_new (FALSE
, 0);
144 gtk_widget_show (hbox
);
145 gtk_box_pack_start(GTK_BOX (widget
), hbox
, FALSE
, FALSE
, 0);
146 gtk_container_set_border_width (GTK_CONTAINER (hbox
), 6);
150 void create_general(GtkWidget
*parent
)
155 void create_panel(GtkWidget
*parent
)
158 GtkWidget
*screen_position
[12];
159 GtkWidget
*table
, *hbox
, *frame
;
160 GtkWidget
*margin_x
, *margin_y
, *combo_strut_policy
, *combo_layer
, *combo_width_type
, *combo_height_type
, *combo_monitor
, *combo_background
;
163 label
= gtk_label_new (_("<b>Position and size</b>"));
164 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
165 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
166 gtk_widget_show (label
);
167 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
168 hbox
= gtk_hbox_new (FALSE
, 20);
169 gtk_widget_show (hbox
);
170 gtk_box_pack_start (GTK_BOX (parent
), hbox
, FALSE
, FALSE
, 0);
172 table
= gtk_table_new (2, 10, FALSE
);
173 gtk_widget_show (table
);
174 gtk_box_pack_start (GTK_BOX (hbox
), table
, FALSE
, FALSE
, 0);
175 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
176 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
178 label
= gtk_label_new (_("Width"));
179 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
180 gtk_widget_show (label
);
181 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
183 margin_x
= gtk_spin_button_new_with_range (0, 9000, 1);
184 gtk_widget_show (margin_x
);
185 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
187 combo_width_type
= gtk_combo_box_new_text ();
188 gtk_widget_show (combo_width_type
);
189 gtk_table_attach (GTK_TABLE (table
), combo_width_type
, 4, 5, 0, 1, GTK_FILL
, 0, 0, 0);
190 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_width_type
), _("Percent"));
191 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_width_type
), _("Pixels"));
193 label
= gtk_label_new (_("Marging x"));
194 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
195 gtk_widget_show (label
);
196 gtk_table_attach (GTK_TABLE (table
), label
, 7, 8, 0, 1, GTK_FILL
, 0, 0, 0);
198 margin_x
= gtk_spin_button_new_with_range (0, 500, 1);
199 gtk_widget_show (margin_x
);
200 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
201 gtk_table_attach (GTK_TABLE (table
), margin_x
, 8, 9, 0, 1, GTK_FILL
, 0, 0, 0);
203 label
= gtk_label_new (_("Height"));
204 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
205 gtk_widget_show (label
);
206 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
208 margin_y
= gtk_spin_button_new_with_range (0, 9000, 1);
209 gtk_widget_show (margin_y
);
210 gtk_table_attach (GTK_TABLE (table
), margin_y
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
212 combo_height_type
= gtk_combo_box_new_text ();
213 gtk_widget_show (combo_height_type
);
214 gtk_table_attach (GTK_TABLE (table
), combo_height_type
, 4, 5, 1, 2, GTK_FILL
, 0, 0, 0);
215 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_height_type
), _("Percent"));
216 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_height_type
), _("Pixels"));
218 label
= gtk_label_new (_("Marging y"));
219 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
220 gtk_widget_show (label
);
221 gtk_table_attach (GTK_TABLE (table
), label
, 7, 8, 1, 2, GTK_FILL
, 0, 0, 0);
223 margin_y
= gtk_spin_button_new_with_range (0, 500, 1);
224 gtk_widget_show (margin_y
);
225 gtk_entry_set_max_length (GTK_ENTRY (margin_y
), 3);
226 gtk_table_attach (GTK_TABLE (table
), margin_y
, 8, 9, 1, 2, GTK_FILL
, 0, 0, 0);
228 table
= gtk_table_new (5, 5, FALSE
);
229 gtk_widget_show (table
);
230 gtk_box_pack_start (GTK_BOX (hbox
), table
, FALSE
, FALSE
, 0);
232 for (i
= 0; i
< 12; ++i
) {
233 screen_position
[i
] = gtk_toggle_button_new ();
234 gtk_widget_show (screen_position
[i
]);
236 if (i
<= 2 || i
>= 9)
237 gtk_widget_set_size_request (screen_position
[i
], 30, 15);
239 gtk_widget_set_size_request (screen_position
[i
], 15, 25);
241 // g_signal_connect (G_OBJECT (screen_position[i]), "button-press-event", G_CALLBACK (screen_position_pressed));
242 // g_signal_connect (G_OBJECT (screen_position[i]), "key-press-event", G_CALLBACK (screen_position_pressed));
244 gtk_table_attach_defaults (GTK_TABLE (table
), screen_position
[0], 1, 2, 0, 1);
245 gtk_table_attach_defaults (GTK_TABLE (table
), screen_position
[1], 2, 3, 0, 1);
246 gtk_table_attach_defaults (GTK_TABLE (table
), screen_position
[2], 3, 4, 0, 1);
247 gtk_table_attach_defaults (GTK_TABLE (table
), screen_position
[3], 0, 1, 1, 2);
248 gtk_table_attach_defaults (GTK_TABLE (table
), screen_position
[4], 0, 1, 2, 3);
249 gtk_table_attach_defaults (GTK_TABLE (table
), screen_position
[5], 0, 1, 3, 4);
250 gtk_table_attach_defaults (GTK_TABLE (table
), screen_position
[6], 4, 5, 1, 2);
251 gtk_table_attach_defaults (GTK_TABLE (table
), screen_position
[7], 4, 5, 2, 3);
252 gtk_table_attach_defaults (GTK_TABLE (table
), screen_position
[8], 4, 5, 3, 4);
253 gtk_table_attach_defaults (GTK_TABLE (table
), screen_position
[9], 1, 2, 4, 5);
254 gtk_table_attach_defaults (GTK_TABLE (table
), screen_position
[10], 2, 3, 4, 5);
255 gtk_table_attach_defaults (GTK_TABLE (table
), screen_position
[11], 3, 4, 4, 5);
257 frame
= gtk_frame_new (NULL
);
258 gtk_widget_show (frame
);
259 gtk_box_pack_start (GTK_BOX (hbox
), frame
, FALSE
, TRUE
, 0);
260 gtk_frame_set_shadow_type (GTK_FRAME (frame
), GTK_SHADOW_NONE
);
262 label
= gtk_label_new (_("<b>Autohide</b>"));
263 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
264 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
265 gtk_widget_show (label
);
266 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
268 table
= gtk_table_new (2, 10, FALSE
);
269 gtk_widget_show (table
);
270 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
271 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
272 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
274 label
= gtk_label_new (_("Autohide"));
275 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
276 gtk_widget_show (label
);
277 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
279 margin_x
= gtk_check_button_new ();
280 gtk_widget_show (margin_x
);
281 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
283 label
= gtk_label_new (_("Show panel after"));
284 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
285 gtk_widget_show (label
);
286 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 0, 1, GTK_FILL
, 0, 0, 0);
288 margin_x
= gtk_spin_button_new_with_range (0, 10000, 0.1);
289 gtk_widget_show (margin_x
);
290 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 0, 1, GTK_FILL
, 0, 0, 0);
292 label
= gtk_label_new (_("seconds"));
293 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
294 gtk_widget_show (label
);
295 gtk_table_attach (GTK_TABLE (table
), label
, 8, 9, 0, 1, GTK_FILL
, 0, 0, 0);
297 label
= gtk_label_new (_("Hidden size"));
298 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
299 gtk_widget_show (label
);
300 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
302 margin_x
= gtk_spin_button_new_with_range (0, 500, 1);
303 gtk_widget_show (margin_x
);
304 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
305 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
307 label
= gtk_label_new (_("Hide panel after"));
308 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
309 gtk_widget_show (label
);
310 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 1, 2, GTK_FILL
, 0, 0, 0);
312 margin_y
= gtk_spin_button_new_with_range (0, 10000, 0.1);
313 gtk_widget_show (margin_y
);
314 gtk_table_attach (GTK_TABLE (table
), margin_y
, 7, 8, 1, 2, GTK_FILL
, 0, 0, 0);
316 label
= gtk_label_new (_("seconds"));
317 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
318 gtk_widget_show (label
);
319 gtk_table_attach (GTK_TABLE (table
), label
, 8, 9, 1, 2, GTK_FILL
, 0, 0, 0);
321 change_paragraph(parent
);
323 label
= gtk_label_new (_("<b>Appearance</b>"));
324 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
325 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
326 gtk_widget_show (label
);
327 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
329 table
= gtk_table_new (2, 10, FALSE
);
330 gtk_widget_show (table
);
331 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
332 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
333 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
335 label
= gtk_label_new (_("Padding horizontal"));
336 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
337 gtk_widget_show (label
);
338 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
340 margin_x
= gtk_spin_button_new_with_range (0, 500, 1);
341 gtk_widget_show (margin_x
);
342 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
343 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
345 label
= gtk_label_new (_("Background"));
346 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
347 gtk_widget_show (label
);
348 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 0, 1, GTK_FILL
, 0, 0, 0);
350 combo_background
= gtk_combo_box_new_text ();
351 gtk_widget_show (combo_background
);
352 gtk_table_attach (GTK_TABLE (table
), combo_background
, 7, 8, 0, 1, GTK_FILL
, 0, 0, 0);
353 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 1"));
354 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 2"));
355 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 3"));
357 label
= gtk_label_new (_("Padding vertical"));
358 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
359 gtk_widget_show (label
);
360 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
362 margin_y
= gtk_spin_button_new_with_range (0, 500, 1);
363 gtk_widget_show (margin_y
);
364 gtk_entry_set_max_length (GTK_ENTRY (margin_y
), 3);
365 gtk_table_attach (GTK_TABLE (table
), margin_y
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
367 label
= gtk_label_new (_("Spacing"));
368 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
369 gtk_widget_show (label
);
370 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 1, 2, GTK_FILL
, 0, 0, 0);
372 margin_x
= gtk_spin_button_new_with_range (0, 500, 1);
373 gtk_widget_show (margin_x
);
374 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
375 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 1, 2, GTK_FILL
, 0, 0, 0);
377 change_paragraph(parent
);
379 label
= gtk_label_new (_("<b>Window manager</b>"));
380 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
381 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
382 gtk_widget_show (label
);
383 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
385 table
= gtk_table_new (2, 12, FALSE
);
386 gtk_widget_show (table
);
387 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
388 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
389 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
391 label
= gtk_label_new (_("WM menu"));
392 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
393 gtk_widget_show (label
);
394 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
396 margin_x
= gtk_check_button_new ();
397 gtk_widget_show (margin_x
);
398 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
399 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
401 label
= gtk_label_new (_("Place in dock"));
402 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
403 gtk_widget_show (label
);
404 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
406 margin_x
= gtk_check_button_new ();
407 gtk_widget_show (margin_x
);
408 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
409 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
411 label
= gtk_label_new (_("Layer"));
412 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
413 gtk_widget_show (label
);
414 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 0, 1, GTK_FILL
, 0, 0, 0);
416 combo_layer
= gtk_combo_box_new_text ();
417 gtk_widget_show (combo_layer
);
418 gtk_entry_set_max_length (GTK_ENTRY (combo_layer
), 3);
419 gtk_table_attach (GTK_TABLE (table
), combo_layer
, 7, 8, 0, 1, GTK_FILL
, 0, 0, 0);
420 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_layer
), _("Top"));
421 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_layer
), _("Normal"));
422 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_layer
), _("Bottom"));
424 label
= gtk_label_new (_("Strut policy"));
425 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
426 gtk_widget_show (label
);
427 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 1, 2, GTK_FILL
, 0, 0, 0);
429 combo_strut_policy
= gtk_combo_box_new_text ();
430 gtk_widget_show (combo_strut_policy
);
431 gtk_entry_set_max_length (GTK_ENTRY (combo_strut_policy
), 3);
432 gtk_table_attach (GTK_TABLE (table
), combo_strut_policy
, 7, 8, 1, 2, GTK_FILL
, 0, 0, 0);
433 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_strut_policy
), _("Follow size"));
434 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_strut_policy
), _("Minimum"));
435 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_strut_policy
), _("None"));
437 label
= gtk_label_new (_("Monitor"));
438 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
439 gtk_widget_show (label
);
440 gtk_table_attach (GTK_TABLE (table
), label
, 10, 11, 0, 1, GTK_FILL
, 0, 0, 0);
442 combo_monitor
= gtk_combo_box_new_text ();
443 gtk_widget_show (combo_monitor
);
444 gtk_table_attach (GTK_TABLE (table
), combo_monitor
, 11, 12, 0, 1, GTK_FILL
, 0, 0, 0);
445 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_monitor
), _("All"));
447 change_paragraph(parent
);
451 void create_taskbar(GtkWidget
*parent
)
453 GtkWidget
*table
, *label
;
454 GtkWidget
*margin_x
, *margin_y
, *combo_background
;
456 table
= gtk_table_new (1, 2, FALSE
);
457 gtk_widget_show (table
);
458 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
459 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
460 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
462 label
= gtk_label_new (_("Show all desktop"));
463 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
464 gtk_widget_show (label
);
465 gtk_table_attach (GTK_TABLE (table
), label
, 0, 1, 0, 1, GTK_FILL
, 0, 0, 0);
467 margin_x
= gtk_check_button_new ();
468 gtk_widget_show (margin_x
);
469 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
470 gtk_table_attach (GTK_TABLE (table
), margin_x
, 1, 2, 0, 1, GTK_FILL
, 0, 0, 0);
472 change_paragraph(parent
);
474 label
= gtk_label_new (_("<b>Appearance</b>"));
475 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
476 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
477 gtk_widget_show (label
);
478 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
480 table
= gtk_table_new (2, 12, FALSE
);
481 gtk_widget_show (table
);
482 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
483 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
484 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
486 label
= gtk_label_new (_("Padding horizontal"));
487 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
488 gtk_widget_show (label
);
489 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
491 margin_x
= gtk_spin_button_new_with_range (0, 500, 1);
492 gtk_widget_show (margin_x
);
493 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
494 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
496 label
= gtk_label_new (_("Padding vertical"));
497 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
498 gtk_widget_show (label
);
499 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
501 margin_y
= gtk_spin_button_new_with_range (0, 500, 1);
502 gtk_widget_show (margin_y
);
503 gtk_entry_set_max_length (GTK_ENTRY (margin_y
), 3);
504 gtk_table_attach (GTK_TABLE (table
), margin_y
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
506 label
= gtk_label_new (_("Spacing"));
507 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
508 gtk_widget_show (label
);
509 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 2, 3, GTK_FILL
, 0, 0, 0);
511 margin_x
= gtk_spin_button_new_with_range (0, 500, 1);
512 gtk_widget_show (margin_x
);
513 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
514 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 2, 3, GTK_FILL
, 0, 0, 0);
516 label
= gtk_label_new (_("Background active"));
517 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
518 gtk_widget_show (label
);
519 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 0, 1, GTK_FILL
, 0, 0, 0);
521 combo_background
= gtk_combo_box_new_text ();
522 gtk_widget_show (combo_background
);
523 gtk_table_attach (GTK_TABLE (table
), combo_background
, 7, 8, 0, 1, GTK_FILL
, 0, 0, 0);
524 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 1"));
525 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 2"));
526 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 3"));
528 label
= gtk_label_new (_("Background inactive"));
529 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
530 gtk_widget_show (label
);
531 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 1, 2, GTK_FILL
, 0, 0, 0);
533 combo_background
= gtk_combo_box_new_text ();
534 gtk_widget_show (combo_background
);
535 gtk_table_attach (GTK_TABLE (table
), combo_background
, 7, 8, 1, 2, GTK_FILL
, 0, 0, 0);
536 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 1"));
537 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 2"));
538 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 3"));
540 change_paragraph(parent
);
544 void create_task(GtkWidget
*parent
)
546 GtkWidget
*table
, *label
, *notebook
, *page_task
;
547 GtkWidget
*margin_x
, *combo_background
;
549 label
= gtk_label_new (_("<b>Mouse action</b>"));
550 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
551 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
552 gtk_widget_show (label
);
553 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
555 table
= gtk_table_new (2, 10, FALSE
);
556 gtk_widget_show (table
);
557 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
558 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
559 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
561 label
= gtk_label_new (_("Middle click"));
562 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
563 gtk_widget_show (label
);
564 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
566 combo_background
= gtk_combo_box_new_text ();
567 gtk_widget_show (combo_background
);
568 gtk_table_attach (GTK_TABLE (table
), combo_background
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
569 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("None"));
570 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Close"));
571 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Toggle"));
572 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Iconify"));
573 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Shade"));
574 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Toggle iconify"));
575 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Maximize restore"));
576 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Desktop left"));
577 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Next task"));
578 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Previous task"));
580 label
= gtk_label_new (_("Wheel scroll up"));
581 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
582 gtk_widget_show (label
);
583 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 0, 1, GTK_FILL
, 0, 0, 0);
585 combo_background
= gtk_combo_box_new_text ();
586 gtk_widget_show (combo_background
);
587 gtk_table_attach (GTK_TABLE (table
), combo_background
, 7, 8, 0, 1, GTK_FILL
, 0, 0, 0);
588 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("None"));
589 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Close"));
590 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Toggle"));
591 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Iconify"));
592 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Shade"));
593 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Toggle iconify"));
594 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Maximize restore"));
595 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Desktop left"));
596 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Next task"));
597 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Previous task"));
599 label
= gtk_label_new (_("Right click"));
600 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
601 gtk_widget_show (label
);
602 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
604 combo_background
= gtk_combo_box_new_text ();
605 gtk_widget_show (combo_background
);
606 gtk_table_attach (GTK_TABLE (table
), combo_background
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
607 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("None"));
608 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Close"));
609 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Toggle"));
610 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Iconify"));
611 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Shade"));
612 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Toggle iconify"));
613 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Maximize restore"));
614 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Desktop left"));
615 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Next task"));
616 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Previous task"));
618 label
= gtk_label_new (_("Wheel scroll down"));
619 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
620 gtk_widget_show (label
);
621 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 1, 2, GTK_FILL
, 0, 0, 0);
623 combo_background
= gtk_combo_box_new_text ();
624 gtk_widget_show (combo_background
);
625 gtk_table_attach (GTK_TABLE (table
), combo_background
, 7, 8, 1, 2, GTK_FILL
, 0, 0, 0);
626 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("None"));
627 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Close"));
628 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Toggle"));
629 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Iconify"));
630 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Shade"));
631 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Toggle iconify"));
632 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Maximize restore"));
633 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Desktop left"));
634 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Next task"));
635 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Previous task"));
637 change_paragraph(parent
);
639 label
= gtk_label_new (_("<b>Appearance</b>"));
640 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
641 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
642 gtk_widget_show (label
);
643 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
645 table
= gtk_table_new (4, 10, FALSE
);
646 gtk_widget_show (table
);
647 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
648 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
649 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
651 label
= gtk_label_new (_("Show icon"));
652 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
653 gtk_widget_show (label
);
654 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
656 margin_x
= gtk_check_button_new ();
657 gtk_widget_show (margin_x
);
658 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
659 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
661 label
= gtk_label_new (_("Show text"));
662 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
663 gtk_widget_show (label
);
664 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
666 margin_x
= gtk_check_button_new ();
667 gtk_widget_show (margin_x
);
668 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
669 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
671 label
= gtk_label_new (_("Align center"));
672 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
673 gtk_widget_show (label
);
674 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 2, 3, GTK_FILL
, 0, 0, 0);
676 margin_x
= gtk_check_button_new ();
677 gtk_widget_show (margin_x
);
678 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
679 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 2, 3, GTK_FILL
, 0, 0, 0);
681 label
= gtk_label_new (_("Font shadow"));
682 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
683 gtk_widget_show (label
);
684 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 3, 4, GTK_FILL
, 0, 0, 0);
686 margin_x
= gtk_check_button_new ();
687 gtk_widget_show (margin_x
);
688 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
689 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 3, 4, GTK_FILL
, 0, 0, 0);
692 notebook
= gtk_notebook_new ();
693 gtk_widget_show (notebook
);
694 gtk_container_set_border_width(GTK_CONTAINER(notebook
), 0);
695 gtk_box_pack_start (GTK_BOX (parent
), notebook
, TRUE
, TRUE
, 0);
698 label
= gtk_label_new (_("Normal task"));
699 gtk_widget_show (label
);
700 page_task
= gtk_vbox_new (FALSE
, DEFAULT_HOR_SPACING
);
701 gtk_container_set_border_width(GTK_CONTAINER(page_task
), 10);
702 gtk_widget_show (page_task
);
703 gtk_notebook_append_page (GTK_NOTEBOOK (notebook
), page_task
, label
);
705 label
= gtk_label_new (_("Active task"));
706 gtk_widget_show (label
);
707 page_task
= gtk_vbox_new (FALSE
, DEFAULT_HOR_SPACING
);
708 gtk_container_set_border_width(GTK_CONTAINER(page_task
), 10);
709 gtk_widget_show (page_task
);
710 gtk_notebook_append_page (GTK_NOTEBOOK (notebook
), page_task
, label
);
712 label
= gtk_label_new (_("Urgent task"));
713 gtk_widget_show (label
);
714 page_task
= gtk_vbox_new (FALSE
, DEFAULT_HOR_SPACING
);
715 gtk_container_set_border_width(GTK_CONTAINER(page_task
), 10);
716 gtk_widget_show (page_task
);
717 gtk_notebook_append_page (GTK_NOTEBOOK (notebook
), page_task
, label
);
719 label
= gtk_label_new (_("Iconified task"));
720 gtk_widget_show (label
);
721 page_task
= gtk_vbox_new (FALSE
, DEFAULT_HOR_SPACING
);
722 gtk_container_set_border_width(GTK_CONTAINER(page_task
), 10);
723 gtk_widget_show (page_task
);
724 gtk_notebook_append_page (GTK_NOTEBOOK (notebook
), page_task
, label
);
728 void create_clock(GtkWidget
*parent
)
731 GtkWidget
*margin_x
, *margin_y
, *combo_background
;
734 table
= gtk_table_new (1, 2, FALSE
);
735 gtk_widget_show (table
);
736 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
737 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
738 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
740 label
= gtk_label_new (_("Show clock"));
741 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
742 gtk_widget_show (label
);
743 gtk_table_attach (GTK_TABLE (table
), label
, 0, 1, 0, 1, GTK_FILL
, 0, 0, 0);
745 margin_x
= gtk_check_button_new ();
746 gtk_widget_show (margin_x
);
747 gtk_table_attach (GTK_TABLE (table
), margin_x
, 1, 2, 0, 1, GTK_FILL
, 0, 0, 0);
749 change_paragraph(parent
);
751 label
= gtk_label_new (_("<b>Format and timezone</b>"));
752 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
753 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
); gtk_widget_show (label
);
754 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
756 table
= gtk_table_new (3, 10, FALSE
);
757 gtk_widget_show (table
);
758 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
759 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
760 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
762 label
= gtk_label_new (_("First line"));
763 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
764 gtk_widget_show (label
);
765 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
767 margin_x
= gtk_entry_new ();
768 gtk_widget_show (margin_x
);
769 gtk_entry_set_width_chars (GTK_ENTRY (margin_x
), 15);
770 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
772 label
= gtk_label_new (_("Second line"));
773 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
774 gtk_widget_show (label
);
775 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
777 margin_x
= gtk_entry_new ();
778 gtk_widget_show (margin_x
);
779 gtk_entry_set_width_chars (GTK_ENTRY (margin_x
), 15);
780 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
782 label
= gtk_label_new (_("Tooltip"));
783 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
784 gtk_widget_show (label
);
785 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 2, 3, GTK_FILL
, 0, 0, 0);
787 margin_x
= gtk_entry_new ();
788 gtk_widget_show (margin_x
);
789 gtk_entry_set_width_chars (GTK_ENTRY (margin_x
), 15);
790 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 2, 3, GTK_FILL
, 0, 0, 0);
792 label
= gtk_label_new (_("First line"));
793 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
794 gtk_widget_show (label
);
795 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 0, 1, GTK_FILL
, 0, 0, 0);
797 margin_x
= gtk_entry_new ();
798 gtk_widget_show (margin_x
);
799 gtk_entry_set_width_chars (GTK_ENTRY (margin_x
), 20);
800 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 0, 1, GTK_FILL
, 0, 0, 0);
802 label
= gtk_label_new (_("Second line"));
803 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
804 gtk_widget_show (label
);
805 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 1, 2, GTK_FILL
, 0, 0, 0);
807 margin_x
= gtk_entry_new ();
808 gtk_widget_show (margin_x
);
809 gtk_entry_set_width_chars (GTK_ENTRY (margin_x
), 20);
810 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 1, 2, GTK_FILL
, 0, 0, 0);
812 label
= gtk_label_new (_("Tooltip"));
813 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
814 gtk_widget_show (label
);
815 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 2, 3, GTK_FILL
, 0, 0, 0);
817 margin_x
= gtk_entry_new ();
818 gtk_widget_show (margin_x
);
819 gtk_entry_set_width_chars (GTK_ENTRY (margin_x
), 20);
820 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 2, 3, GTK_FILL
, 0, 0, 0);
822 change_paragraph(parent
);
824 label
= gtk_label_new (_("<b>Mouse action</b>"));
825 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
826 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
827 gtk_widget_show (label
);
828 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
830 table
= gtk_table_new (2, 10, FALSE
);
831 gtk_widget_show (table
);
832 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
833 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
834 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
836 label
= gtk_label_new (_("Left click command"));
837 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
838 gtk_widget_show (label
);
839 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
841 margin_x
= gtk_entry_new ();
842 gtk_widget_show (margin_x
);
843 gtk_entry_set_width_chars (GTK_ENTRY (margin_x
), 12);
844 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
846 label
= gtk_label_new (_("Right click command"));
847 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
848 gtk_widget_show (label
);
849 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 0, 1, GTK_FILL
, 0, 0, 0);
851 margin_x
= gtk_entry_new ();
852 gtk_widget_show (margin_x
);
853 gtk_entry_set_width_chars (GTK_ENTRY (margin_x
), 12);
854 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 0, 1, GTK_FILL
, 0, 0, 0);
856 change_paragraph(parent
);
858 label
= gtk_label_new (_("<b>Appearance</b>"));
859 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
860 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
861 gtk_widget_show (label
);
862 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
864 table
= gtk_table_new (3, 10, FALSE
);
865 gtk_widget_show (table
);
866 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
867 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
868 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
870 label
= gtk_label_new (_("Padding horizontal"));
871 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
872 gtk_widget_show (label
);
873 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
875 margin_x
= gtk_spin_button_new_with_range (0, 500, 1);
876 gtk_widget_show (margin_x
);
877 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
878 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
880 label
= gtk_label_new (_("Padding vertical"));
881 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
882 gtk_widget_show (label
);
883 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
885 margin_y
= gtk_spin_button_new_with_range (0, 500, 1);
886 gtk_widget_show (margin_y
);
887 gtk_entry_set_max_length (GTK_ENTRY (margin_y
), 3);
888 gtk_table_attach (GTK_TABLE (table
), margin_y
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
890 label
= gtk_label_new (_("Background"));
891 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
892 gtk_widget_show (label
);
893 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 2, 3, GTK_FILL
, 0, 0, 0);
895 combo_background
= gtk_combo_box_new_text ();
896 gtk_widget_show (combo_background
);
897 gtk_table_attach (GTK_TABLE (table
), combo_background
, 3, 4, 2, 3, GTK_FILL
, 0, 0, 0);
898 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 1"));
899 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 2"));
900 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 3"));
902 label
= gtk_label_new (_("Font first line"));
903 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
904 gtk_widget_show (label
);
905 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 0, 1, GTK_FILL
, 0, 0, 0);
907 margin_x
= gtk_font_button_new ();
908 gtk_widget_show (margin_x
);
909 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 0, 1, GTK_FILL
, 0, 0, 0);
910 // gtk_font_button_set_show_style (GTK_FONT_BUTTON (margin_x), FALSE);
912 label
= gtk_label_new (_("Font second line"));
913 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
914 gtk_widget_show (label
);
915 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 1, 2, GTK_FILL
, 0, 0, 0);
917 margin_x
= gtk_font_button_new ();
918 gtk_widget_show (margin_x
);
919 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 1, 2, GTK_FILL
, 0, 0, 0);
920 // gtk_font_button_set_show_style (GTK_FONT_BUTTON (margin_x), FALSE);
922 label
= gtk_label_new (_("Font color"));
923 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
924 gtk_widget_show (label
);
925 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 2, 3, GTK_FILL
, 0, 0, 0);
927 margin_x
= gtk_color_button_new();
928 gtk_color_button_set_use_alpha(GTK_COLOR_BUTTON(margin_x
), TRUE
);
929 gtk_widget_show (margin_x
);
930 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 2, 3, GTK_FILL
, 0, 0, 0);
932 change_paragraph(parent
);
936 void create_systemtray(GtkWidget
*parent
)
939 GtkWidget
*margin_x
, *margin_y
, *combo_background
;
942 table
= gtk_table_new (2, 2, FALSE
);
943 gtk_widget_show (table
);
944 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
945 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
946 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
948 label
= gtk_label_new (_("Show notification"));
949 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
950 gtk_widget_show (label
);
951 gtk_table_attach (GTK_TABLE (table
), label
, 0, 1, 0, 1, GTK_FILL
, 0, 0, 0);
953 margin_x
= gtk_check_button_new ();
954 gtk_widget_show (margin_x
);
955 gtk_table_attach (GTK_TABLE (table
), margin_x
, 1, 2, 0, 1, GTK_FILL
, 0, 0, 0);
957 label
= gtk_label_new (_("Icon ordering"));
958 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
959 gtk_widget_show (label
);
960 gtk_table_attach (GTK_TABLE (table
), label
, 0, 1, 1, 2, GTK_FILL
, 0, 0, 0);
962 combo_background
= gtk_combo_box_new_text ();
963 gtk_widget_show (combo_background
);
964 gtk_table_attach (GTK_TABLE (table
), combo_background
, 1, 2, 1, 2, GTK_FILL
, 0, 0, 0);
965 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Ascending"));
966 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Descending"));
967 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Left to right"));
968 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Right to left"));
970 change_paragraph(parent
);
972 label
= gtk_label_new (_("<b>Appearance</b>"));
973 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
974 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
975 gtk_widget_show (label
);
976 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
978 table
= gtk_table_new (6, 10, FALSE
);
979 gtk_widget_show (table
);
980 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
981 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
982 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
984 label
= gtk_label_new (_("Padding horizontal"));
985 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
986 gtk_widget_show (label
);
987 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
989 margin_x
= gtk_spin_button_new_with_range (0, 500, 1);
990 gtk_widget_show (margin_x
);
991 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
992 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
994 label
= gtk_label_new (_("Padding vertical"));
995 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
996 gtk_widget_show (label
);
997 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
999 margin_y
= gtk_spin_button_new_with_range (0, 500, 1);
1000 gtk_widget_show (margin_y
);
1001 gtk_entry_set_max_length (GTK_ENTRY (margin_y
), 3);
1002 gtk_table_attach (GTK_TABLE (table
), margin_y
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
1004 label
= gtk_label_new (_("Spacing"));
1005 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1006 gtk_widget_show (label
);
1007 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 2, 3, GTK_FILL
, 0, 0, 0);
1009 margin_x
= gtk_spin_button_new_with_range (0, 500, 1);
1010 gtk_widget_show (margin_x
);
1011 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
1012 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 2, 3, GTK_FILL
, 0, 0, 0);
1014 label
= gtk_label_new (_("Background"));
1015 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1016 gtk_widget_show (label
);
1017 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 3, 4, GTK_FILL
, 0, 0, 0);
1019 combo_background
= gtk_combo_box_new_text ();
1020 gtk_widget_show (combo_background
);
1021 gtk_table_attach (GTK_TABLE (table
), combo_background
, 3, 4, 3, 4, GTK_FILL
, 0, 0, 0);
1022 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 1"));
1023 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 2"));
1024 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 3"));
1026 label
= gtk_label_new (_("Icon size"));
1027 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1028 gtk_widget_show (label
);
1029 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 0, 1, GTK_FILL
, 0, 0, 0);
1031 margin_x
= gtk_spin_button_new_with_range (0, 500, 1);
1032 gtk_widget_show (margin_x
);
1033 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
1034 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 0, 1, GTK_FILL
, 0, 0, 0);
1036 label
= gtk_label_new (_("Icon opacity"));
1037 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1038 gtk_widget_show (label
);
1039 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 1, 2, GTK_FILL
, 0, 0, 0);
1041 margin_x
= gtk_spin_button_new_with_range (0, 100, 1);
1042 gtk_widget_show (margin_x
);
1043 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
1044 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 1, 2, GTK_FILL
, 0, 0, 0);
1046 label
= gtk_label_new (_("Icon saturation"));
1047 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1048 gtk_widget_show (label
);
1049 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 2, 3, GTK_FILL
, 0, 0, 0);
1051 margin_x
= gtk_spin_button_new_with_range (-100, 100, 1);
1052 gtk_widget_show (margin_x
);
1053 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
1054 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 2, 3, GTK_FILL
, 0, 0, 0);
1056 label
= gtk_label_new (_("Icon brightness"));
1057 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1058 gtk_widget_show (label
);
1059 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 3, 4, GTK_FILL
, 0, 0, 0);
1061 margin_x
= gtk_spin_button_new_with_range (-100, 100, 1);
1062 gtk_widget_show (margin_x
);
1063 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
1064 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 3, 4, GTK_FILL
, 0, 0, 0);
1069 void create_battery(GtkWidget
*parent
)
1072 GtkWidget
*margin_x
, *margin_y
, *combo_background
;
1075 table
= gtk_table_new (1, 2, FALSE
);
1076 gtk_widget_show (table
);
1077 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
1078 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
1079 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
1081 label
= gtk_label_new (_("Show battery"));
1082 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1083 gtk_widget_show (label
);
1084 gtk_table_attach (GTK_TABLE (table
), label
, 0, 1, 0, 1, GTK_FILL
, 0, 0, 0);
1086 margin_x
= gtk_check_button_new ();
1087 gtk_widget_show (margin_x
);
1088 gtk_table_attach (GTK_TABLE (table
), margin_x
, 1, 2, 0, 1, GTK_FILL
, 0, 0, 0);
1090 change_paragraph(parent
);
1092 label
= gtk_label_new (_("<b>Event</b>"));
1093 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1094 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
1095 gtk_widget_show (label
);
1096 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
1098 table
= gtk_table_new (2, 10, FALSE
);
1099 gtk_widget_show (table
);
1100 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
1101 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
1102 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
1104 label
= gtk_label_new (_("Hide if charge higher than"));
1105 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1106 gtk_widget_show (label
);
1107 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
1109 margin_x
= gtk_spin_button_new_with_range (0, 100, 1);
1110 gtk_widget_show (margin_x
);
1111 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
1112 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
1114 label
= gtk_label_new (_("%"));
1115 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1116 gtk_widget_show (label
);
1117 gtk_table_attach (GTK_TABLE (table
), label
, 4, 5, 0, 1, GTK_FILL
, 0, 0, 0);
1119 label
= gtk_label_new (_("Alert if charge lower than"));
1120 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1121 gtk_widget_show (label
);
1122 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
1124 margin_x
= gtk_spin_button_new_with_range (0, 100, 1);
1125 gtk_widget_show (margin_x
);
1126 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
1127 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
1129 label
= gtk_label_new (_("%"));
1130 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1131 gtk_widget_show (label
);
1132 gtk_table_attach (GTK_TABLE (table
), label
, 4, 5, 1, 2, GTK_FILL
, 0, 0, 0);
1134 change_paragraph(parent
);
1136 label
= gtk_label_new (_("<b>Appearance</b>"));
1137 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1138 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
1139 gtk_widget_show (label
);
1140 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
1142 table
= gtk_table_new (4, 10, FALSE
);
1143 gtk_widget_show (table
);
1144 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
1145 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
1146 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
1148 label
= gtk_label_new (_("Padding horizontal"));
1149 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1150 gtk_widget_show (label
);
1151 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
1153 margin_x
= gtk_spin_button_new_with_range (0, 500, 1);
1154 gtk_widget_show (margin_x
);
1155 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
1156 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
1158 label
= gtk_label_new (_("Padding vertical"));
1159 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1160 gtk_widget_show (label
);
1161 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
1163 margin_y
= gtk_spin_button_new_with_range (0, 500, 1);
1164 gtk_widget_show (margin_y
);
1165 gtk_entry_set_max_length (GTK_ENTRY (margin_y
), 3);
1166 gtk_table_attach (GTK_TABLE (table
), margin_y
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
1168 label
= gtk_label_new (_("Background"));
1169 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1170 gtk_widget_show (label
);
1171 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 2, 3, GTK_FILL
, 0, 0, 0);
1173 combo_background
= gtk_combo_box_new_text ();
1174 gtk_widget_show (combo_background
);
1175 gtk_table_attach (GTK_TABLE (table
), combo_background
, 3, 4, 2, 3, GTK_FILL
, 0, 0, 0);
1176 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 1"));
1177 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 2"));
1178 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 3"));
1180 label
= gtk_label_new (_("Font first line"));
1181 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1182 gtk_widget_show (label
);
1183 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 0, 1, GTK_FILL
, 0, 0, 0);
1185 margin_x
= gtk_font_button_new ();
1186 gtk_widget_show (margin_x
);
1187 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 0, 1, GTK_FILL
, 0, 0, 0);
1188 // gtk_font_button_set_show_style (GTK_FONT_BUTTON (margin_x), FALSE);
1190 label
= gtk_label_new (_("Font second line"));
1191 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1192 gtk_widget_show (label
);
1193 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 1, 2, GTK_FILL
, 0, 0, 0);
1195 margin_x
= gtk_font_button_new ();
1196 gtk_widget_show (margin_x
);
1197 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 1, 2, GTK_FILL
, 0, 0, 0);
1198 // gtk_font_button_set_show_style (GTK_FONT_BUTTON (margin_x), FALSE);
1200 label
= gtk_label_new (_("Font color"));
1201 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1202 gtk_widget_show (label
);
1203 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 2, 3, GTK_FILL
, 0, 0, 0);
1205 margin_x
= gtk_color_button_new();
1206 gtk_color_button_set_use_alpha(GTK_COLOR_BUTTON(margin_x
), TRUE
);
1207 gtk_widget_show (margin_x
);
1208 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 2, 3, GTK_FILL
, 0, 0, 0);
1210 change_paragraph(parent
);
1214 void create_tooltip(GtkWidget
*parent
)
1217 GtkWidget
*margin_x
, *margin_y
, *combo_background
;
1220 table
= gtk_table_new (1, 2, FALSE
);
1221 gtk_widget_show (table
);
1222 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
1223 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
1224 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
1226 label
= gtk_label_new (_("Show tooltip"));
1227 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1228 gtk_widget_show (label
);
1229 gtk_table_attach (GTK_TABLE (table
), label
, 0, 1, 0, 1, GTK_FILL
, 0, 0, 0);
1231 margin_x
= gtk_check_button_new ();
1232 gtk_widget_show (margin_x
);
1233 gtk_table_attach (GTK_TABLE (table
), margin_x
, 1, 2, 0, 1, GTK_FILL
, 0, 0, 0);
1235 change_paragraph(parent
);
1237 label
= gtk_label_new (_("<b>Timing</b>"));
1238 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1239 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
1240 gtk_widget_show (label
);
1241 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
1243 table
= gtk_table_new (2, 10, FALSE
);
1244 gtk_widget_show (table
);
1245 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
1246 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
1247 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
1249 label
= gtk_label_new (_("Show tooltip after"));
1250 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1251 gtk_widget_show (label
);
1252 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
1254 margin_x
= gtk_spin_button_new_with_range (0, 10000, 0.1);
1255 gtk_widget_show (margin_x
);
1256 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
1258 label
= gtk_label_new (_("seconds"));
1259 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1260 gtk_widget_show (label
);
1261 gtk_table_attach (GTK_TABLE (table
), label
, 4, 5, 0, 1, GTK_FILL
, 0, 0, 0);
1263 label
= gtk_label_new (_("Hide tooltip after"));
1264 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1265 gtk_widget_show (label
);
1266 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
1268 margin_y
= gtk_spin_button_new_with_range (0, 10000, 0.1);
1269 gtk_widget_show (margin_y
);
1270 gtk_table_attach (GTK_TABLE (table
), margin_y
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
1272 label
= gtk_label_new (_("seconds"));
1273 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1274 gtk_widget_show (label
);
1275 gtk_table_attach (GTK_TABLE (table
), label
, 4, 5, 1, 2, GTK_FILL
, 0, 0, 0);
1277 change_paragraph(parent
);
1279 label
= gtk_label_new (_("<b>Appearance</b>"));
1280 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1281 gtk_label_set_use_markup (GTK_LABEL (label
), TRUE
);
1282 gtk_widget_show (label
);
1283 gtk_box_pack_start(GTK_BOX (parent
), label
, FALSE
, FALSE
, 0);
1285 table
= gtk_table_new (3, 10, FALSE
);
1286 gtk_widget_show (table
);
1287 gtk_box_pack_start (GTK_BOX (parent
), table
, FALSE
, FALSE
, 0);
1288 gtk_table_set_row_spacings (GTK_TABLE (table
), ROW_SPACING
);
1289 gtk_table_set_col_spacings (GTK_TABLE (table
), COL_SPACING
);
1291 label
= gtk_label_new (_("Padding horizontal"));
1292 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1293 gtk_widget_show (label
);
1294 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 0, 1, GTK_FILL
, 0, 0, 0);
1296 margin_x
= gtk_spin_button_new_with_range (0, 500, 1);
1297 gtk_widget_show (margin_x
);
1298 gtk_entry_set_max_length (GTK_ENTRY (margin_x
), 3);
1299 gtk_table_attach (GTK_TABLE (table
), margin_x
, 3, 4, 0, 1, GTK_FILL
, 0, 0, 0);
1301 label
= gtk_label_new (_("Padding vertical"));
1302 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1303 gtk_widget_show (label
);
1304 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 1, 2, GTK_FILL
, 0, 0, 0);
1306 margin_y
= gtk_spin_button_new_with_range (0, 500, 1);
1307 gtk_widget_show (margin_y
);
1308 gtk_entry_set_max_length (GTK_ENTRY (margin_y
), 3);
1309 gtk_table_attach (GTK_TABLE (table
), margin_y
, 3, 4, 1, 2, GTK_FILL
, 0, 0, 0);
1311 label
= gtk_label_new (_("Background"));
1312 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1313 gtk_widget_show (label
);
1314 gtk_table_attach (GTK_TABLE (table
), label
, 2, 3, 2, 3, GTK_FILL
, 0, 0, 0);
1316 combo_background
= gtk_combo_box_new_text ();
1317 gtk_widget_show (combo_background
);
1318 gtk_table_attach (GTK_TABLE (table
), combo_background
, 3, 4, 2, 3, GTK_FILL
, 0, 0, 0);
1319 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 1"));
1320 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 2"));
1321 gtk_combo_box_append_text (GTK_COMBO_BOX (combo_background
), _("Back 3"));
1323 label
= gtk_label_new (_("Font"));
1324 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1325 gtk_widget_show (label
);
1326 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 0, 1, GTK_FILL
, 0, 0, 0);
1328 margin_x
= gtk_font_button_new ();
1329 gtk_widget_show (margin_x
);
1330 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 0, 1, GTK_FILL
, 0, 0, 0);
1331 // gtk_font_button_set_show_style (GTK_FONT_BUTTON (margin_x), FALSE);
1333 label
= gtk_label_new (_("Font color"));
1334 gtk_misc_set_alignment (GTK_MISC (label
), 0, 0);
1335 gtk_widget_show (label
);
1336 gtk_table_attach (GTK_TABLE (table
), label
, 6, 7, 1, 2, GTK_FILL
, 0, 0, 0);
1338 margin_x
= gtk_color_button_new();
1339 gtk_color_button_set_use_alpha(GTK_COLOR_BUTTON(margin_x
), TRUE
);
1340 gtk_widget_show (margin_x
);
1341 gtk_table_attach (GTK_TABLE (table
), margin_x
, 7, 8, 1, 2, GTK_FILL
, 0, 0, 0);
1343 change_paragraph(parent
);
1348 void create_background(GtkWidget
*parent
)