diff --git a/demos/gtk-demo/blendmodes.ui b/demos/gtk-demo/blendmodes.ui index e87a0a8970..5826f41d44 100644 --- a/demos/gtk-demo/blendmodes.ui +++ b/demos/gtk-demo/blendmodes.ui @@ -8,6 +8,10 @@ 300 + 12 + 12 + 12 + 12 12 12 diff --git a/demos/gtk-demo/dnd.c b/demos/gtk-demo/dnd.c index 1aff3b1bcd..83e6e92359 100644 --- a/demos/gtk-demo/dnd.c +++ b/demos/gtk-demo/dnd.c @@ -566,7 +566,6 @@ canvas_new (void) canvas = gtk_fixed_new (); gtk_widget_set_hexpand (canvas, TRUE); gtk_widget_set_vexpand (canvas, TRUE); - gtk_widget_add_css_class (canvas, "frame"); source = gtk_drag_source_new (); gtk_drag_source_set_actions (source, GDK_ACTION_MOVE); @@ -764,6 +763,8 @@ do_dnd (GtkWidget *do_widget) y += 100; } + gtk_box_append (GTK_BOX (box), gtk_separator_new (GTK_ORIENTATION_HORIZONTAL)); + sw = gtk_scrolled_window_new (); gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (sw), GTK_POLICY_AUTOMATIC, diff --git a/demos/gtk-demo/fontrendering.ui b/demos/gtk-demo/fontrendering.ui index e9fcea53d5..f2551e29a5 100644 --- a/demos/gtk-demo/fontrendering.ui +++ b/demos/gtk-demo/fontrendering.ui @@ -198,10 +198,12 @@ + + + 1 - 1 1 1 diff --git a/demos/gtk-demo/panes.c b/demos/gtk-demo/panes.c index 134d3bea97..e6312054f1 100644 --- a/demos/gtk-demo/panes.c +++ b/demos/gtk-demo/panes.c @@ -61,10 +61,6 @@ create_pane_options (GtkPaned *paned, child2 = gtk_paned_get_end_child (paned); frame = gtk_frame_new (frame_label); - gtk_widget_set_margin_start (frame, 4); - gtk_widget_set_margin_end (frame, 4); - gtk_widget_set_margin_top (frame, 4); - gtk_widget_set_margin_bottom (frame, 4); table = gtk_grid_new (); gtk_frame_set_child (GTK_FRAME (frame), table); @@ -110,6 +106,7 @@ do_panes (GtkWidget *do_widget) GtkWidget *vpaned; GtkWidget *button; GtkWidget *vbox; + GtkWidget *box; if (!window) { @@ -120,33 +117,42 @@ do_panes (GtkWidget *do_widget) gtk_window_set_title (GTK_WINDOW (window), "Paned Widgets"); - vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0); + vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 8); + gtk_widget_set_margin_start (vbox, 8); + gtk_widget_set_margin_end (vbox, 8); + gtk_widget_set_margin_top (vbox, 8); + gtk_widget_set_margin_bottom (vbox, 8); gtk_window_set_child (GTK_WINDOW (window), vbox); + frame = gtk_frame_new (NULL); + gtk_box_append (GTK_BOX (vbox), frame); + vpaned = gtk_paned_new (GTK_ORIENTATION_VERTICAL); - gtk_widget_set_margin_start (vpaned, 5); - gtk_widget_set_margin_end (vpaned, 5); - gtk_widget_set_margin_top (vpaned, 5); - gtk_widget_set_margin_bottom (vpaned, 5); - gtk_box_append (GTK_BOX (vbox), vpaned); + gtk_frame_set_child (GTK_FRAME (frame), vpaned); hpaned = gtk_paned_new (GTK_ORIENTATION_HORIZONTAL); gtk_paned_set_start_child (GTK_PANED (vpaned), hpaned); - frame = gtk_frame_new (NULL); - gtk_widget_set_size_request (frame, 60, 60); - gtk_paned_set_start_child (GTK_PANED (hpaned), frame); + box = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0); + gtk_widget_set_size_request (box, 60, 60); + gtk_paned_set_start_child (GTK_PANED (hpaned), box); button = gtk_button_new_with_mnemonic ("_Hi there"); - gtk_frame_set_child (GTK_FRAME (frame), button); + gtk_widget_set_margin_start (button, 4); + gtk_widget_set_margin_end (button, 4); + gtk_widget_set_margin_top (button, 4); + gtk_widget_set_margin_bottom (button, 4); + gtk_widget_set_hexpand (button, TRUE); + gtk_widget_set_vexpand (button, TRUE); + gtk_box_append (GTK_BOX (box), button); - frame = gtk_frame_new (NULL); - gtk_widget_set_size_request (frame, 80, 60); - gtk_paned_set_end_child (GTK_PANED (hpaned), frame); + box = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0); + gtk_widget_set_size_request (box, 80, 60); + gtk_paned_set_end_child (GTK_PANED (hpaned), box); - frame = gtk_frame_new (NULL); - gtk_widget_set_size_request (frame, 60, 80); - gtk_paned_set_end_child (GTK_PANED (vpaned), frame); + box = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0); + gtk_widget_set_size_request (box, 60, 80); + gtk_paned_set_end_child (GTK_PANED (vpaned), box); /* Now create toggle buttons to control sizing */