summaryrefslogtreecommitdiff
path: root/tests/testgtk.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/testgtk.c')
-rw-r--r--tests/testgtk.c722
1 files changed, 352 insertions, 370 deletions
diff --git a/tests/testgtk.c b/tests/testgtk.c
index 3c38d7a763..4bba2a2dac 100644
--- a/tests/testgtk.c
+++ b/tests/testgtk.c
@@ -214,10 +214,10 @@ build_alpha_widgets (void)
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
label = gtk_label_new (NULL);
gtk_label_set_markup (GTK_LABEL (label), "<i>Entry: </i>");
- gtk_box_pack_start (GTK_BOX (hbox), label, FALSE);
+ gtk_box_pack_start (GTK_BOX (hbox), label);
entry = gtk_entry_new ();
gtk_widget_set_hexpand (entry, TRUE);
- gtk_box_pack_start (GTK_BOX (hbox), entry, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), entry);
gtk_widget_set_hexpand (hbox, TRUE);
gtk_grid_attach (GTK_GRID (grid), hbox, 0, 3, 2, 1);
@@ -263,19 +263,18 @@ create_alpha_window (GtkWidget *widget)
content_area = gtk_dialog_get_content_area (GTK_DIALOG (window));
vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 8);
- gtk_box_pack_start (GTK_BOX (content_area), vbox,
- TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), vbox);
label = gtk_label_new (NULL);
- gtk_box_pack_start (GTK_BOX (vbox), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), label);
label = gtk_label_new (NULL);
- gtk_box_pack_start (GTK_BOX (vbox), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), label);
display = gtk_widget_get_display (window);
on_composited_changed (display, NULL, GTK_LABEL (label));
g_signal_connect (display, "notify::composited", G_CALLBACK (on_composited_changed), label);
- gtk_box_pack_start (GTK_BOX (vbox), build_alpha_widgets (), TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), build_alpha_widgets ());
g_signal_connect (window, "destroy",
G_CALLBACK (gtk_widget_destroyed),
@@ -337,7 +336,7 @@ create_buttons (GtkWidget *widget)
grid = gtk_grid_new ();
gtk_grid_set_row_spacing (GTK_GRID (grid), 5);
gtk_grid_set_column_spacing (GTK_GRID (grid), 5);
- gtk_box_pack_start (GTK_BOX (box1), grid, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), grid);
button[0] = gtk_button_new_with_label ("button1");
button[1] = gtk_button_new_with_mnemonic ("_button2");
@@ -362,16 +361,16 @@ create_buttons (GtkWidget *widget)
}
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button[9] = gtk_button_new_with_label ("close");
g_signal_connect_swapped (button[9], "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (box2), button[9], TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button[9]);
gtk_widget_set_can_default (button[9], TRUE);
gtk_widget_grab_default (button[9]);
}
@@ -411,28 +410,28 @@ create_toggle_buttons (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (window), box1);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_toggle_button_new_with_label ("button1");
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
button = gtk_toggle_button_new_with_label ("button2");
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
button = gtk_toggle_button_new_with_label ("button3");
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_button_new_with_label ("close");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);
}
@@ -531,26 +530,26 @@ create_check_buttons (GtkWidget *widget)
box1 = gtk_dialog_get_content_area (GTK_DIALOG (window));
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_check_button_new_with_mnemonic ("_button1");
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
button = gtk_check_button_new_with_label ("button2");
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
button = gtk_check_button_new_with_label ("button3");
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
button = gtk_check_button_new_with_label ("inconsistent");
gtk_check_button_set_inconsistent (GTK_CHECK_BUTTON (button), TRUE);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
table = create_widget_grid (GTK_TYPE_CHECK_BUTTON);
- gtk_box_pack_start (GTK_BOX (box1), table, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), table);
}
if (!gtk_widget_get_visible (window))
@@ -594,56 +593,56 @@ create_radio_buttons (GtkWidget *widget)
box1 = gtk_dialog_get_content_area (GTK_DIALOG (window));
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_radio_button_new_with_label (NULL, "button1");
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
button = gtk_radio_button_new_with_label (
gtk_radio_button_get_group (GTK_RADIO_BUTTON (button)),
"button2");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button), TRUE);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
button = gtk_radio_button_new_with_label (
gtk_radio_button_get_group (GTK_RADIO_BUTTON (button)),
"button3");
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
button = gtk_radio_button_new_with_label (
gtk_radio_button_get_group (GTK_RADIO_BUTTON (button)),
"inconsistent");
gtk_check_button_set_inconsistent (GTK_CHECK_BUTTON (button), TRUE);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_radio_button_new_with_label (NULL, "button4");
gtk_check_button_set_draw_indicator (GTK_CHECK_BUTTON (button), FALSE);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
button = gtk_radio_button_new_with_label (
gtk_radio_button_get_group (GTK_RADIO_BUTTON (button)),
"button5");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button), TRUE);
gtk_check_button_set_draw_indicator (GTK_CHECK_BUTTON (button), FALSE);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
button = gtk_radio_button_new_with_label (
gtk_radio_button_get_group (GTK_RADIO_BUTTON (button)),
"button6");
gtk_check_button_set_draw_indicator (GTK_CHECK_BUTTON (button), FALSE);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
table = create_widget_grid (GTK_TYPE_RADIO_BUTTON);
- gtk_box_pack_start (GTK_BOX (box1), table, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), table);
}
if (!gtk_widget_get_visible (window))
@@ -718,58 +717,48 @@ create_button_box (GtkWidget *widget)
frame_horz = gtk_frame_new ("Horizontal Button Boxes");
gtk_widget_set_margin_top (frame_horz, 10);
gtk_widget_set_margin_bottom (frame_horz, 10);
- gtk_box_pack_start (GTK_BOX (main_vbox), frame_horz, TRUE);
+ gtk_box_pack_start (GTK_BOX (main_vbox), frame_horz);
vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
gtk_container_add (GTK_CONTAINER (frame_horz), vbox);
gtk_box_pack_start (GTK_BOX (vbox),
- create_bbox (TRUE, "Spread", 40, 85, 20, GTK_BUTTONBOX_SPREAD),
- TRUE);
+ create_bbox (TRUE, "Spread", 40, 85, 20, GTK_BUTTONBOX_SPREAD));
gtk_box_pack_start (GTK_BOX (vbox),
- create_bbox (TRUE, "Edge", 40, 85, 20, GTK_BUTTONBOX_EDGE),
- TRUE);
+ create_bbox (TRUE, "Edge", 40, 85, 20, GTK_BUTTONBOX_EDGE));
gtk_box_pack_start (GTK_BOX (vbox),
- create_bbox (TRUE, "Start", 40, 85, 20, GTK_BUTTONBOX_START),
- TRUE);
+ create_bbox (TRUE, "Start", 40, 85, 20, GTK_BUTTONBOX_START));
gtk_box_pack_start (GTK_BOX (vbox),
- create_bbox (TRUE, "End", 40, 85, 20, GTK_BUTTONBOX_END),
- TRUE);
+ create_bbox (TRUE, "End", 40, 85, 20, GTK_BUTTONBOX_END));
gtk_box_pack_start (GTK_BOX (vbox),
- create_bbox (TRUE, "Center", 40, 85, 20, GTK_BUTTONBOX_CENTER),
- TRUE);
+ create_bbox (TRUE, "Center", 40, 85, 20, GTK_BUTTONBOX_CENTER));
frame_vert = gtk_frame_new ("Vertical Button Boxes");
gtk_widget_set_margin_top (frame_vert, 10);
gtk_widget_set_margin_bottom (frame_vert, 10);
- gtk_box_pack_start (GTK_BOX (main_vbox), frame_vert, TRUE);
+ gtk_box_pack_start (GTK_BOX (main_vbox), frame_vert);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
gtk_container_add (GTK_CONTAINER (frame_vert), hbox);
gtk_box_pack_start (GTK_BOX (hbox),
- create_bbox (FALSE, "Spread", 30, 85, 20, GTK_BUTTONBOX_SPREAD),
- TRUE);
+ create_bbox (FALSE, "Spread", 30, 85, 20, GTK_BUTTONBOX_SPREAD));
gtk_box_pack_start (GTK_BOX (hbox),
- create_bbox (FALSE, "Edge", 30, 85, 20, GTK_BUTTONBOX_EDGE),
- TRUE);
+ create_bbox (FALSE, "Edge", 30, 85, 20, GTK_BUTTONBOX_EDGE));
gtk_box_pack_start (GTK_BOX (hbox),
- create_bbox (FALSE, "Start", 30, 85, 20, GTK_BUTTONBOX_START),
- TRUE);
+ create_bbox (FALSE, "Start", 30, 85, 20, GTK_BUTTONBOX_START));
gtk_box_pack_start (GTK_BOX (hbox),
- create_bbox (FALSE, "End", 30, 85, 20, GTK_BUTTONBOX_END),
- TRUE);
+ create_bbox (FALSE, "End", 30, 85, 20, GTK_BUTTONBOX_END));
gtk_box_pack_start (GTK_BOX (hbox),
- create_bbox (FALSE, "Center", 30, 85, 20, GTK_BUTTONBOX_CENTER),
- TRUE);
+ create_bbox (FALSE, "Center", 30, 85, 20, GTK_BUTTONBOX_CENTER));
}
if (!gtk_widget_get_visible (window))
@@ -912,10 +901,10 @@ create_statusbar (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (window), box1);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
statusbar = gtk_statusbar_new ();
- gtk_box_pack_end (GTK_BOX (box1), statusbar, TRUE);
+ gtk_box_pack_end (GTK_BOX (box1), statusbar);
g_signal_connect (statusbar,
"text_popped",
G_CALLBACK (statusbar_popped),
@@ -963,16 +952,16 @@ create_statusbar (GtkWidget *widget)
NULL);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_button_new_with_label ("close");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);
}
@@ -1023,64 +1012,64 @@ create_alpha_widgets (GtkWidget *widget)
vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
- gtk_box_pack_start (GTK_BOX (main_hbox), vbox, FALSE);
+ gtk_box_pack_start (GTK_BOX (main_hbox), vbox);
/* Plain button (no gdkwindows */
label = gtk_label_new ("non-window widget");
- gtk_box_pack_start (GTK_BOX (vbox), label, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), label);
alpha1 = button = gtk_button_new_with_label ("A Button");
- gtk_box_pack_start (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
/* windowed container with both windowed and normal button */
label = gtk_label_new ("\nwindow widget");
- gtk_box_pack_start (GTK_BOX (vbox), label, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), label);
alpha2 = event_box = gtk_event_box_new ();
- gtk_box_pack_start (GTK_BOX (vbox), event_box, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), event_box);
vbox2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
gtk_container_add (GTK_CONTAINER (event_box), vbox2);
button = gtk_button_new_with_label ("A Button");
- gtk_box_pack_start (GTK_BOX (vbox2), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox2), button);
event_box = gtk_event_box_new ();
button = gtk_button_new_with_label ("A Button (in window)");
gtk_container_add (GTK_CONTAINER (event_box), button);
- gtk_box_pack_start (GTK_BOX (vbox2), event_box, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox2), event_box);
/* non-windowed container with both windowed and normal button */
label = gtk_label_new ("\nnon-window widget with widget child");
- gtk_box_pack_start (GTK_BOX (vbox), label, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), label);
alpha3 = vbox2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
- gtk_box_pack_start (GTK_BOX (vbox), vbox2, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), vbox2);
button = gtk_button_new_with_label ("A Button");
- gtk_box_pack_start (GTK_BOX (vbox2), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox2), button);
event_box = gtk_event_box_new ();
button = gtk_button_new_with_label ("A Button (in window)");
gtk_container_add (GTK_CONTAINER (event_box), button);
- gtk_box_pack_start (GTK_BOX (vbox2), event_box, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox2), event_box);
scale = gtk_scale_new_with_range (GTK_ORIENTATION_VERTICAL,
0, 100, 1);
- gtk_box_pack_start (GTK_BOX (main_hbox), scale, FALSE);
+ gtk_box_pack_start (GTK_BOX (main_hbox), scale);
g_signal_connect (scale, "value_changed", G_CALLBACK (alpha_changed), alpha1);
gtk_range_set_value (GTK_RANGE (scale), 50);
scale = gtk_scale_new_with_range (GTK_ORIENTATION_VERTICAL,
0, 100, 1);
- gtk_box_pack_start (GTK_BOX (main_hbox), scale, FALSE);
+ gtk_box_pack_start (GTK_BOX (main_hbox), scale);
g_signal_connect (scale, "value_changed", G_CALLBACK (alpha_changed), alpha2);
gtk_range_set_value (GTK_RANGE (scale), 50);
scale = gtk_scale_new_with_range (GTK_ORIENTATION_VERTICAL,
0, 100, 1);
- gtk_box_pack_start (GTK_BOX (main_hbox), scale, FALSE);
+ gtk_box_pack_start (GTK_BOX (main_hbox), scale);
g_signal_connect (scale, "value_changed", G_CALLBACK (alpha_changed), alpha3);
gtk_range_set_value (GTK_RANGE (scale), 50);
@@ -1244,45 +1233,45 @@ void create_labels (GtkWidget *widget)
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 5);
gtk_container_add (GTK_CONTAINER (window), vbox);
- gtk_box_pack_end (GTK_BOX (vbox), hbox, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), hbox);
button = create_sensitivity_control (hbox);
- gtk_box_pack_start (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
button = create_selectable_control (hbox);
- gtk_box_pack_start (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5);
- gtk_box_pack_start (GTK_BOX (hbox), vbox, FALSE);
+ gtk_box_pack_start (GTK_BOX (hbox), vbox);
frame = gtk_frame_new ("Normal Label");
label = gtk_label_new ("This is a Normal label");
gtk_label_set_ellipsize (GTK_LABEL (label), PANGO_ELLIPSIZE_START);
gtk_container_add (GTK_CONTAINER (frame), label);
- gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
frame = gtk_frame_new ("Multi-line Label");
label = gtk_label_new ("This is a Multi-line label.\nSecond line\nThird line");
gtk_label_set_ellipsize (GTK_LABEL (label), PANGO_ELLIPSIZE_END);
gtk_container_add (GTK_CONTAINER (frame), label);
- gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
frame = gtk_frame_new ("Left Justified Label");
label = gtk_label_new ("This is a Left-Justified\nMulti-line label.\nThird line");
gtk_label_set_ellipsize (GTK_LABEL (label), PANGO_ELLIPSIZE_MIDDLE);
gtk_label_set_justify (GTK_LABEL (label), GTK_JUSTIFY_LEFT);
gtk_container_add (GTK_CONTAINER (frame), label);
- gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
frame = gtk_frame_new ("Right Justified Label");
gtk_label_set_ellipsize (GTK_LABEL (label), PANGO_ELLIPSIZE_START);
label = gtk_label_new ("This is a Right-Justified\nMulti-line label.\nFourth line, (j/k)");
gtk_label_set_justify (GTK_LABEL (label), GTK_JUSTIFY_RIGHT);
gtk_container_add (GTK_CONTAINER (frame), label);
- gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
frame = gtk_frame_new ("Internationalized Label");
label = gtk_label_new (NULL);
@@ -1295,13 +1284,13 @@ void create_labels (GtkWidget *widget)
"Japanese <span lang=\"ja\">\345\205\203\346\260\227 \351\226\213\347\231\272</span>");
gtk_label_set_justify (GTK_LABEL (label), GTK_JUSTIFY_LEFT);
gtk_container_add (GTK_CONTAINER (frame), label);
- gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
frame = gtk_frame_new ("Bidirection Label");
label = gtk_label_new ("\342\200\217Arabic \330\247\331\204\330\263\331\204\330\247\331\205 \330\271\331\204\331\212\331\203\331\205\n"
"\342\200\217Hebrew \327\251\327\234\327\225\327\235");
gtk_container_add (GTK_CONTAINER (frame), label);
- gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
frame = gtk_frame_new ("Links in a label");
label = gtk_label_new ("Some <a href=\"http://en.wikipedia.org/wiki/Text\" title=\"plain text\">text</a> may be marked up\n"
@@ -1309,11 +1298,11 @@ void create_labels (GtkWidget *widget)
"or activated via <a href=\"keynav\">keynav</a>");
gtk_label_set_use_markup (GTK_LABEL (label), TRUE);
gtk_container_add (GTK_CONTAINER (frame), label);
- gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
g_signal_connect (label, "activate-link", G_CALLBACK (activate_link), NULL);
vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5);
- gtk_box_pack_start (GTK_BOX (hbox), vbox, FALSE);
+ gtk_box_pack_start (GTK_BOX (hbox), vbox);
frame = gtk_frame_new ("Line wrapped label");
label = gtk_label_new ("This is an example of a line-wrapped label. It should not be taking "\
"up the entire "/* big space to test spacing */\
@@ -1325,7 +1314,7 @@ void create_labels (GtkWidget *widget)
gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
gtk_container_add (GTK_CONTAINER (frame), label);
- gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
frame = gtk_frame_new ("Filled, wrapped label");
label = gtk_label_new ("This is an example of a line-wrapped, filled label. It should be taking "\
@@ -1338,7 +1327,7 @@ void create_labels (GtkWidget *widget)
gtk_label_set_justify (GTK_LABEL (label), GTK_JUSTIFY_FILL);
gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
gtk_container_add (GTK_CONTAINER (frame), label);
- gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
frame = gtk_frame_new ("Underlined label");
label = gtk_label_new ("This label is underlined!\n"
@@ -1346,7 +1335,7 @@ void create_labels (GtkWidget *widget)
gtk_label_set_justify (GTK_LABEL (label), GTK_JUSTIFY_LEFT);
gtk_label_set_pattern (GTK_LABEL (label), "_________________________ _ _________ _ _____ _ __ __ ___ ____ _____");
gtk_container_add (GTK_CONTAINER (frame), label);
- gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
frame = gtk_frame_new ("Markup label");
label = gtk_label_new (NULL);
@@ -1373,7 +1362,7 @@ void create_labels (GtkWidget *widget)
g_assert (gtk_label_get_mnemonic_keyval (GTK_LABEL (label)) == GDK_KEY_s);
gtk_container_add (GTK_CONTAINER (frame), label);
- gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
}
if (!gtk_widget_get_visible (window))
@@ -1420,18 +1409,18 @@ create_rotated_label (GtkWidget *widget)
content_area = gtk_dialog_get_content_area (GTK_DIALOG (window));
vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5);
- gtk_box_pack_start (GTK_BOX (content_area), vbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), vbox);
label = gtk_label_new (NULL);
gtk_label_set_markup (GTK_LABEL (label), "Hello World\n<i>Rotate</i> <span underline='single' foreground='blue'>me</span>");
- gtk_box_pack_start (GTK_BOX (vbox), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), label);
scale_hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
- gtk_box_pack_start (GTK_BOX (vbox), scale_hbox, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), scale_hbox);
scale_label = gtk_label_new (NULL);
gtk_label_set_markup (GTK_LABEL (scale_label), "<i>Angle: </i>");
- gtk_box_pack_start (GTK_BOX (scale_hbox), scale_label, FALSE);
+ gtk_box_pack_start (GTK_BOX (scale_hbox), scale_label);
hscale = gtk_scale_new_with_range (GTK_ORIENTATION_HORIZONTAL,
0, 360, 5);
@@ -1440,7 +1429,7 @@ create_rotated_label (GtkWidget *widget)
gtk_range_set_value (GTK_RANGE (hscale), 45);
gtk_widget_set_size_request (hscale, 200, -1);
- gtk_box_pack_start (GTK_BOX (scale_hbox), hscale, TRUE);
+ gtk_box_pack_start (GTK_BOX (scale_hbox), hscale);
}
if (!gtk_widget_get_visible (window))
@@ -1552,7 +1541,7 @@ create_rotated_text (GtkWidget *widget)
content_area = gtk_dialog_get_content_area (GTK_DIALOG (window));
drawing_area = gtk_drawing_area_new ();
- gtk_box_pack_start (GTK_BOX (content_area), drawing_area, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), drawing_area);
tile_pixbuf = gdk_pixbuf_new_from_file ("marble.xpm", NULL);
@@ -1639,22 +1628,22 @@ create_reparent (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (window), box1);
box2 = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 5);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
label = gtk_label_new ("Hello World");
frame = gtk_frame_new ("Frame 1");
- gtk_box_pack_start (GTK_BOX (box2), frame, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), frame);
box3 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5);
gtk_container_add (GTK_CONTAINER (frame), box3);
button = gtk_button_new_with_label ("switch");
g_object_set_data (G_OBJECT (button), "user_data", label);
- gtk_box_pack_start (GTK_BOX (box3), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box3), button);
event_box = gtk_event_box_new ();
- gtk_box_pack_start (GTK_BOX (box3), event_box, TRUE);
+ gtk_box_pack_start (GTK_BOX (box3), event_box);
gtk_container_add (GTK_CONTAINER (event_box), label);
g_signal_connect (button, "clicked",
@@ -1666,32 +1655,32 @@ create_reparent (GtkWidget *widget)
GINT_TO_POINTER (42));
frame = gtk_frame_new ("Frame 2");
- gtk_box_pack_start (GTK_BOX (box2), frame, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), frame);
box3 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5);
gtk_container_add (GTK_CONTAINER (frame), box3);
button = gtk_button_new_with_label ("switch");
g_object_set_data (G_OBJECT (button), "user_data", label);
- gtk_box_pack_start (GTK_BOX (box3), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box3), button);
event_box = gtk_event_box_new ();
- gtk_box_pack_start (GTK_BOX (box3), event_box, TRUE);
+ gtk_box_pack_start (GTK_BOX (box3), event_box);
g_signal_connect (button, "clicked",
G_CALLBACK (reparent_label),
event_box);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_button_new_with_label ("close");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy), window);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);
}
@@ -1792,43 +1781,43 @@ create_saved_position (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (vbox), button);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
- gtk_box_pack_start (GTK_BOX (vbox), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), hbox);
label = gtk_label_new ("X Origin : ");
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (hbox), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), label);
x_label = gtk_label_new ("");
- gtk_box_pack_start (GTK_BOX (hbox), x_label, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), x_label);
g_object_set_data (G_OBJECT (window), "x", x_label);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
- gtk_box_pack_start (GTK_BOX (vbox), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), hbox);
label = gtk_label_new ("Y Origin : ");
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (hbox), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), label);
y_label = gtk_label_new ("");
- gtk_box_pack_start (GTK_BOX (hbox), y_label, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), y_label);
g_object_set_data (G_OBJECT (window), "y", y_label);
any =
g_object_new (gtk_separator_get_type (),
"GtkWidget::visible", TRUE,
NULL);
- gtk_box_pack_start (GTK_BOX (main_vbox), any, TRUE);
+ gtk_box_pack_start (GTK_BOX (main_vbox), any);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
- gtk_box_pack_start (GTK_BOX (main_vbox), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (main_vbox), hbox);
button = gtk_button_new_with_label ("Close");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (hbox), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);
@@ -1873,10 +1862,10 @@ create_pixbuf (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (window), box1);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_button_new ();
- gtk_box_pack_start (GTK_BOX (box2), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gdk_window = gtk_widget_get_window (window);
@@ -1889,7 +1878,7 @@ create_pixbuf (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (button), box3);
button = gtk_button_new ();
- gtk_box_pack_start (GTK_BOX (box2), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
pixbufwid = new_pixbuf ("test.xpm", gdk_window);
@@ -1902,16 +1891,16 @@ create_pixbuf (GtkWidget *widget)
gtk_widget_set_sensitive (button, FALSE);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_button_new_with_label ("close");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);
}
@@ -1950,15 +1939,15 @@ create_tooltips (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (window), box1);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_toggle_button_new_with_label ("button1");
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_tooltip_text (button, "This is button 1");
button = gtk_toggle_button_new_with_label ("button2");
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_tooltip_text (button,
"This is button 2. This is also a really long tooltip which probably "
@@ -1966,7 +1955,7 @@ create_tooltips (GtkWidget *widget)
"Hopefully the wrapping will work correctly.");
toggle = gtk_toggle_button_new_with_label ("Override TipsQuery Label");
- gtk_box_pack_start (GTK_BOX (box2), toggle, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), toggle);
gtk_widget_set_tooltip_text (toggle, "Toggle TipsQuery view.");
@@ -1984,7 +1973,7 @@ create_tooltips (GtkWidget *widget)
"visible", TRUE,
"parent", box3,
NULL);
- gtk_box_set_child_packing (GTK_BOX (box3), button, FALSE, GTK_PACK_START);
+ gtk_box_set_child_packing (GTK_BOX (box3), button, GTK_PACK_START);
gtk_widget_set_tooltip_text (button, "Start the Tooltips Inspector");
frame = g_object_new (gtk_frame_get_type (),
@@ -1994,19 +1983,19 @@ create_tooltips (GtkWidget *widget)
"parent", box2,
NULL);
gtk_container_add (GTK_CONTAINER (frame), box3);
- gtk_box_set_child_packing (GTK_BOX (box2), frame, TRUE, GTK_PACK_START);
+ gtk_box_set_child_packing (GTK_BOX (box2), frame, GTK_PACK_START);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_button_new_with_label ("close");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);
@@ -2029,12 +2018,10 @@ pack_image (GtkWidget *box,
GtkWidget *image)
{
gtk_box_pack_start (GTK_BOX (box),
- gtk_label_new (text),
- FALSE);
+ gtk_label_new (text));
gtk_box_pack_start (GTK_BOX (box),
- image,
- TRUE);
+ image);
}
static void
@@ -2548,7 +2535,7 @@ create_menus (GtkWidget *widget)
gtk_widget_show (box1);
menubar = gtk_menu_bar_new ();
- gtk_box_pack_start (GTK_BOX (box1), menubar, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), menubar);
gtk_widget_show (menubar);
menu = create_menu (screen, 2, 50);
@@ -2586,7 +2573,7 @@ create_menus (GtkWidget *widget)
gtk_widget_show (menuitem);
menubar = gtk_menu_bar_new ();
- gtk_box_pack_start (GTK_BOX (box1), menubar, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), menubar);
gtk_widget_show (menubar);
menu = create_menu (screen, 2, 10);
@@ -2597,7 +2584,7 @@ create_menus (GtkWidget *widget)
gtk_widget_show (menuitem);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
gtk_widget_show (box2);
menu = create_menu (screen, 1, 5);
@@ -2639,22 +2626,22 @@ create_menus (GtkWidget *widget)
optionmenu = gtk_combo_box_text_new ();
gtk_combo_box_set_active (GTK_COMBO_BOX (optionmenu), 3);
- gtk_box_pack_start (GTK_BOX (box2), optionmenu, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), optionmenu);
gtk_widget_show (optionmenu);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
gtk_widget_show (separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
gtk_widget_show (box2);
button = gtk_button_new_with_label ("close");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);
gtk_widget_show (button);
@@ -2721,33 +2708,33 @@ create_key_lookup (GtkWidget *widget)
content_area = gtk_dialog_get_content_area (GTK_DIALOG (window));
button = gtk_button_new_with_mnemonic ("Button 1 (_a)");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = gtk_button_new_with_mnemonic ("Button 2 (_A)");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = gtk_button_new_with_mnemonic ("Button 3 (_\321\204)");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = gtk_button_new_with_mnemonic ("Button 4 (_\320\244)");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = gtk_button_new_with_mnemonic ("Button 6 (_b)");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = accel_button_new (accel_group, "Button 7", "<Alt><Shift>b");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = accel_button_new (accel_group, "Button 8", "<Alt>d");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = accel_button_new (accel_group, "Button 9", "<Alt>Cyrillic_ve");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = gtk_button_new_with_mnemonic ("Button 10 (_1)");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = gtk_button_new_with_mnemonic ("Button 11 (_!)");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = accel_button_new (accel_group, "Button 12", "<Super>a");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = accel_button_new (accel_group, "Button 13", "<Hyper>a");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = accel_button_new (accel_group, "Button 14", "<Meta>a");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
button = accel_button_new (accel_group, "Button 15", "<Shift><Mod4>b");
- gtk_box_pack_start (GTK_BOX (content_area), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
window_ptr = &window;
g_object_add_weak_pointer (G_OBJECT (window), window_ptr);
@@ -2847,12 +2834,12 @@ create_modal_window (GtkWidget *widget)
/* Pack widgets */
gtk_container_add (GTK_CONTAINER (window), box1);
- gtk_box_pack_start (GTK_BOX (box1), frame1, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), frame1);
gtk_container_add (GTK_CONTAINER (frame1), box2);
- gtk_box_pack_start (GTK_BOX (box2), btnColor, FALSE);
- gtk_box_pack_start (GTK_BOX (box2), btnFile, FALSE);
- gtk_box_pack_start (GTK_BOX (box1), gtk_separator_new (GTK_ORIENTATION_HORIZONTAL), FALSE);
- gtk_box_pack_start (GTK_BOX (box1), btnClose, FALSE);
+ gtk_box_pack_start (GTK_BOX (box2), btnColor);
+ gtk_box_pack_start (GTK_BOX (box2), btnFile);
+ gtk_box_pack_start (GTK_BOX (box1), gtk_separator_new (GTK_ORIENTATION_HORIZONTAL));
+ gtk_box_pack_start (GTK_BOX (box1), btnClose);
/* connect signals */
g_signal_connect_swapped (btnClose, "clicked",
@@ -3039,7 +3026,7 @@ create_scrolled_windows (GtkWidget *widget)
gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolled_window),
GTK_POLICY_AUTOMATIC,
GTK_POLICY_AUTOMATIC);
- gtk_box_pack_start (GTK_BOX (content_area), scrolled_window, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), scrolled_window);
gtk_widget_show (scrolled_window);
grid = gtk_grid_new ();
@@ -3195,15 +3182,15 @@ create_entry (GtkWidget *widget)
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 5);
- gtk_box_pack_start (GTK_BOX (box2), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), hbox);
entry = gtk_entry_new ();
gtk_entry_set_text (GTK_ENTRY (entry), "hello world \330\247\331\204\330\263\331\204\330\247\331\205 \330\271\331\204\331\212\331\203\331\205");
gtk_editable_select_region (GTK_EDITABLE (entry), 0, 5);
- gtk_box_pack_start (GTK_BOX (hbox), entry, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), entry);
cb = GTK_COMBO_BOX_TEXT (gtk_combo_box_text_new_with_entry ());
@@ -3222,41 +3209,41 @@ create_entry (GtkWidget *widget)
cb_entry = gtk_bin_get_child (GTK_BIN (cb));
gtk_entry_set_text (GTK_ENTRY (cb_entry), "hello world \n\n\n foo");
gtk_editable_select_region (GTK_EDITABLE (cb_entry), 0, -1);
- gtk_box_pack_start (GTK_BOX (box2), GTK_WIDGET (cb), TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), GTK_WIDGET (cb));
sensitive_check = gtk_check_button_new_with_label("Sensitive");
- gtk_box_pack_start (GTK_BOX (box2), sensitive_check, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), sensitive_check);
g_signal_connect (sensitive_check, "toggled",
G_CALLBACK (entry_toggle_sensitive), entry);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (sensitive_check), TRUE);
has_frame_check = gtk_check_button_new_with_label("Has Frame");
- gtk_box_pack_start (GTK_BOX (box2), has_frame_check, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), has_frame_check);
g_signal_connect (has_frame_check, "toggled",
G_CALLBACK (entry_toggle_frame), entry);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (has_frame_check), TRUE);
progress_check = gtk_check_button_new_with_label("Show Progress");
- gtk_box_pack_start (GTK_BOX (box2), progress_check, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), progress_check);
g_signal_connect (progress_check, "toggled",
G_CALLBACK (entry_toggle_progress), entry);
progress_check = gtk_check_button_new_with_label("Pulse Progress");
- gtk_box_pack_start (GTK_BOX (box2), progress_check, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), progress_check);
g_signal_connect (progress_check, "toggled",
G_CALLBACK (entry_toggle_pulse), entry);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_button_new_with_label ("close");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);
}
@@ -3292,7 +3279,7 @@ create_expander (GtkWidget *widget)
expander = gtk_expander_new ("The Hidden");
- gtk_box_pack_start (GTK_BOX (box1), expander, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), expander);
hidden = gtk_label_new ("Revealed!");
@@ -3387,10 +3374,10 @@ create_event_box (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (window), box1);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
- gtk_box_pack_start (GTK_BOX (box1), hbox, FALSE);
+ gtk_box_pack_start (GTK_BOX (box1), hbox);
event_box = gtk_event_box_new ();
- gtk_box_pack_start (GTK_BOX (hbox), event_box, FALSE);
+ gtk_box_pack_start (GTK_BOX (hbox), event_box);
vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
gtk_container_add (GTK_CONTAINER (event_box), vbox);
@@ -3402,38 +3389,38 @@ create_event_box (GtkWidget *widget)
NULL);
label = gtk_label_new ("Click on this label");
- gtk_box_pack_start (GTK_BOX (vbox), label, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), label);
button = gtk_button_new_with_label ("button in eventbox");
- gtk_box_pack_start (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
g_signal_connect (button, "clicked",
G_CALLBACK (event_box_button_clicked),
NULL);
visible_window_check = gtk_check_button_new_with_label("Visible Window");
- gtk_box_pack_start (GTK_BOX (box1), visible_window_check, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), visible_window_check);
g_signal_connect (visible_window_check, "toggled",
G_CALLBACK (event_box_toggle_visible_window), event_box);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (visible_window_check), TRUE);
above_child_check = gtk_check_button_new_with_label("Above Child");
- gtk_box_pack_start (GTK_BOX (box1), above_child_check, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), above_child_check);
g_signal_connect (above_child_check, "toggled",
G_CALLBACK (event_box_toggle_above_child), event_box);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (above_child_check), FALSE);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_button_new_with_label ("close");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);
}
@@ -3502,7 +3489,7 @@ create_size_group_window (GdkScreen *screen,
content_area = gtk_dialog_get_content_area (GTK_DIALOG (window));
grid = gtk_grid_new ();
- gtk_box_pack_start (GTK_BOX (content_area), grid, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), grid);
gtk_grid_set_row_spacing (GTK_GRID (grid), 5);
gtk_grid_set_column_spacing (GTK_GRID (grid), 5);
@@ -3563,17 +3550,17 @@ create_size_group_window (GdkScreen *screen,
g_object_unref (vgroup2);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 5);
- gtk_box_pack_start (GTK_BOX (content_area), hbox, FALSE);
+ gtk_box_pack_start (GTK_BOX (content_area), hbox);
spin_button = gtk_spin_button_new_with_range (1, 100, 1);
gtk_spin_button_set_value (GTK_SPIN_BUTTON (spin_button), SIZE_GROUP_INITIAL_SIZE);
- gtk_box_pack_start (GTK_BOX (hbox), spin_button, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), spin_button);
g_signal_connect (spin_button, "value_changed",
G_CALLBACK (size_group_hsize_changed), main_button);
spin_button = gtk_spin_button_new_with_range (1, 100, 1);
gtk_spin_button_set_value (GTK_SPIN_BUTTON (spin_button), SIZE_GROUP_INITIAL_SIZE);
- gtk_box_pack_start (GTK_BOX (hbox), spin_button, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), spin_button);
g_signal_connect (spin_button, "value_changed",
G_CALLBACK (size_group_vsize_changed), main_button);
@@ -3824,7 +3811,7 @@ create_spins (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (window), main_vbox);
frame = gtk_frame_new ("Not accelerated");
- gtk_box_pack_start (GTK_BOX (main_vbox), frame, TRUE);
+ gtk_box_pack_start (GTK_BOX (main_vbox), frame);
vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
gtk_container_add (GTK_CONTAINER (frame), vbox);
@@ -3832,15 +3819,15 @@ create_spins (GtkWidget *widget)
/* Time, month, hex spinners */
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
- gtk_box_pack_start (GTK_BOX (vbox), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), hbox);
vbox2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
- gtk_box_pack_start (GTK_BOX (hbox), vbox2, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), vbox2);
label = gtk_label_new ("Time :");
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (vbox2), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox2), label);
adjustment = gtk_adjustment_new (0, 0, 1410, 30, 60, 0);
spinner = gtk_spin_button_new (adjustment, 0, 0);
@@ -3851,15 +3838,15 @@ create_spins (GtkWidget *widget)
NULL);
gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (spinner), TRUE);
gtk_entry_set_width_chars (GTK_ENTRY (spinner), 5);
- gtk_box_pack_start (GTK_BOX (vbox2), spinner, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox2), spinner);
vbox2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
- gtk_box_pack_start (GTK_BOX (hbox), vbox2, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), vbox2);
label = gtk_label_new ("Month :");
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (vbox2), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox2), label);
adjustment = gtk_adjustment_new (1.0, 1.0, 12.0, 1.0,
5.0, 0.0);
@@ -3876,15 +3863,15 @@ create_spins (GtkWidget *widget)
NULL);
gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (spinner), TRUE);
gtk_entry_set_width_chars (GTK_ENTRY (spinner), 9);
- gtk_box_pack_start (GTK_BOX (vbox2), spinner, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox2), spinner);
vbox2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
- gtk_box_pack_start (GTK_BOX (hbox), vbox2, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), vbox2);
label = gtk_label_new ("Hex :");
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (vbox2), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox2), label);
adjustment = gtk_adjustment_new (0, 0, 255, 1, 16, 0);
spinner = gtk_spin_button_new (adjustment, 0, 0);
@@ -3899,87 +3886,87 @@ create_spins (GtkWidget *widget)
NULL);
gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (spinner), TRUE);
gtk_entry_set_width_chars (GTK_ENTRY (spinner), 4);
- gtk_box_pack_start (GTK_BOX (vbox2), spinner, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox2), spinner);
frame = gtk_frame_new ("Accelerated");
- gtk_box_pack_start (GTK_BOX (main_vbox), frame, TRUE);
+ gtk_box_pack_start (GTK_BOX (main_vbox), frame);
vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
gtk_container_add (GTK_CONTAINER (frame), vbox);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
- gtk_box_pack_start (GTK_BOX (vbox), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), hbox);
vbox2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
- gtk_box_pack_start (GTK_BOX (hbox), vbox2, FALSE);
+ gtk_box_pack_start (GTK_BOX (hbox), vbox2);
label = gtk_label_new ("Value :");
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (vbox2), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox2), label);
adjustment = gtk_adjustment_new (0.0, -10000.0, 10000.0,
0.5, 100.0, 0.0);
spinner1 = gtk_spin_button_new (adjustment, 1.0, 2);
gtk_spin_button_set_wrap (GTK_SPIN_BUTTON (spinner1), TRUE);
- gtk_box_pack_start (GTK_BOX (vbox2), spinner1, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox2), spinner1);
vbox2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
- gtk_box_pack_start (GTK_BOX (hbox), vbox2, FALSE);
+ gtk_box_pack_start (GTK_BOX (hbox), vbox2);
label = gtk_label_new ("Digits :");
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (vbox2), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox2), label);
adjustment = gtk_adjustment_new (2, 1, 15, 1, 1, 0);
spinner2 = gtk_spin_button_new (adjustment, 0.0, 0);
g_signal_connect (adjustment, "value_changed",
G_CALLBACK (change_digits),
spinner2);
- gtk_box_pack_start (GTK_BOX (vbox2), spinner2, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox2), spinner2);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
- gtk_box_pack_start (GTK_BOX (vbox), hbox, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), hbox);
button = gtk_check_button_new_with_label ("Snap to 0.5-ticks");
g_signal_connect (button, "clicked",
G_CALLBACK (toggle_snap),
spinner1);
- gtk_box_pack_start (GTK_BOX (vbox), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button), TRUE);
button = gtk_check_button_new_with_label ("Numeric only input mode");
g_signal_connect (button, "clicked",
G_CALLBACK (toggle_numeric),
spinner1);
- gtk_box_pack_start (GTK_BOX (vbox), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button), TRUE);
val_label = gtk_label_new ("");
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
- gtk_box_pack_start (GTK_BOX (vbox), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), hbox);
button = gtk_button_new_with_label ("Value as Int");
g_object_set_data (G_OBJECT (button), "user_data", val_label);
g_signal_connect (button, "clicked",
G_CALLBACK (get_value),
GINT_TO_POINTER (1));
- gtk_box_pack_start (GTK_BOX (hbox), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), button);
button = gtk_button_new_with_label ("Value as Float");
g_object_set_data (G_OBJECT (button), "user_data", val_label);
g_signal_connect (button, "clicked",
G_CALLBACK (get_value),
GINT_TO_POINTER (2));
- gtk_box_pack_start (GTK_BOX (hbox), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), button);
- gtk_box_pack_start (GTK_BOX (vbox), val_label, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), val_label);
gtk_label_set_text (GTK_LABEL (val_label), "0");
frame = gtk_frame_new ("Using Convenience Constructor");
- gtk_box_pack_start (GTK_BOX (main_vbox), frame, TRUE);
+ gtk_box_pack_start (GTK_BOX (main_vbox), frame);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
gtk_container_add (GTK_CONTAINER (frame), hbox);
@@ -3990,17 +3977,17 @@ create_spins (GtkWidget *widget)
gtk_spin_button_set_value (GTK_SPIN_BUTTON (spinner), 0.0);
g_signal_connect (spinner, "value_changed",
G_CALLBACK (get_spin_value), val_label);
- gtk_box_pack_start (GTK_BOX (hbox), spinner, TRUE);
- gtk_box_pack_start (GTK_BOX (hbox), val_label, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), spinner);
+ gtk_box_pack_start (GTK_BOX (hbox), val_label);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
- gtk_box_pack_start (GTK_BOX (main_vbox), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (main_vbox), hbox);
button = gtk_button_new_with_label ("Close");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (hbox), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), button);
}
if (!gtk_widget_get_visible (window))
@@ -4304,21 +4291,21 @@ create_cursors (GtkWidget *widget)
guint w, h;
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
- gtk_box_pack_start (GTK_BOX (vbox), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), hbox);
label = gtk_label_new ("Cursor Theme:");
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (hbox), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), label);
entry = gtk_entry_new ();
gtk_entry_set_text (GTK_ENTRY (entry), "default");
- gtk_box_pack_start (GTK_BOX (hbox), entry, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), entry);
gdk_display_get_maximal_cursor_size (gtk_widget_get_display (vbox), &w, &h);
size = gtk_spin_button_new_with_range (1.0, MIN (w, h), 1.0);
gtk_spin_button_set_value (GTK_SPIN_BUTTON (size), 24.0);
- gtk_box_pack_start (GTK_BOX (hbox), size, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), size);
g_signal_connect (entry, "changed",
G_CALLBACK (change_cursor_theme), hbox);
@@ -4327,12 +4314,12 @@ create_cursors (GtkWidget *widget)
}
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
- gtk_box_pack_start (GTK_BOX (vbox), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), hbox);
label = gtk_label_new ("Cursor Name:");
gtk_widget_set_halign (label, GTK_ALIGN_START);
gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (hbox), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), label);
entry = gtk_entry_new ();
completion = gtk_entry_completion_new ();
@@ -4341,7 +4328,7 @@ create_cursors (GtkWidget *widget)
gtk_entry_completion_set_text_column (completion, 0);
gtk_entry_set_completion (GTK_ENTRY (entry), completion);
g_object_unref (model);
- gtk_box_pack_start (GTK_BOX (hbox), entry, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), entry);
frame =
g_object_new (gtk_frame_get_type (),
@@ -4368,16 +4355,16 @@ create_cursors (GtkWidget *widget)
any = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (main_vbox), any, TRUE);
+ gtk_box_pack_start (GTK_BOX (main_vbox), any);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
- gtk_box_pack_start (GTK_BOX (main_vbox), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (main_vbox), hbox);
button = gtk_button_new_with_label ("Close");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (hbox), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), button);
gtk_widget_show (window);
@@ -4531,7 +4518,7 @@ create_flipping (GtkWidget *widget)
gtk_window_set_title (GTK_WINDOW (window), "Bidirectional Flipping");
check_button = gtk_check_button_new_with_label ("Right-to-left global direction");
- gtk_box_pack_start (GTK_BOX (content_area), check_button, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), check_button);
if (gtk_widget_get_default_direction () == GTK_TEXT_DIR_RTL)
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (check_button), TRUE);
@@ -4540,22 +4527,19 @@ create_flipping (GtkWidget *widget)
G_CALLBACK (flipping_toggled_cb), NULL);
check_button = gtk_check_button_new_with_label ("Toggle orientation of all boxes");
- gtk_box_pack_start (GTK_BOX (content_area), check_button, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), check_button);
g_signal_connect (check_button, "toggled",
G_CALLBACK (flipping_orientation_toggled_cb), NULL);
gtk_box_pack_start (GTK_BOX (content_area),
- create_forward_back ("Default", GTK_TEXT_DIR_NONE),
- TRUE);
+ create_forward_back ("Default", GTK_TEXT_DIR_NONE));
gtk_box_pack_start (GTK_BOX (content_area),
- create_forward_back ("Left-to-Right", GTK_TEXT_DIR_LTR),
- TRUE);
+ create_forward_back ("Left-to-Right", GTK_TEXT_DIR_LTR));
gtk_box_pack_start (GTK_BOX (content_area),
- create_forward_back ("Right-to-Left", GTK_TEXT_DIR_RTL),
- TRUE);
+ create_forward_back ("Right-to-Left", GTK_TEXT_DIR_RTL));
gtk_dialog_add_button (GTK_DIALOG (window), "Close", GTK_RESPONSE_CLOSE);
g_signal_connect (window, "response", G_CALLBACK (gtk_widget_destroy), NULL);
@@ -4642,7 +4626,7 @@ create_focus (GtkWidget *widget)
frame = gtk_frame_new ("Weird tab focus chain");
- gtk_box_pack_start (GTK_BOX (content_area), frame, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), frame);
table = make_focus_table (&list);
@@ -4655,7 +4639,7 @@ create_focus (GtkWidget *widget)
frame = gtk_frame_new ("Default tab focus chain");
- gtk_box_pack_start (GTK_BOX (content_area), frame, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), frame);
list = NULL;
table = make_focus_table (&list);
@@ -4747,7 +4731,7 @@ dialog_response_cb (GtkWidget *widget, gint response, gpointer unused)
label = gtk_label_new ("Dialog Test");
g_object_set (label, "margin", 10, NULL);
gtk_box_pack_start (GTK_BOX (content_area),
- label, TRUE);
+ label);
gtk_widget_show (label);
}
@@ -5002,7 +4986,7 @@ create_event_watcher (GtkWidget *widget)
g_signal_connect (button, "clicked",
G_CALLBACK (event_watcher_toggle),
NULL);
- gtk_box_pack_start (GTK_BOX (content_area), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), button);
gtk_widget_show (button);
gtk_dialog_add_button (GTK_DIALOG (dialog_window), "Close", GTK_RESPONSE_CLOSE);
@@ -5060,7 +5044,7 @@ create_range_controls (GtkWidget *widget)
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
gtk_widget_show (box2);
@@ -5070,11 +5054,11 @@ create_range_controls (GtkWidget *widget)
gtk_widget_set_size_request (GTK_WIDGET (scale), 150, -1);
gtk_scale_set_digits (GTK_SCALE (scale), 1);
gtk_scale_set_draw_value (GTK_SCALE (scale), TRUE);
- gtk_box_pack_start (GTK_BOX (box2), scale, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), scale);
gtk_widget_show (scale);
scrollbar = gtk_scrollbar_new (GTK_ORIENTATION_HORIZONTAL, GTK_ADJUSTMENT (adjustment));
- gtk_box_pack_start (GTK_BOX (box2), scrollbar, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), scrollbar);
gtk_widget_show (scrollbar);
scale = gtk_scale_new (GTK_ORIENTATION_HORIZONTAL, GTK_ADJUSTMENT (adjustment));
@@ -5083,7 +5067,7 @@ create_range_controls (GtkWidget *widget)
"format_value",
G_CALLBACK (reformat_value),
NULL);
- gtk_box_pack_start (GTK_BOX (box2), scale, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), scale);
gtk_widget_show (scale);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
@@ -5092,7 +5076,7 @@ create_range_controls (GtkWidget *widget)
gtk_widget_set_size_request (scale, -1, 200);
gtk_scale_set_digits (GTK_SCALE (scale), 2);
gtk_scale_set_draw_value (GTK_SCALE (scale), TRUE);
- gtk_box_pack_start (GTK_BOX (hbox), scale, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), scale);
gtk_widget_show (scale);
scale = gtk_scale_new (GTK_ORIENTATION_VERTICAL, GTK_ADJUSTMENT (adjustment));
@@ -5100,7 +5084,7 @@ create_range_controls (GtkWidget *widget)
gtk_scale_set_digits (GTK_SCALE (scale), 2);
gtk_scale_set_draw_value (GTK_SCALE (scale), TRUE);
gtk_range_set_inverted (GTK_RANGE (scale), TRUE);
- gtk_box_pack_start (GTK_BOX (hbox), scale, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), scale);
gtk_widget_show (scale);
scale = gtk_scale_new (GTK_ORIENTATION_VERTICAL, GTK_ADJUSTMENT (adjustment));
@@ -5109,20 +5093,20 @@ create_range_controls (GtkWidget *widget)
"format_value",
G_CALLBACK (reformat_value),
NULL);
- gtk_box_pack_start (GTK_BOX (hbox), scale, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), scale);
gtk_widget_show (scale);
- gtk_box_pack_start (GTK_BOX (box2), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), hbox);
gtk_widget_show (hbox);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
gtk_widget_show (separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
gtk_widget_show (box2);
@@ -5130,7 +5114,7 @@ create_range_controls (GtkWidget *widget)
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);
gtk_widget_show (button);
@@ -5272,21 +5256,21 @@ create_pages (GtkNotebook *notebook, gint start, gint end)
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
gtk_box_set_homogeneous (GTK_BOX (hbox), TRUE);
- gtk_box_pack_start (GTK_BOX (vbox), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), hbox);
button = gtk_check_button_new_with_label ("Fill Tab");
- gtk_box_pack_start (GTK_BOX (hbox), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), button);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button), TRUE);
g_signal_connect (button, "toggled",
G_CALLBACK (tab_fill), child);
button = gtk_check_button_new_with_label ("Expand Tab");
- gtk_box_pack_start (GTK_BOX (hbox), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), button);
g_signal_connect (button, "toggled",
G_CALLBACK (tab_expand), child);
button = gtk_button_new_with_label ("Hide Page");
- gtk_box_pack_end (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), button);
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_hide),
child);
@@ -5297,13 +5281,13 @@ create_pages (GtkNotebook *notebook, gint start, gint end)
pixwid = gtk_image_new_from_pixbuf (book_closed);
g_object_set_data (G_OBJECT (child), "tab_pixmap", pixwid);
- gtk_box_pack_start (GTK_BOX (label_box), pixwid, TRUE);
+ gtk_box_pack_start (GTK_BOX (label_box), pixwid);
gtk_widget_set_margin_start (pixwid, 3);
gtk_widget_set_margin_end (pixwid, 3);
gtk_widget_set_margin_bottom (pixwid, 1);
gtk_widget_set_margin_top (pixwid, 1);
label = gtk_label_new_with_mnemonic (accel_buffer);
- gtk_box_pack_start (GTK_BOX (label_box), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (label_box), label);
gtk_widget_show (label_box);
@@ -5311,13 +5295,13 @@ create_pages (GtkNotebook *notebook, gint start, gint end)
pixwid = gtk_image_new_from_pixbuf (book_closed);
g_object_set_data (G_OBJECT (child), "menu_pixmap", pixwid);
- gtk_box_pack_start (GTK_BOX (menu_box), pixwid, TRUE);
+ gtk_box_pack_start (GTK_BOX (menu_box), pixwid);
gtk_widget_set_margin_start (pixwid, 3);
gtk_widget_set_margin_end (pixwid, 3);
gtk_widget_set_margin_bottom (pixwid, 1);
gtk_widget_set_margin_top (pixwid, 1);
label = gtk_label_new (buffer);
- gtk_box_pack_start (GTK_BOX (menu_box), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (menu_box), label);
gtk_widget_show (menu_box);
gtk_notebook_append_page_menu (notebook, child, label_box, menu_box);
@@ -5443,7 +5427,7 @@ create_notebook (GtkWidget *widget)
g_signal_connect (sample_notebook, "switch_page",
G_CALLBACK (page_switch), NULL);
gtk_notebook_set_tab_pos (GTK_NOTEBOOK (sample_notebook), GTK_POS_TOP);
- gtk_box_pack_start (GTK_BOX (box1), sample_notebook, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), sample_notebook);
gtk_widget_realize (sample_notebook);
@@ -5456,62 +5440,62 @@ create_notebook (GtkWidget *widget)
create_pages (GTK_NOTEBOOK (sample_notebook), 1, 5);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
box2 = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 5);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_check_button_new_with_label ("popup menu");
- gtk_box_pack_start (GTK_BOX (box2), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
g_signal_connect (button, "clicked",
G_CALLBACK (notebook_popup),
sample_notebook);
box2 = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 5);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
label = gtk_label_new ("Notebook Style :");
- gtk_box_pack_start (GTK_BOX (box2), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), label);
omenu = build_option_menu (items, G_N_ELEMENTS (items), 0,
notebook_type_changed,
sample_notebook);
- gtk_box_pack_start (GTK_BOX (box2), omenu, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), omenu);
button = gtk_button_new_with_label ("Show all Pages");
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
g_signal_connect (button, "clicked",
G_CALLBACK (show_all_pages), sample_notebook);
box2 = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 10);
gtk_box_set_homogeneous (GTK_BOX (box2), TRUE);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_button_new_with_label ("prev");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_notebook_prev_page),
sample_notebook);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
button = gtk_button_new_with_label ("next");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_notebook_next_page),
sample_notebook);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
button = gtk_button_new_with_label ("rotate");
g_signal_connect (button, "clicked",
G_CALLBACK (rotate_notebook), sample_notebook);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
button = gtk_button_new_with_label ("close");
g_signal_connect_swapped (button, "clicked",
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (box1), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (box1), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);
}
@@ -5634,7 +5618,7 @@ create_panes (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (window), vbox);
vpaned = gtk_paned_new (GTK_ORIENTATION_VERTICAL);
- gtk_box_pack_start (GTK_BOX (vbox), vpaned, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), vpaned);
hpaned = gtk_paned_new (GTK_ORIENTATION_HORIZONTAL);
gtk_paned_add1 (GTK_PANED (vpaned), hpaned);
@@ -5663,15 +5647,13 @@ create_panes (GtkWidget *widget)
create_pane_options (GTK_PANED (hpaned),
"Horizontal",
"Left",
- "Right"),
- FALSE);
+ "Right"));
gtk_box_pack_start (GTK_BOX (vbox),
create_pane_options (GTK_PANED (vpaned),
"Vertical",
"Top",
- "Bottom"),
- FALSE);
+ "Bottom"));
gtk_widget_show (vbox);
}
@@ -5726,13 +5708,13 @@ paned_keyboard_window1 (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (frame1), vbox1);
button7 = gtk_button_new_with_label ("button7");
- gtk_box_pack_start (GTK_BOX (vbox1), button7, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox1), button7);
button8 = gtk_button_new_with_label ("button8");
- gtk_box_pack_start (GTK_BOX (vbox1), button8, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox1), button8);
button9 = gtk_button_new_with_label ("button9");
- gtk_box_pack_start (GTK_BOX (vbox1), button9, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox1), button9);
vpaned1 = gtk_paned_new (GTK_ORIENTATION_VERTICAL);
gtk_paned_pack2 (GTK_PANED (hpaned1), vpaned1, TRUE, TRUE);
@@ -5748,10 +5730,10 @@ paned_keyboard_window1 (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (frame5), hbox1);
button5 = gtk_button_new_with_label ("button5");
- gtk_box_pack_start (GTK_BOX (hbox1), button5, FALSE);
+ gtk_box_pack_start (GTK_BOX (hbox1), button5);
button6 = gtk_button_new_with_label ("button6");
- gtk_box_pack_start (GTK_BOX (hbox1), button6, FALSE);
+ gtk_box_pack_start (GTK_BOX (hbox1), button6);
frame3 = gtk_frame_new (NULL);
gtk_paned_pack2 (GTK_PANED (vpaned1), frame3, TRUE, TRUE);
@@ -5813,7 +5795,7 @@ paned_keyboard_window2 (GtkWidget *widget)
gtk_paned_pack2 (GTK_PANED (hpaned2), hbox2, TRUE, TRUE);
vpaned2 = gtk_paned_new (GTK_ORIENTATION_VERTICAL);
- gtk_box_pack_start (GTK_BOX (hbox2), vpaned2, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox2), vpaned2);
frame7 = gtk_frame_new (NULL);
gtk_paned_pack1 (GTK_PANED (vpaned2), frame7, FALSE, TRUE);
@@ -5830,7 +5812,7 @@ paned_keyboard_window2 (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (frame8), button11);
button10 = gtk_button_new_with_label ("button10");
- gtk_box_pack_start (GTK_BOX (hbox2), button10, FALSE);
+ gtk_box_pack_start (GTK_BOX (hbox2), button10);
return window2;
}
@@ -5865,10 +5847,10 @@ paned_keyboard_window3 (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (window3), vbox2);
label1 = gtk_label_new ("Three panes nested inside each other");
- gtk_box_pack_start (GTK_BOX (vbox2), label1, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox2), label1);
hpaned3 = gtk_paned_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (vbox2), hpaned3, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox2), hpaned3);
frame9 = gtk_frame_new (NULL);
gtk_paned_pack1 (GTK_PANED (hpaned3), frame9, FALSE, TRUE);
@@ -5939,11 +5921,11 @@ paned_keyboard_window4 (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (window4), vbox3);
label2 = gtk_label_new ("Widget tree:\n\nhpaned \n - vpaned\n - hbox\n - vpaned\n - vpaned\n - vpaned\n");
- gtk_box_pack_start (GTK_BOX (vbox3), label2, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox3), label2);
gtk_label_set_justify (GTK_LABEL (label2), GTK_JUSTIFY_LEFT);
hpaned6 = gtk_paned_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (vbox3), hpaned6, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox3), hpaned6);
vpaned3 = gtk_paned_new (GTK_ORIENTATION_VERTICAL);
gtk_paned_pack1 (GTK_PANED (hpaned6), vpaned3, FALSE, TRUE);
@@ -5958,7 +5940,7 @@ paned_keyboard_window4 (GtkWidget *widget)
gtk_paned_pack2 (GTK_PANED (hpaned6), hbox3, TRUE, TRUE);
vpaned4 = gtk_paned_new (GTK_ORIENTATION_VERTICAL);
- gtk_box_pack_start (GTK_BOX (hbox3), vpaned4, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox3), vpaned4);
button21 = gtk_button_new_with_label ("button21");
gtk_paned_pack1 (GTK_PANED (vpaned4), button21, FALSE, TRUE);
@@ -5967,7 +5949,7 @@ paned_keyboard_window4 (GtkWidget *widget)
gtk_paned_pack2 (GTK_PANED (vpaned4), button20, TRUE, TRUE);
vpaned5 = gtk_paned_new (GTK_ORIENTATION_VERTICAL);
- gtk_box_pack_start (GTK_BOX (hbox3), vpaned5, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox3), vpaned5);
button23 = gtk_button_new_with_label ("button23");
gtk_paned_pack1 (GTK_PANED (vpaned5), button23, FALSE, TRUE);
@@ -5976,7 +5958,7 @@ paned_keyboard_window4 (GtkWidget *widget)
gtk_paned_pack2 (GTK_PANED (vpaned5), button22, TRUE, TRUE);
vpaned6 = gtk_paned_new (GTK_ORIENTATION_VERTICAL);
- gtk_box_pack_start (GTK_BOX (hbox3), vpaned6, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox3), vpaned6);
button25 = gtk_button_new_with_label ("button25");
gtk_paned_pack1 (GTK_PANED (vpaned6), button25, FALSE, TRUE);
@@ -6339,17 +6321,17 @@ create_wmhints (GtkWidget *widget)
label = gtk_label_new ("Try iconizing me!");
gtk_widget_set_size_request (label, 150, 50);
- gtk_box_pack_start (GTK_BOX (box1), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), label);
gtk_widget_show (label);
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
gtk_widget_show (separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
gtk_widget_show (box2);
@@ -6359,7 +6341,7 @@ create_wmhints (GtkWidget *widget)
G_CALLBACK (gtk_widget_destroy),
window);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);
gtk_widget_show (button);
@@ -6425,7 +6407,7 @@ tracking_label (GtkWidget *window)
label = gtk_label_new ("<no window state events received>");
gtk_label_set_line_wrap (GTK_LABEL (label), TRUE);
- gtk_box_pack_start (GTK_BOX (hbox), label, FALSE);
+ gtk_box_pack_start (GTK_BOX (hbox), label);
g_signal_connect (window,
"window_state_event",
@@ -6438,7 +6420,7 @@ tracking_label (GtkWidget *window)
G_CALLBACK (gtk_window_deiconify),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_end (GTK_BOX (hbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (hbox), button);
button = gtk_button_new_with_label ("Iconify");
g_signal_connect_object (button,
@@ -6446,7 +6428,7 @@ tracking_label (GtkWidget *window)
G_CALLBACK (gtk_window_iconify),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_end (GTK_BOX (hbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (hbox), button);
button = gtk_button_new_with_label ("Fullscreen");
g_signal_connect_object (button,
@@ -6454,7 +6436,7 @@ tracking_label (GtkWidget *window)
G_CALLBACK (gtk_window_fullscreen),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_end (GTK_BOX (hbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (hbox), button);
button = gtk_button_new_with_label ("Unfullscreen");
g_signal_connect_object (button,
@@ -6462,7 +6444,7 @@ tracking_label (GtkWidget *window)
G_CALLBACK (gtk_window_unfullscreen),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_end (GTK_BOX (hbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (hbox), button);
button = gtk_button_new_with_label ("Present");
g_signal_connect_object (button,
@@ -6470,7 +6452,7 @@ tracking_label (GtkWidget *window)
G_CALLBACK (gtk_window_present),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_end (GTK_BOX (hbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (hbox), button);
button = gtk_button_new_with_label ("Show");
g_signal_connect_object (button,
@@ -6478,7 +6460,7 @@ tracking_label (GtkWidget *window)
G_CALLBACK (gtk_widget_show),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_end (GTK_BOX (hbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (hbox), button);
gtk_widget_show (hbox);
@@ -6526,7 +6508,7 @@ get_state_controls (GtkWidget *window)
G_CALLBACK (gtk_window_stick),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_start (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Unstick");
g_signal_connect_object (button,
@@ -6534,7 +6516,7 @@ get_state_controls (GtkWidget *window)
G_CALLBACK (gtk_window_unstick),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_start (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Maximize");
g_signal_connect_object (button,
@@ -6542,7 +6524,7 @@ get_state_controls (GtkWidget *window)
G_CALLBACK (gtk_window_maximize),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_start (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Unmaximize");
g_signal_connect_object (button,
@@ -6550,7 +6532,7 @@ get_state_controls (GtkWidget *window)
G_CALLBACK (gtk_window_unmaximize),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_start (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Iconify");
g_signal_connect_object (button,
@@ -6558,7 +6540,7 @@ get_state_controls (GtkWidget *window)
G_CALLBACK (gtk_window_iconify),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_start (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Fullscreen");
g_signal_connect_object (button,
@@ -6566,7 +6548,7 @@ get_state_controls (GtkWidget *window)
G_CALLBACK (gtk_window_fullscreen),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_start (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Unfullscreen");
g_signal_connect_object (button,
@@ -6574,21 +6556,21 @@ get_state_controls (GtkWidget *window)
G_CALLBACK (gtk_window_unfullscreen),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_start (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
button_above = gtk_toggle_button_new_with_label ("Keep above");
g_signal_connect (button_above,
"toggled",
G_CALLBACK (keep_window_above),
window);
- gtk_box_pack_start (GTK_BOX (vbox), button_above, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button_above);
button_below = gtk_toggle_button_new_with_label ("Keep below");
g_signal_connect (button_below,
"toggled",
G_CALLBACK (keep_window_below),
window);
- gtk_box_pack_start (GTK_BOX (vbox), button_below, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button_below);
g_object_set_data (G_OBJECT (button_above), "radio", button_below);
g_object_set_data (G_OBJECT (button_below), "radio", button_above);
@@ -6599,7 +6581,7 @@ get_state_controls (GtkWidget *window)
G_CALLBACK (gtk_widget_hide),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_start (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
gtk_widget_show (vbox);
@@ -6853,7 +6835,7 @@ window_controls (GtkWidget *window)
gtk_container_add (GTK_CONTAINER (control_window), vbox);
label = gtk_label_new ("<no configure events>");
- gtk_box_pack_start (GTK_BOX (vbox), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), label);
g_signal_connect (window,
"configure_event",
@@ -6863,14 +6845,14 @@ window_controls (GtkWidget *window)
adjustment = gtk_adjustment_new (10.0, -2000.0, 2000.0, 1.0, 5.0, 0.0);
spin = gtk_spin_button_new (adjustment, 0, 0);
- gtk_box_pack_start (GTK_BOX (vbox), spin, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), spin);
g_object_set_data (G_OBJECT (control_window), "spin1", spin);
adjustment = gtk_adjustment_new (10.0, -2000.0, 2000.0, 1.0, 5.0, 0.0);
spin = gtk_spin_button_new (adjustment, 0, 0);
- gtk_box_pack_start (GTK_BOX (vbox), spin, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), spin);
g_object_set_data (G_OBJECT (control_window), "spin2", spin);
@@ -6880,56 +6862,56 @@ window_controls (GtkWidget *window)
G_CALLBACK (gtk_widget_queue_resize),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_end (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Resize");
g_signal_connect (button,
"clicked",
G_CALLBACK (set_size_callback),
control_window);
- gtk_box_pack_end (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Set default size");
g_signal_connect (button,
"clicked",
G_CALLBACK (set_default_size_callback),
control_window);
- gtk_box_pack_end (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Unset default size");
g_signal_connect (button,
"clicked",
G_CALLBACK (unset_default_size_callback),
control_window);
- gtk_box_pack_end (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Set size request");
g_signal_connect (button,
"clicked",
G_CALLBACK (set_size_request_callback),
control_window);
- gtk_box_pack_end (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Unset size request");
g_signal_connect (button,
"clicked",
G_CALLBACK (unset_size_request_callback),
control_window);
- gtk_box_pack_end (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Move");
g_signal_connect (button,
"clicked",
G_CALLBACK (set_location_callback),
control_window);
- gtk_box_pack_end (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), button);
button = gtk_button_new_with_label ("Move to current position");
g_signal_connect (button,
"clicked",
G_CALLBACK (move_to_position_callback),
control_window);
- gtk_box_pack_end (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), button);
button = gtk_check_button_new_with_label ("Allow resize");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (button), TRUE);
@@ -6937,7 +6919,7 @@ window_controls (GtkWidget *window)
"toggled",
G_CALLBACK (resizable_callback),
control_window);
- gtk_box_pack_end (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), button);
button = gtk_button_new_with_mnemonic ("_Show");
g_signal_connect_object (button,
@@ -6945,7 +6927,7 @@ window_controls (GtkWidget *window)
G_CALLBACK (gtk_widget_show),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_end (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), button);
button = gtk_button_new_with_mnemonic ("_Hide");
g_signal_connect_object (button,
@@ -6953,7 +6935,7 @@ window_controls (GtkWidget *window)
G_CALLBACK (gtk_widget_hide),
window,
G_CONNECT_SWAPPED);
- gtk_box_pack_end (GTK_BOX (vbox), button, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), button);
om = gtk_combo_box_text_new ();
i = 0;
@@ -6984,7 +6966,7 @@ window_controls (GtkWidget *window)
G_CALLBACK (gravity_selected),
control_window);
- gtk_box_pack_end (GTK_BOX (vbox), om, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), om);
om = gtk_combo_box_text_new ();
@@ -7011,7 +6993,7 @@ window_controls (GtkWidget *window)
G_CALLBACK (pos_selected),
control_window);
- gtk_box_pack_end (GTK_BOX (vbox), om, FALSE);
+ gtk_box_pack_end (GTK_BOX (vbox), om);
gtk_widget_show (vbox);
@@ -7249,10 +7231,10 @@ create_progress_bar (GtkWidget *widget)
gtk_window_set_title (GTK_WINDOW (pdata->window), "GtkProgressBar");
vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5);
- gtk_box_pack_start (GTK_BOX (content_area), vbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), vbox);
frame = gtk_frame_new ("Progress");
- gtk_box_pack_start (GTK_BOX (vbox), frame, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
vbox2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5);
gtk_container_add (GTK_CONTAINER (frame), vbox2);
@@ -7262,19 +7244,19 @@ create_progress_bar (GtkWidget *widget)
PANGO_ELLIPSIZE_MIDDLE);
gtk_widget_set_halign (pdata->pbar, GTK_ALIGN_CENTER);
gtk_widget_set_valign (pdata->pbar, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (vbox2), pdata->pbar, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox2), pdata->pbar);
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 5);
gtk_widget_set_halign (hbox, GTK_ALIGN_CENTER);
gtk_widget_set_valign (hbox, GTK_ALIGN_CENTER);
- gtk_box_pack_start (GTK_BOX (vbox2), hbox, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox2), hbox);
label = gtk_label_new ("Label updated by user :");
- gtk_box_pack_start (GTK_BOX (hbox), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), label);
pdata->label = gtk_label_new ("");
- gtk_box_pack_start (GTK_BOX (hbox), pdata->label, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), pdata->label);
frame = gtk_frame_new ("Options");
- gtk_box_pack_start (GTK_BOX (vbox), frame, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), frame);
vbox2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5);
gtk_container_add (GTK_CONTAINER (frame), vbox2);
@@ -7282,7 +7264,7 @@ create_progress_bar (GtkWidget *widget)
grid = gtk_grid_new ();
gtk_grid_set_row_spacing (GTK_GRID (grid), 10);
gtk_grid_set_column_spacing (GTK_GRID (grid), 10);
- gtk_box_pack_start (GTK_BOX (vbox2), grid, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox2), grid);
label = gtk_label_new ("Orientation :");
gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 1, 1);
@@ -7311,14 +7293,14 @@ create_progress_bar (GtkWidget *widget)
gtk_grid_attach (GTK_GRID (grid), hbox, 1, 2, 1, 1);
label = gtk_label_new ("Text: ");
- gtk_box_pack_start (GTK_BOX (hbox), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), label);
pdata->entry = gtk_entry_new ();
gtk_widget_set_hexpand (pdata->entry, TRUE);
g_signal_connect (pdata->entry, "changed",
G_CALLBACK (entry_changed),
pdata);
- gtk_box_pack_start (GTK_BOX (hbox), pdata->entry, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), pdata->entry);
gtk_widget_set_size_request (pdata->entry, 100, -1);
label = gtk_label_new ("Ellipsize text :");
@@ -7641,14 +7623,14 @@ create_snapshot (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (window), vbox);
button = gtk_button_new_with_label ("Snapshot widget");
- gtk_box_pack_start (GTK_BOX (vbox), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
g_signal_connect (button, "clicked",
G_CALLBACK (snapshot_widget),
data);
button = gtk_button_new_with_label ("Snapshot toplevel");
data->toplevel_button = button;
- gtk_box_pack_start (GTK_BOX (vbox), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), button);
g_signal_connect (button, "clicked",
G_CALLBACK (snapshot_widget),
data);
@@ -7763,16 +7745,16 @@ create_selection_test (GtkWidget *widget)
/* Create the list */
vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5);
- gtk_box_pack_start (GTK_BOX (content_area), vbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), vbox);
label = gtk_label_new ("Gets available targets for current selection");
- gtk_box_pack_start (GTK_BOX (vbox), label, FALSE);
+ gtk_box_pack_start (GTK_BOX (vbox), label);
scrolled_win = gtk_scrolled_window_new (NULL, NULL);
gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolled_win),
GTK_POLICY_AUTOMATIC,
GTK_POLICY_AUTOMATIC);
- gtk_box_pack_start (GTK_BOX (vbox), scrolled_win, TRUE);
+ gtk_box_pack_start (GTK_BOX (vbox), scrolled_win);
gtk_widget_set_size_request (scrolled_win, 100, 200);
store = gtk_list_store_new (1, G_TYPE_STRING);
@@ -7911,12 +7893,12 @@ create_scroll_test (GtkWidget *widget)
gtk_window_set_title (GTK_WINDOW (window), "Scroll Test");
hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
- gtk_box_pack_start (GTK_BOX (content_area), hbox, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), hbox);
gtk_widget_show (hbox);
drawing_area = gtk_drawing_area_new ();
gtk_widget_set_size_request (drawing_area, 200, 200);
- gtk_box_pack_start (GTK_BOX (hbox), drawing_area, TRUE);
+ gtk_box_pack_start (GTK_BOX (hbox), drawing_area);
gtk_widget_show (drawing_area);
gtk_widget_set_events (drawing_area, GDK_EXPOSURE_MASK | GDK_SCROLL_MASK);
@@ -7925,7 +7907,7 @@ create_scroll_test (GtkWidget *widget)
scroll_test_pos = 0.0;
scrollbar = gtk_scrollbar_new (GTK_ORIENTATION_VERTICAL, adjustment);
- gtk_box_pack_start (GTK_BOX (hbox), scrollbar, FALSE);
+ gtk_box_pack_start (GTK_BOX (hbox), scrollbar);
gtk_widget_show (scrollbar);
g_signal_connect (drawing_area, "draw",
@@ -8029,7 +8011,7 @@ create_timeout_test (GtkWidget *widget)
label = gtk_label_new ("count: 0");
g_object_set (label, "margin", 10, NULL);
- gtk_box_pack_start (GTK_BOX (content_area), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), label);
gtk_widget_show (label);
button = gtk_button_new_with_label ("close");
@@ -8037,7 +8019,7 @@ create_timeout_test (GtkWidget *widget)
G_CALLBACK (gtk_widget_destroy),
window);
gtk_widget_set_can_default (button, TRUE);
- gtk_box_pack_start (GTK_BOX (action_area), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (action_area), button);
gtk_widget_grab_default (button);
gtk_widget_show (button);
@@ -8046,7 +8028,7 @@ create_timeout_test (GtkWidget *widget)
G_CALLBACK(start_timeout_test),
label);
gtk_widget_set_can_default (button, TRUE);
- gtk_box_pack_start (GTK_BOX (action_area), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (action_area), button);
gtk_widget_show (button);
button = gtk_button_new_with_label ("stop");
@@ -8054,7 +8036,7 @@ create_timeout_test (GtkWidget *widget)
G_CALLBACK (stop_timeout_test),
NULL);
gtk_widget_set_can_default (button, TRUE);
- gtk_box_pack_start (GTK_BOX (action_area), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (action_area), button);
gtk_widget_show (button);
}
@@ -8100,7 +8082,7 @@ create_mainloop (GtkWidget *widget)
label = gtk_label_new ("In recursive main loop...");
g_object_set (label, "margin", 20, NULL);
- gtk_box_pack_start (GTK_BOX (content_area), label, TRUE);
+ gtk_box_pack_start (GTK_BOX (content_area), label);
gtk_widget_show (label);
gtk_dialog_add_button (GTK_DIALOG (window),
@@ -8528,7 +8510,7 @@ create_native_dialogs (GtkWidget *widget)
gtk_container_add (GTK_CONTAINER (window), box);
label = gtk_label_new ("");
- gtk_box_pack_start (GTK_BOX (box), label, FALSE);
+ gtk_box_pack_start (GTK_BOX (box), label);
combo = gtk_combo_box_text_new ();
@@ -8541,7 +8523,7 @@ create_native_dialogs (GtkWidget *widget)
g_signal_connect (combo, "changed",
G_CALLBACK (native_action_changed), native);
gtk_combo_box_set_active (GTK_COMBO_BOX (combo), GTK_FILE_CHOOSER_ACTION_OPEN);
- gtk_box_pack_start (GTK_BOX (box), combo, FALSE);
+ gtk_box_pack_start (GTK_BOX (box), combo);
combo = gtk_combo_box_text_new ();
@@ -8552,34 +8534,34 @@ create_native_dialogs (GtkWidget *widget)
g_signal_connect (combo, "changed",
G_CALLBACK (native_filter_changed), native);
gtk_combo_box_set_active (GTK_COMBO_BOX (combo), 0);
- gtk_box_pack_start (GTK_BOX (box), combo, FALSE);
+ gtk_box_pack_start (GTK_BOX (box), combo);
check_button = gtk_check_button_new_with_label ("Modal");
g_signal_connect (check_button, "toggled",
G_CALLBACK (native_modal_toggle), native);
- gtk_box_pack_start (GTK_BOX (box), check_button, FALSE);
+ gtk_box_pack_start (GTK_BOX (box), check_button);
check_button = gtk_check_button_new_with_label ("Multiple select");
g_signal_connect (check_button, "toggled",
G_CALLBACK (native_multi_select_toggle), native);
- gtk_box_pack_start (GTK_BOX (box), check_button, FALSE);
+ gtk_box_pack_start (GTK_BOX (box), check_button);
check_button = gtk_check_button_new_with_label ("Confirm overwrite");
g_signal_connect (check_button, "toggled",
G_CALLBACK (native_overwrite_confirmation_toggle), native);
- gtk_box_pack_start (GTK_BOX (box), check_button, FALSE);
+ gtk_box_pack_start (GTK_BOX (box), check_button);
check_button = gtk_check_button_new_with_label ("Extra widget");
g_signal_connect (check_button, "toggled",
G_CALLBACK (native_extra_widget_toggle), native);
- gtk_box_pack_start (GTK_BOX (box), check_button, FALSE);
+ gtk_box_pack_start (GTK_BOX (box), check_button);
show_button = gtk_button_new_with_label ("Show");
hide_button = gtk_button_new_with_label ("Hide");
gtk_widget_set_sensitive (hide_button, FALSE);
- gtk_box_pack_start (GTK_BOX (box), show_button, FALSE);
- gtk_box_pack_start (GTK_BOX (box), hide_button, FALSE);
+ gtk_box_pack_start (GTK_BOX (box), show_button);
+ gtk_box_pack_start (GTK_BOX (box), hide_button);
/* connect signals */
g_signal_connect (native, "response",
@@ -8717,14 +8699,14 @@ create_main_window (void)
gtk_get_minor_version ());
label = gtk_label_new (buffer);
- gtk_box_pack_start (GTK_BOX (box1), label, FALSE);
+ gtk_box_pack_start (GTK_BOX (box1), label);
gtk_widget_set_name (label, "testgtk-version-label");
scrolled_window = gtk_scrolled_window_new (NULL, NULL);
gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolled_window),
GTK_POLICY_NEVER,
GTK_POLICY_AUTOMATIC);
- gtk_box_pack_start (GTK_BOX (box1), scrolled_window, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), scrolled_window);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
gtk_container_add (GTK_CONTAINER (scrolled_window), box2);
@@ -8742,20 +8724,20 @@ create_main_window (void)
NULL);
else
gtk_widget_set_sensitive (button, FALSE);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
}
separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
- gtk_box_pack_start (GTK_BOX (box1), separator, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), separator);
box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, 10);
- gtk_box_pack_start (GTK_BOX (box1), box2, TRUE);
+ gtk_box_pack_start (GTK_BOX (box1), box2);
button = gtk_button_new_with_mnemonic ("_Close");
g_signal_connect (button, "clicked",
G_CALLBACK (do_exit),
window);
- gtk_box_pack_start (GTK_BOX (box2), button, TRUE);
+ gtk_box_pack_start (GTK_BOX (box2), button);
gtk_widget_set_can_default (button, TRUE);
gtk_widget_grab_default (button);