Skip to content
Browse files

Fix various packing issue affecting GTK3 but compatible with GTK2

  • Loading branch information...
1 parent 972b34e commit c1a7b1b475a28c73f830b76de7d1dedf5948df3f @b4n b4n committed Sep 28, 2012
Showing with 12 additions and 12 deletions.
  1. +1 −1 plugins/filebrowser.c
  2. +1 −1 plugins/saveactions.c
  3. +1 −1 plugins/splitwindow.c
  4. +5 −5 src/dialogs.c
  5. +1 −1 src/highlighting.c
  6. +1 −1 src/plugins.c
  7. +1 −1 src/pluginutils.c
  8. +1 −1 src/project.c
View
2 plugins/filebrowser.c
@@ -1109,7 +1109,7 @@ void plugin_init(GeanyData *data)
GTK_SCROLLED_WINDOW(scrollwin),
GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
gtk_container_add(GTK_CONTAINER(scrollwin), file_view);
- gtk_container_add(GTK_CONTAINER(file_view_vbox), scrollwin);
+ gtk_box_pack_start(GTK_BOX(file_view_vbox), scrollwin, TRUE, TRUE, 0);
/* load settings before file_view "realize" callback */
load_settings();
View
2 plugins/saveactions.c
@@ -556,7 +556,7 @@ GtkWidget *plugin_configure(GtkDialog *dialog)
label = gtk_label_new_with_mnemonic(_("Auto save _interval:"));
gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5);
- gtk_container_add(GTK_CONTAINER(inner_vbox), label);
+ gtk_box_pack_start(GTK_BOX(inner_vbox), label, TRUE, TRUE, 0);
pref_widgets.autosave_interval_spin = spin = gtk_spin_button_new_with_range(1, 1800, 1);
gtk_spin_button_set_value(GTK_SPIN_BUTTON(spin), autosave_interval);
View
2 plugins/splitwindow.c
@@ -173,7 +173,7 @@ static void set_editor(EditWindow *editwin, GeanyEditor *editor)
editwin->sci = editor_create_widget(editor);
gtk_widget_show(GTK_WIDGET(editwin->sci));
- gtk_container_add(GTK_CONTAINER(editwin->vbox), GTK_WIDGET(editwin->sci));
+ gtk_box_pack_start(GTK_BOX(editwin->vbox), GTK_WIDGET(editwin->sci), TRUE, TRUE, 0);
sync_to_current(editwin->sci, editor->sci);
View
10 src/dialogs.c
@@ -1262,9 +1262,9 @@ void dialogs_show_file_properties(GeanyDocument *doc)
gtk_misc_set_alignment(GTK_MISC(image), 1.0, 0.5);
hbox = gtk_hbox_new(FALSE, 6);
gtk_label_set_use_markup(GTK_LABEL(label), TRUE);
- gtk_container_add(GTK_CONTAINER(hbox), image);
- gtk_container_add(GTK_CONTAINER(hbox), label);
- gtk_container_add(GTK_CONTAINER(vbox), hbox);
+ gtk_box_pack_start(GTK_BOX(hbox), image, TRUE, TRUE, 0);
+ gtk_box_pack_start(GTK_BOX(hbox), label, TRUE, TRUE, 0);
+ gtk_box_pack_start(GTK_BOX(vbox), hbox, TRUE, TRUE, 0);
table = gtk_table_new(8, 2, FALSE);
gtk_table_set_row_spacings(GTK_TABLE(table), 10);
@@ -1394,7 +1394,7 @@ void dialogs_show_file_properties(GeanyDocument *doc)
gtk_misc_set_alignment(GTK_MISC(label), 0, 0);
/* add table */
- gtk_container_add(GTK_CONTAINER(vbox), table);
+ gtk_box_pack_start(GTK_BOX(vbox), table, TRUE, TRUE, 0);
/* create table with the permissions */
perm_table = gtk_table_new(5, 4, TRUE);
@@ -1537,7 +1537,7 @@ void dialogs_show_file_properties(GeanyDocument *doc)
(GtkAttachOptions) (0), 0, 0);
gtk_button_set_alignment(GTK_BUTTON(check), 0.5, 0);
- gtk_container_add(GTK_CONTAINER(vbox), perm_table);
+ gtk_box_pack_start(GTK_BOX(vbox), perm_table ,TRUE, TRUE, 0);
g_free(base_name);
g_free(time_changed);
View
2 src/highlighting.c
@@ -1377,7 +1377,7 @@ void highlighting_show_color_scheme_dialog(void)
gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(swin),
GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
gtk_container_add(GTK_CONTAINER(swin), tree);
- gtk_container_add(GTK_CONTAINER(vbox), swin);
+ gtk_box_pack_start(GTK_BOX(vbox), swin, TRUE, TRUE, 0);
g_signal_connect(dialog, "response", G_CALLBACK(on_color_scheme_dialog_response), &dialog);
gtk_widget_show_all(dialog);
}
View
2 src/plugins.c
@@ -1484,7 +1484,7 @@ static void pm_show_dialog(GtkMenuItem *menuitem, gpointer user_data)
g_signal_connect(pm_widgets.dialog, "response", G_CALLBACK(pm_dialog_response), NULL);
- gtk_container_add(GTK_CONTAINER(vbox), vbox2);
+ gtk_box_pack_start(GTK_BOX(vbox), vbox2, TRUE, TRUE, 0);
gtk_widget_show_all(pm_widgets.dialog);
}
View
2 src/pluginutils.c
@@ -338,7 +338,7 @@ static void configure_plugins(Plugin *current_plugin)
vbox = ui_dialog_vbox_new(GTK_DIALOG(dialog));
nb = gtk_notebook_new();
gtk_notebook_set_scrollable(GTK_NOTEBOOK(nb), TRUE);
- gtk_container_add(GTK_CONTAINER(vbox), nb);
+ gtk_box_pack_start(GTK_BOX(vbox), nb, TRUE, TRUE, 0);
foreach_list(node, active_plugin_list)
{
View
2 src/project.c
@@ -177,7 +177,7 @@ void project_new(void)
ui_table_add_row(GTK_TABLE(table), 2, label, bbox, NULL);
- gtk_container_add(GTK_CONTAINER(vbox), table);
+ gtk_box_pack_start(GTK_BOX(vbox), table, TRUE, TRUE, 0);
/* signals */
g_signal_connect(e->name, "changed", G_CALLBACK(on_name_entry_changed), e);

0 comments on commit c1a7b1b

Please sign in to comment.
Something went wrong with that request. Please try again.