[Xfce4-commits] [xfce/thunar] 01/01: Replace GtkTable by GtkGrid

noreply at xfce.org noreply at xfce.org
Mon Sep 4 02:24:42 CEST 2017


This is an automated email from the git hooks/post-receive script.

a   n   d   r   e       p   u   s   h   e   d       a       c   o   m   m   i   t       t   o       b   r   a   n   c   h       m   a   s   t   e   r   
   in repository xfce/thunar.

commit 9003c61f340c55745fad2452d592fb04cec742ba
Author: Andre Miranda <andreldm at xfce.org>
Date:   Sun Sep 3 21:24:32 2017 -0300

    Replace GtkTable by GtkGrid
---
 plugins/thunar-apr/thunar-apr-desktop-page.c    |  50 +++++---
 plugins/thunar-apr/thunar-apr-image-page.c      |  32 +++--
 plugins/thunar-sbr/thunar-sbr-insert-renamer.c  |  23 ++--
 plugins/thunar-sbr/thunar-sbr-remove-renamer.c  |  24 ++--
 plugins/thunar-sbr/thunar-sbr-replace-renamer.c |  26 ++--
 thunar/thunar-column-editor.c                   |  49 ++++----
 thunar/thunar-create-dialog.c                   |  22 ++--
 thunar/thunar-dialogs.c                         |  59 +++++----
 thunar/thunar-permissions-chooser.c             |  60 +++++----
 thunar/thunar-preferences-dialog.c              | 158 +++++++++++++-----------
 thunar/thunar-properties-dialog.c               |  84 +++++++------
 thunar/thunar-window.c                          |  30 +++--
 12 files changed, 348 insertions(+), 269 deletions(-)

diff --git a/plugins/thunar-apr/thunar-apr-desktop-page.c b/plugins/thunar-apr/thunar-apr-desktop-page.c
index bf391fe..87780c8 100644
--- a/plugins/thunar-apr/thunar-apr-desktop-page.c
+++ b/plugins/thunar-apr/thunar-apr-desktop-page.c
@@ -131,8 +131,9 @@ thunar_apr_desktop_page_init (ThunarAprDesktopPage *desktop_page)
   PangoAttrList  *attr_list;
   AtkRelation    *relation;
   AtkObject      *object;
-  GtkWidget      *table;
+  GtkWidget      *grid;
   GtkWidget      *label;
+  GtkWidget      *spacer;
 
   gtk_container_set_border_width (GTK_CONTAINER (desktop_page), 12);
 
@@ -143,16 +144,16 @@ thunar_apr_desktop_page_init (ThunarAprDesktopPage *desktop_page)
   attribute->end_index = -1;
   pango_attr_list_insert (attr_list, attribute);
 
-  table = gtk_table_new (8, 2, FALSE);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 0);
-  gtk_container_add (GTK_CONTAINER (desktop_page), table);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_add (GTK_CONTAINER (desktop_page), grid);
+  gtk_widget_show (grid);
 
   label = gtk_label_new (_("Description:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), attr_list);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 0, 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 1, 1);
   gtk_widget_show (label);
 
   desktop_page->description_entry = gtk_entry_new ();
@@ -160,7 +161,8 @@ thunar_apr_desktop_page_init (ThunarAprDesktopPage *desktop_page)
                                                                   "in case of Firefox."));
   g_signal_connect (G_OBJECT (desktop_page->description_entry), "activate", G_CALLBACK (thunar_apr_desktop_page_activated), desktop_page);
   g_signal_connect (G_OBJECT (desktop_page->description_entry), "focus-out-event", G_CALLBACK (thunar_apr_desktop_page_focus_out_event), desktop_page);
-  gtk_table_attach (GTK_TABLE (table), desktop_page->description_entry, 1, 2, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (desktop_page->description_entry, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), desktop_page->description_entry, 1, 0, 1, 1);
   gtk_widget_show (desktop_page->description_entry);
 
   exo_binding_new (G_OBJECT (desktop_page->description_entry), "visible", G_OBJECT (label), "visible");
@@ -175,14 +177,15 @@ thunar_apr_desktop_page_init (ThunarAprDesktopPage *desktop_page)
   label = gtk_label_new (_("Command:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), attr_list);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 1, 2, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 1, 1, 1);
   gtk_widget_show (label);
 
   desktop_page->command_entry = gtk_entry_new ();
   gtk_widget_set_tooltip_text (desktop_page->command_entry, _("The program to execute, possibly with arguments."));
   g_signal_connect (G_OBJECT (desktop_page->command_entry), "activate", G_CALLBACK (thunar_apr_desktop_page_activated), desktop_page);
   g_signal_connect (G_OBJECT (desktop_page->command_entry), "focus-out-event", G_CALLBACK (thunar_apr_desktop_page_focus_out_event), desktop_page);
-  gtk_table_attach (GTK_TABLE (table), desktop_page->command_entry, 1, 2, 1, 2, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (desktop_page->command_entry, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), desktop_page->command_entry, 1, 1, 1, 1);
   gtk_widget_show (desktop_page->command_entry);
 
   exo_binding_new (G_OBJECT (desktop_page->command_entry), "visible", G_OBJECT (label), "visible");
@@ -197,14 +200,15 @@ thunar_apr_desktop_page_init (ThunarAprDesktopPage *desktop_page)
   label = gtk_label_new (_("Working Directory:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), attr_list);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 2, 3, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 2, 1, 1);
   gtk_widget_show (label);
 
   desktop_page->path_entry = gtk_entry_new ();
   gtk_widget_set_tooltip_text (desktop_page->path_entry, _("The working directory for the program."));
   g_signal_connect (G_OBJECT (desktop_page->path_entry), "activate", G_CALLBACK (thunar_apr_desktop_page_activated), desktop_page);
   g_signal_connect (G_OBJECT (desktop_page->path_entry), "focus-out-event", G_CALLBACK (thunar_apr_desktop_page_focus_out_event), desktop_page);
-  gtk_table_attach (GTK_TABLE (table), desktop_page->path_entry, 1, 2, 2, 3, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (desktop_page->path_entry, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), desktop_page->path_entry, 1, 2, 1, 1);
   gtk_widget_show (desktop_page->path_entry);
 
   exo_binding_new (G_OBJECT (desktop_page->path_entry), "visible", G_OBJECT (label), "visible");
@@ -219,14 +223,15 @@ thunar_apr_desktop_page_init (ThunarAprDesktopPage *desktop_page)
   label = gtk_label_new (_("URL:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), attr_list);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 3, 4, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 3, 1, 1);
   gtk_widget_show (label);
 
   desktop_page->url_entry = gtk_entry_new ();
   gtk_widget_set_tooltip_text (desktop_page->url_entry, _("The URL to access."));
   g_signal_connect (G_OBJECT (desktop_page->url_entry), "activate", G_CALLBACK (thunar_apr_desktop_page_activated), desktop_page);
   g_signal_connect (G_OBJECT (desktop_page->url_entry), "focus-out-event", G_CALLBACK (thunar_apr_desktop_page_focus_out_event), desktop_page);
-  gtk_table_attach (GTK_TABLE (table), desktop_page->url_entry, 1, 2, 3, 4, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (desktop_page->url_entry, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), desktop_page->url_entry, 1, 3, 1, 1);
   gtk_widget_show (desktop_page->url_entry);
 
   exo_binding_new (G_OBJECT (desktop_page->url_entry), "visible", G_OBJECT (label), "visible");
@@ -241,7 +246,7 @@ thunar_apr_desktop_page_init (ThunarAprDesktopPage *desktop_page)
   label = gtk_label_new (_("Comment:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), attr_list);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 4, 5, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 4, 1, 1);
   gtk_widget_show (label);
 
   desktop_page->comment_entry = gtk_entry_new ();
@@ -250,7 +255,8 @@ thunar_apr_desktop_page_init (ThunarAprDesktopPage *desktop_page)
                                                               "description."));
   g_signal_connect (G_OBJECT (desktop_page->comment_entry), "activate", G_CALLBACK (thunar_apr_desktop_page_activated), desktop_page);
   g_signal_connect (G_OBJECT (desktop_page->comment_entry), "focus-out-event", G_CALLBACK (thunar_apr_desktop_page_focus_out_event), desktop_page);
-  gtk_table_attach (GTK_TABLE (table), desktop_page->comment_entry, 1, 2, 4, 5, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (desktop_page->comment_entry, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), desktop_page->comment_entry, 1, 4, 1, 1);
   gtk_widget_show (desktop_page->comment_entry);
 
   exo_binding_new (G_OBJECT (desktop_page->comment_entry), "visible", G_OBJECT (label), "visible");
@@ -263,12 +269,14 @@ thunar_apr_desktop_page_init (ThunarAprDesktopPage *desktop_page)
   g_object_unref (G_OBJECT (relation));
 
   /* add spacing between the entries and the options */
-  gtk_table_set_row_spacing (GTK_TABLE (table), 4, 24);
+  spacer = g_object_new (GTK_TYPE_BOX, "orientation", GTK_ORIENTATION_VERTICAL, "height-request", 24, NULL);
+  gtk_grid_attach (GTK_GRID (grid), spacer, 0, 6, 2, 1);
+  gtk_widget_show (spacer);
 
   label = gtk_label_new (_("Options:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), attr_list);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 6, 7, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 7, 1, 1);
   gtk_widget_show (label);
 
   desktop_page->snotify_button = gtk_check_button_new_with_mnemonic (_("Use _startup notification"));
@@ -276,13 +284,15 @@ thunar_apr_desktop_page_init (ThunarAprDesktopPage *desktop_page)
                                                                "is run from the file manager or the menu. Not every application supports "
                                                                "startup notification."));
   g_signal_connect (G_OBJECT (desktop_page->snotify_button), "toggled", G_CALLBACK (thunar_apr_desktop_page_toggled), desktop_page);
-  gtk_table_attach (GTK_TABLE (table), desktop_page->snotify_button, 1, 2, 6, 7, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (desktop_page->snotify_button, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), desktop_page->snotify_button, 1, 7, 1, 1);
   gtk_widget_show (desktop_page->snotify_button);
 
   desktop_page->terminal_button = gtk_check_button_new_with_mnemonic (_("Run in _terminal"));
   gtk_widget_set_tooltip_text (desktop_page->terminal_button, _("Select this option to run the command in a terminal window."));
   g_signal_connect (G_OBJECT (desktop_page->terminal_button), "toggled", G_CALLBACK (thunar_apr_desktop_page_toggled), desktop_page);
-  gtk_table_attach (GTK_TABLE (table), desktop_page->terminal_button, 1, 2, 7, 8, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (desktop_page->terminal_button, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), desktop_page->terminal_button, 1, 8, 1, 1);
   gtk_widget_show (desktop_page->terminal_button);
 
   /* set Atk label relation for the buttons */
diff --git a/plugins/thunar-apr/thunar-apr-image-page.c b/plugins/thunar-apr/thunar-apr-image-page.c
index 28eabd9..48b92c5 100644
--- a/plugins/thunar-apr/thunar-apr-image-page.c
+++ b/plugins/thunar-apr/thunar-apr-image-page.c
@@ -107,7 +107,8 @@ thunar_apr_image_page_init (ThunarAprImagePage *image_page)
   AtkRelation    *relation;
   AtkObject      *object;
   GtkWidget      *label;
-  GtkWidget      *table;
+  GtkWidget      *grid;
+  GtkWidget      *spacer;
 #ifdef HAVE_EXIF
   guint           n;
 #endif
@@ -122,23 +123,24 @@ thunar_apr_image_page_init (ThunarAprImagePage *image_page)
   attribute->end_index = -1;
   pango_attr_list_insert (attr_list, attribute);
 
-  table = gtk_table_new (3, 2, FALSE);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 0);
-  gtk_container_add (GTK_CONTAINER (image_page), table);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_add (GTK_CONTAINER (image_page), grid);
+  gtk_widget_show (grid);
 
   label = gtk_label_new (_("Image Type:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), attr_list);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 0, 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 1, 1);
   gtk_widget_show (label);
 
   image_page->type_label = gtk_label_new ("");
   gtk_label_set_selectable (GTK_LABEL (image_page->type_label), TRUE);
   gtk_label_set_xalign (GTK_LABEL (image_page->type_label), 0.0f);
   gtk_label_set_ellipsize (GTK_LABEL (image_page->type_label), PANGO_ELLIPSIZE_END);
-  gtk_table_attach (GTK_TABLE (table), image_page->type_label, 1, 2, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (image_page->type_label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), image_page->type_label, 1, 0, 1, 1);
   gtk_widget_show (image_page->type_label);
 
   /* set Atk label relation for the label */
@@ -151,14 +153,15 @@ thunar_apr_image_page_init (ThunarAprImagePage *image_page)
   label = gtk_label_new (_("Image Size:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), attr_list);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 1, 2, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 1, 1, 1);
   gtk_widget_show (label);
 
   image_page->dimensions_label = gtk_label_new ("");
   gtk_label_set_selectable (GTK_LABEL (image_page->dimensions_label), TRUE);
   gtk_label_set_xalign (GTK_LABEL (image_page->dimensions_label), 0.0f);
   gtk_label_set_ellipsize (GTK_LABEL (image_page->dimensions_label), PANGO_ELLIPSIZE_END);
-  gtk_table_attach (GTK_TABLE (table), image_page->dimensions_label, 1, 2, 1, 2, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (image_page->dimensions_label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), image_page->dimensions_label, 1, 1, 1, 1);
   gtk_widget_show (image_page->dimensions_label);
 
   /* set Atk label relation for the label */
@@ -170,7 +173,9 @@ thunar_apr_image_page_init (ThunarAprImagePage *image_page)
 
 #ifdef HAVE_EXIF
   /* some spacing between the General info and the Exif info */
-  gtk_table_set_row_spacing (GTK_TABLE (table), 2, 6);
+  spacer = g_object_new (GTK_TYPE_BOX, "orientation", GTK_ORIENTATION_VERTICAL, "height-request", 6, NULL);
+  gtk_grid_attach (GTK_GRID (grid), spacer, 0, 2, 2, 1);
+  gtk_widget_show (spacer);
 
   /* add labels for the Exif info */
   for (n = 0; n < G_N_ELEMENTS (TAIP_EXIF); ++n)
@@ -178,14 +183,15 @@ thunar_apr_image_page_init (ThunarAprImagePage *image_page)
       label = gtk_label_new (_(TAIP_EXIF[n].name));
       gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
       gtk_label_set_attributes (GTK_LABEL (label), attr_list);
-      gtk_table_attach (GTK_TABLE (table), label, 0, 1, n + 3, n + 4, GTK_FILL, GTK_FILL, 0, 3);
+      gtk_grid_attach (GTK_GRID (grid), label, 0, n + 3, 1, 1);
       gtk_widget_show (label);
 
       image_page->exif_labels[n] = gtk_label_new ("");
       gtk_label_set_selectable (GTK_LABEL (image_page->exif_labels[n]), TRUE);
       gtk_label_set_xalign (GTK_LABEL (image_page->exif_labels[n]), 0.0f);
       gtk_label_set_ellipsize (GTK_LABEL (image_page->exif_labels[n]), PANGO_ELLIPSIZE_END);
-      gtk_table_attach (GTK_TABLE (table), image_page->exif_labels[n], 1, 2, n + 3, n + 4, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+      gtk_widget_set_hexpand (image_page->exif_labels[n], TRUE);
+      gtk_grid_attach (GTK_GRID (grid), image_page->exif_labels[n], 1, n + 3, 1, 1);
       gtk_widget_show (image_page->exif_labels[n]);
 
       exo_binding_new (G_OBJECT (image_page->exif_labels[n]), "visible", G_OBJECT (label), "visible");
diff --git a/plugins/thunar-sbr/thunar-sbr-insert-renamer.c b/plugins/thunar-sbr/thunar-sbr-insert-renamer.c
index fbdbf16..ccf3bfc 100644
--- a/plugins/thunar-sbr/thunar-sbr-insert-renamer.c
+++ b/plugins/thunar-sbr/thunar-sbr-insert-renamer.c
@@ -157,33 +157,34 @@ thunar_sbr_insert_renamer_init (ThunarSbrInsertRenamer *insert_renamer)
   GtkWidget      *combo;
   GtkWidget      *entry;
   GtkWidget      *label;
-  GtkWidget      *table;
+  GtkWidget      *grid;
   GtkWidget      *hbox;
   guint           n;
 
-  table = gtk_table_new (2, 3, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_box_pack_start (GTK_BOX (insert_renamer), table, TRUE, TRUE, 0);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_box_pack_start (GTK_BOX (insert_renamer), grid, TRUE, TRUE, 0);
+  gtk_widget_show (grid);
 
   combo = gtk_combo_box_text_new ();
   klass = g_type_class_ref (THUNAR_SBR_TYPE_INSERT_MODE);
   for (n = 0; n < klass->n_values; ++n)
     gtk_combo_box_text_append_text (GTK_COMBO_BOX_TEXT (combo), _(klass->values[n].value_nick));
   exo_mutual_binding_new (G_OBJECT (insert_renamer), "mode", G_OBJECT (combo), "active");
-  gtk_table_attach (GTK_TABLE (table), combo, 0, 1, 0, 1, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), combo, 0, 0, 1, 1);
   g_type_class_unref (klass);
   gtk_widget_show (combo);
 
   label = gtk_label_new_with_mnemonic (_("_Text:"));
-  gtk_table_attach (GTK_TABLE (table), label, 1, 2, 0, 1, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 1, 0, 1, 1);
   gtk_widget_show (label);
 
   entry = gtk_entry_new ();
   gtk_entry_set_activates_default (GTK_ENTRY (entry), TRUE);
   exo_mutual_binding_new (G_OBJECT (entry), "text", G_OBJECT (insert_renamer), "text");
-  gtk_table_attach (GTK_TABLE (table), entry, 2, 3, 0, 1, GTK_EXPAND | GTK_FILL, 0, 0, 0);
+  gtk_widget_set_hexpand (entry, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), entry, 2, 0, 1, 1);
   gtk_label_set_mnemonic_widget (GTK_LABEL (label), entry);
   gtk_widget_show (entry);
 
@@ -196,11 +197,11 @@ thunar_sbr_insert_renamer_init (ThunarSbrInsertRenamer *insert_renamer)
 
   label = gtk_label_new_with_mnemonic (_("_At position:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 2, 1, 2, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 1, 2, 1);
   gtk_widget_show (label);
 
   hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 12);
-  gtk_table_attach (GTK_TABLE (table), hbox, 2, 3, 1, 2, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), hbox, 2, 1, 1, 1);
   gtk_widget_show (hbox);
 
   spinner = gtk_spin_button_new_with_range (0u, G_MAXUINT, 1u);
diff --git a/plugins/thunar-sbr/thunar-sbr-remove-renamer.c b/plugins/thunar-sbr/thunar-sbr-remove-renamer.c
index 2070466..24a27ae 100644
--- a/plugins/thunar-sbr/thunar-sbr-remove-renamer.c
+++ b/plugins/thunar-sbr/thunar-sbr-remove-renamer.c
@@ -163,18 +163,18 @@ thunar_sbr_remove_renamer_init (ThunarSbrRemoveRenamer *remove_renamer)
   AtkObject      *object;
   GtkWidget      *combo;
   GtkWidget      *label;
-  GtkWidget      *table;
+  GtkWidget      *grid;
   guint           n;
 
-  table = gtk_table_new (2, 3, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_box_pack_start (GTK_BOX (remove_renamer), table, TRUE, TRUE, 0);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_box_pack_start (GTK_BOX (remove_renamer), grid, TRUE, TRUE, 0);
+  gtk_widget_show (grid);
 
   label = gtk_label_new_with_mnemonic (_("Remove _From Position:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 0, 1, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 1, 1);
   gtk_widget_show (label);
 
   remove_renamer->start_spinner = gtk_spin_button_new_with_range (0u, G_MAXUINT, 1u);
@@ -184,7 +184,7 @@ thunar_sbr_remove_renamer_init (ThunarSbrRemoveRenamer *remove_renamer)
   gtk_spin_button_set_digits (GTK_SPIN_BUTTON (remove_renamer->start_spinner), 0);
   gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (remove_renamer->start_spinner), TRUE);
   gtk_spin_button_set_snap_to_ticks (GTK_SPIN_BUTTON (remove_renamer->start_spinner), TRUE);
-  gtk_table_attach (GTK_TABLE (table), remove_renamer->start_spinner, 1, 2, 0, 1, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), remove_renamer->start_spinner, 1, 0, 1, 1);
   gtk_label_set_mnemonic_widget (GTK_LABEL (label), remove_renamer->start_spinner);
   gtk_widget_show (remove_renamer->start_spinner);
 
@@ -203,13 +203,13 @@ thunar_sbr_remove_renamer_init (ThunarSbrRemoveRenamer *remove_renamer)
   for (n = 0; n < klass->n_values; ++n)
     gtk_combo_box_text_append_text (GTK_COMBO_BOX_TEXT (combo), _(klass->values[n].value_nick));
   exo_mutual_binding_new (G_OBJECT (remove_renamer), "start-offset-mode", G_OBJECT (combo), "active");
-  gtk_table_attach (GTK_TABLE (table), combo, 2, 3, 0, 1, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), combo, 2, 0, 1, 1);
   g_type_class_unref (klass);
   gtk_widget_show (combo);
 
   label = gtk_label_new_with_mnemonic (_("_To Position:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 1, 2, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 1, 1, 1);
   gtk_widget_show (label);
 
   remove_renamer->end_spinner = gtk_spin_button_new_with_range (0u, G_MAXUINT, 1u);
@@ -219,7 +219,7 @@ thunar_sbr_remove_renamer_init (ThunarSbrRemoveRenamer *remove_renamer)
   gtk_spin_button_set_digits (GTK_SPIN_BUTTON (remove_renamer->end_spinner), 0);
   gtk_spin_button_set_numeric (GTK_SPIN_BUTTON (remove_renamer->end_spinner), TRUE);
   gtk_spin_button_set_snap_to_ticks (GTK_SPIN_BUTTON (remove_renamer->end_spinner), TRUE);
-  gtk_table_attach (GTK_TABLE (table), remove_renamer->end_spinner, 1, 2, 1, 2, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), remove_renamer->end_spinner, 1, 1, 1, 1);
   gtk_label_set_mnemonic_widget (GTK_LABEL (label), remove_renamer->end_spinner);
   gtk_widget_show (remove_renamer->end_spinner);
 
@@ -238,7 +238,7 @@ thunar_sbr_remove_renamer_init (ThunarSbrRemoveRenamer *remove_renamer)
   for (n = 0; n < klass->n_values; ++n)
     gtk_combo_box_text_append_text (GTK_COMBO_BOX_TEXT (combo), _(klass->values[n].value_nick));
   exo_mutual_binding_new (G_OBJECT (remove_renamer), "end-offset-mode", G_OBJECT (combo), "active");
-  gtk_table_attach (GTK_TABLE (table), combo, 2, 3, 1, 2, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), combo, 2, 1, 1, 1);
   g_type_class_unref (klass);
   gtk_widget_show (combo);
 }
diff --git a/plugins/thunar-sbr/thunar-sbr-replace-renamer.c b/plugins/thunar-sbr/thunar-sbr-replace-renamer.c
index 0a276f2..c9d725c 100644
--- a/plugins/thunar-sbr/thunar-sbr-replace-renamer.c
+++ b/plugins/thunar-sbr/thunar-sbr-replace-renamer.c
@@ -182,7 +182,7 @@ thunar_sbr_replace_renamer_init (ThunarSbrReplaceRenamer *replace_renamer)
   AtkRelationSet *relations;
   AtkRelation    *relation;
   AtkObject      *object;
-  GtkWidget      *table;
+  GtkWidget      *grid;
   GtkWidget      *label;
   GtkWidget      *entry;
   GtkWidget      *button;
@@ -193,22 +193,23 @@ thunar_sbr_replace_renamer_init (ThunarSbrReplaceRenamer *replace_renamer)
     replace_renamer->regexp_supported = FALSE;
 #endif
 
-  table = gtk_table_new (2, 3, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_box_pack_start (GTK_BOX (replace_renamer), table, FALSE, FALSE, 0);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_box_pack_start (GTK_BOX (replace_renamer), grid, FALSE, FALSE, 0);
+  gtk_widget_show (grid);
 
   label = gtk_label_new_with_mnemonic (_("_Search For:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 0, 1, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 1, 1);
   gtk_widget_show (label);
 
   replace_renamer->pattern_entry = gtk_entry_new ();
   gtk_entry_set_activates_default (GTK_ENTRY (replace_renamer->pattern_entry), TRUE);
   exo_mutual_binding_new (G_OBJECT (replace_renamer->pattern_entry), "text", G_OBJECT (replace_renamer), "pattern");
   gtk_widget_set_tooltip_text (replace_renamer->pattern_entry, _("Enter the text to search for in the file names."));
-  gtk_table_attach (GTK_TABLE (table), replace_renamer->pattern_entry, 1, 2, 0, 1, GTK_EXPAND | GTK_FILL, 0, 0, 0);
+  gtk_widget_set_hexpand (replace_renamer->pattern_entry, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), replace_renamer->pattern_entry, 1, 0, 1, 1);
   gtk_label_set_mnemonic_widget (GTK_LABEL (label), replace_renamer->pattern_entry);
   gtk_widget_show (replace_renamer->pattern_entry);
 
@@ -224,20 +225,21 @@ thunar_sbr_replace_renamer_init (ThunarSbrReplaceRenamer *replace_renamer)
   gtk_widget_set_tooltip_text (button, _("If you enable this option, the pattern will be treated as a regular expression and "
                                          "matched using the Perl-compatible regular expressions (PCRE). Check the documentation "
                                          "for details about the regular expression syntax."));
-  gtk_table_attach (GTK_TABLE (table), button, 2, 3, 0, 1, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), button, 2, 0, 1, 1);
   gtk_widget_set_sensitive (button, replace_renamer->regexp_supported);
   gtk_widget_show (button);
 
   label = gtk_label_new_with_mnemonic (_("Replace _With:"));
   gtk_label_set_xalign (GTK_LABEL (label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 1, 2, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 1, 1, 1);
   gtk_widget_show (label);
 
   entry = gtk_entry_new ();
   gtk_entry_set_activates_default (GTK_ENTRY (entry), TRUE);
   exo_mutual_binding_new (G_OBJECT (entry), "text", G_OBJECT (replace_renamer), "replacement");
   gtk_widget_set_tooltip_text (entry, _("Enter the text that should be used as replacement for the pattern above."));
-  gtk_table_attach (GTK_TABLE (table), entry, 1, 2, 1, 2, GTK_EXPAND | GTK_FILL, 0, 0, 0);
+  gtk_widget_set_hexpand (entry, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), entry, 1, 1, 1, 1);
   gtk_label_set_mnemonic_widget (GTK_LABEL (label), entry);
   gtk_widget_show (entry);
 
@@ -252,7 +254,7 @@ thunar_sbr_replace_renamer_init (ThunarSbrReplaceRenamer *replace_renamer)
   exo_mutual_binding_new (G_OBJECT (button), "active", G_OBJECT (replace_renamer), "case-sensitive");
   gtk_widget_set_tooltip_text (button, _("If you enable this option, the pattern will be searched in a case-sensitive manner. "
                                          "The default is to use a case-insensitive search."));
-  gtk_table_attach (GTK_TABLE (table), button, 2, 3, 1, 2, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), button, 2, 1, 1, 1);
   gtk_widget_show (button);
 }
 
diff --git a/thunar/thunar-column-editor.c b/thunar/thunar-column-editor.c
index eda5937..7761984 100644
--- a/thunar/thunar-column-editor.c
+++ b/thunar/thunar-column-editor.c
@@ -100,7 +100,7 @@ thunar_column_editor_init (ThunarColumnEditor *column_editor)
   GtkWidget         *frame;
   GtkWidget         *image;
   GtkWidget         *label;
-  GtkWidget         *table;
+  GtkWidget         *grid;
   GtkWidget         *vbox;
   GtkWidget         *swin;
 
@@ -141,24 +141,27 @@ thunar_column_editor_init (ThunarColumnEditor *column_editor)
   gtk_frame_set_label_widget (GTK_FRAME (frame), label);
   gtk_widget_show (label);
 
-  table = gtk_table_new (8, 2, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 6);
-  gtk_container_set_border_width (GTK_CONTAINER (table), 12);
-  gtk_container_add (GTK_CONTAINER (frame), table);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 6);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 12);
+  gtk_container_add (GTK_CONTAINER (frame), grid);
+  gtk_widget_show (grid);
 
   /* create the top label for the column editor dialog */
   label = gtk_label_new (_("Choose the order of information to appear in the\ndetailed list view."));
   gtk_label_set_xalign (GTK_LABEL (label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 2, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 2, 1);
   gtk_widget_show (label);
 
   /* create the scrolled window for the tree view */
   swin = gtk_scrolled_window_new (NULL, NULL);
   gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (swin), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
   gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (swin), GTK_SHADOW_IN);
-  gtk_table_attach (GTK_TABLE (table), swin, 0, 1, 1, 7, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (swin, TRUE);
+  gtk_widget_set_vexpand (swin, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), swin, 0, 1, 1, 6);
   gtk_widget_show (swin);
 
   /* create the tree view */
@@ -192,7 +195,7 @@ thunar_column_editor_init (ThunarColumnEditor *column_editor)
   /* create the "Move Up" button */
   column_editor->up_button = gtk_button_new_with_mnemonic (_("Move _Up"));
   g_signal_connect (G_OBJECT (column_editor->up_button), "clicked", G_CALLBACK (thunar_column_editor_move_up), column_editor);
-  gtk_table_attach (GTK_TABLE (table), column_editor->up_button, 1, 2, 1, 2, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), column_editor->up_button, 1, 1, 1, 1);
   gtk_widget_show (column_editor->up_button);
 
   image = gtk_image_new_from_icon_name ("go-up-symbolic", GTK_ICON_SIZE_BUTTON);
@@ -203,7 +206,7 @@ thunar_column_editor_init (ThunarColumnEditor *column_editor)
   /* create the "Move Down" button */
   column_editor->down_button = gtk_button_new_with_mnemonic (_("Move Dow_n"));
   g_signal_connect (G_OBJECT (column_editor->down_button), "clicked", G_CALLBACK (thunar_column_editor_move_down), column_editor);
-  gtk_table_attach (GTK_TABLE (table), column_editor->down_button, 1, 2, 2, 3, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), column_editor->down_button, 1, 2, 1, 1);
   gtk_widget_show (column_editor->down_button);
 
   image = gtk_image_new_from_icon_name ("go-down-symbolic", GTK_ICON_SIZE_BUTTON);
@@ -214,24 +217,24 @@ thunar_column_editor_init (ThunarColumnEditor *column_editor)
   /* create the "Show" button */
   column_editor->show_button = gtk_button_new_with_mnemonic (_("_Show"));
   g_signal_connect (G_OBJECT (column_editor->show_button), "clicked", G_CALLBACK (thunar_column_editor_toggle_visibility), column_editor);
-  gtk_table_attach (GTK_TABLE (table), column_editor->show_button, 1, 2, 3, 4, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), column_editor->show_button, 1, 3, 1, 1);
   gtk_widget_show (column_editor->show_button);
 
   /* create the "Hide" button */
   column_editor->hide_button = gtk_button_new_with_mnemonic (_("Hi_de"));
   g_signal_connect (G_OBJECT (column_editor->hide_button), "clicked", G_CALLBACK (thunar_column_editor_toggle_visibility), column_editor);
-  gtk_table_attach (GTK_TABLE (table), column_editor->hide_button, 1, 2, 4, 5, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), column_editor->hide_button, 1, 4, 1, 1);
   gtk_widget_show (column_editor->hide_button);
 
   /* create the horiz separator */
   separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
-  gtk_table_attach (GTK_TABLE (table), separator, 1, 2, 5, 6, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), separator, 1, 5, 1, 1);
   gtk_widget_show (separator);
 
   /* create the "Use Default" button */
   button = gtk_button_new_with_mnemonic (_("Use De_fault"));
   g_signal_connect (G_OBJECT (button), "clicked", G_CALLBACK (thunar_column_editor_use_defaults), column_editor);
-  gtk_table_attach (GTK_TABLE (table), button, 1, 2, 6, 7, GTK_FILL, 0, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), button, 1, 6, 1, 1);
   gtk_widget_show (button);
 
   frame = g_object_new (GTK_TYPE_FRAME, "border-width", 0, "shadow-type", GTK_SHADOW_NONE, NULL);
@@ -243,12 +246,12 @@ thunar_column_editor_init (ThunarColumnEditor *column_editor)
   gtk_frame_set_label_widget (GTK_FRAME (frame), label);
   gtk_widget_show (label);
 
-  table = gtk_table_new (2, 1, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 6);
-  gtk_container_set_border_width (GTK_CONTAINER (table), 12);
-  gtk_container_add (GTK_CONTAINER (frame), table);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 6);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 12);
+  gtk_container_add (GTK_CONTAINER (frame), grid);
+  gtk_widget_show (grid);
 
   /* create the label that explains the column sizing option */
   label = gtk_label_new (_("By default columns will be automatically expanded if\n"
@@ -256,13 +259,13 @@ thunar_column_editor_init (ThunarColumnEditor *column_editor)
                            "able this behavior below the file manager will always\n"
                            "use the user defined column widths."));
   gtk_label_set_xalign (GTK_LABEL (label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 0, 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 1, 1);
   gtk_widget_show (label);
 
   /* create the "Automatically expand columns as needed" button */
   button = gtk_check_button_new_with_mnemonic (_("Automatically _expand columns as needed"));
   exo_mutual_binding_new_with_negation (G_OBJECT (column_editor->preferences), "last-details-view-fixed-columns", G_OBJECT (button), "active");
-  gtk_table_attach (GTK_TABLE (table), button, 0, 1, 1, 2, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), button, 0, 1, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), button);
   gtk_widget_show (button);
 
diff --git a/thunar/thunar-create-dialog.c b/thunar/thunar-create-dialog.c
index 88e9f25..a0ecd39 100644
--- a/thunar/thunar-create-dialog.c
+++ b/thunar/thunar-create-dialog.c
@@ -132,7 +132,7 @@ static void
 thunar_create_dialog_init (ThunarCreateDialog *dialog)
 {
   GtkWidget *label;
-  GtkWidget *table;
+  GtkWidget *grid;
 
   dialog->content_type = NULL;
 
@@ -145,21 +145,25 @@ thunar_create_dialog_init (ThunarCreateDialog *dialog)
   gtk_dialog_set_response_sensitive (GTK_DIALOG (dialog), GTK_RESPONSE_OK, FALSE);
   gtk_window_set_default_size (GTK_WINDOW (dialog), 300, -1);
 
-  table = g_object_new (GTK_TYPE_TABLE, "border-width", 6, "column-spacing", 6, "row-spacing", 3, NULL);
-  gtk_box_pack_start (GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dialog))), table, TRUE, TRUE, 0);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 6);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 3);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 6);
+  gtk_box_pack_start (GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dialog))), grid, TRUE, TRUE, 0);
+  gtk_widget_show (grid);
 
   dialog->image = g_object_new (GTK_TYPE_IMAGE, "xpad", 6, "ypad", 6, NULL);
-  gtk_table_attach (GTK_TABLE (table), dialog->image, 0, 1, 0, 2, GTK_FILL, GTK_FILL, 0, 0); 
+  gtk_grid_attach (GTK_GRID (grid), dialog->image, 0, 0, 1, 2);
   gtk_widget_show (dialog->image);
 
-  label = g_object_new (GTK_TYPE_LABEL, "label", _("Enter the new name:"), "xalign", 0.0f, NULL);
-  gtk_table_attach (GTK_TABLE (table), label, 1, 2, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  label = g_object_new (GTK_TYPE_LABEL, "label", _("Enter the new name:"), "xalign", 0.0f, "hexpand", TRUE, NULL);
+  gtk_grid_attach (GTK_GRID (grid), label, 1, 0, 1, 1);
   gtk_widget_show (label);
 
-  dialog->entry = g_object_new (GTK_TYPE_ENTRY, "activates-default", TRUE, NULL);
+  dialog->entry = g_object_new (GTK_TYPE_ENTRY, "activates-default", TRUE, "hexpand", TRUE, NULL);
   g_signal_connect (G_OBJECT (dialog->entry), "changed", G_CALLBACK (thunar_create_dialog_text_changed), dialog);
-  gtk_table_attach (GTK_TABLE (table), dialog->entry, 1, 2, 1, 2, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_valign (dialog->entry, GTK_ALIGN_CENTER);
+  gtk_grid_attach (GTK_GRID (grid), dialog->entry, 1, 1, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), dialog->entry);
   gtk_widget_show (dialog->entry);
 }
diff --git a/thunar/thunar-dialogs.c b/thunar/thunar-dialogs.c
index c4567ba..9905f89 100644
--- a/thunar/thunar-dialogs.c
+++ b/thunar/thunar-dialogs.c
@@ -68,7 +68,7 @@ thunar_dialogs_show_rename_file (gpointer    parent,
   GtkWidget         *entry;
   GtkWidget         *label;
   GtkWidget         *image;
-  GtkWidget         *table;
+  GtkWidget         *grid;
   GtkWindow         *window;
   GdkPixbuf         *icon;
   GdkScreen         *screen;
@@ -105,9 +105,12 @@ thunar_dialogs_show_rename_file (gpointer    parent,
   if (G_UNLIKELY (window == NULL && screen != NULL))
     gtk_window_set_screen (GTK_WINDOW (dialog), screen);
 
-  table = g_object_new (GTK_TYPE_TABLE, "border-width", 6, "column-spacing", 6, "row-spacing", 3, NULL);
-  gtk_box_pack_start (GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dialog))), table, TRUE, TRUE, 0);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 6);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 3);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 6);
+  gtk_box_pack_start (GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dialog))), grid, TRUE, TRUE, 0);
+  gtk_widget_show (grid);
 
   icon_theme = gtk_icon_theme_get_for_screen (gtk_widget_get_screen (dialog));
   icon_factory = thunar_icon_factory_get_for_icon_theme (icon_theme);
@@ -116,18 +119,21 @@ thunar_dialogs_show_rename_file (gpointer    parent,
 
   image = gtk_image_new_from_pixbuf (icon);
   gtk_misc_set_padding (GTK_MISC (image), 6, 6);
-  gtk_table_attach (GTK_TABLE (table), image, 0, 1, 0, 2, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), image, 0, 0, 1, 2);
   g_object_unref (G_OBJECT (icon));
   gtk_widget_show (image);
 
   label = gtk_label_new (_("Enter the new name:"));
   gtk_label_set_xalign (GTK_LABEL (label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 1, 2, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), label, 1, 0, 1, 1);
   gtk_widget_show (label);
 
   entry = gtk_entry_new ();
   gtk_entry_set_activates_default (GTK_ENTRY (entry), TRUE);
-  gtk_table_attach (GTK_TABLE (table), entry, 1, 2, 1, 2, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (entry, TRUE);
+  gtk_widget_set_valign (entry, GTK_ALIGN_CENTER);
+  gtk_grid_attach (GTK_GRID (grid), entry, 1, 1, 1, 1);
   gtk_widget_show (entry);
 
   /* setup the old filename */
@@ -514,7 +520,7 @@ thunar_dialogs_show_job_ask_replace (GtkWindow  *parent,
   ThunarDateStyle    date_style;
   GtkIconTheme      *icon_theme;
   GtkWidget         *dialog;
-  GtkWidget         *table;
+  GtkWidget         *grid;
   GtkWidget         *image;
   GtkWidget         *label;
   GdkPixbuf         *icon;
@@ -558,21 +564,19 @@ thunar_dialogs_show_job_ask_replace (GtkWindow  *parent,
   icon_theme = gtk_icon_theme_get_for_screen (gtk_widget_get_screen (dialog));
   icon_factory = thunar_icon_factory_get_for_icon_theme (icon_theme);
 
-  table = g_object_new (GTK_TYPE_TABLE,
-                        "border-width", 10,
-                        "n-columns", 3,
-                        "n-rows", 5,
-                        "row-spacing", 6,
-                        "column-spacing", 5,
-                        NULL);
-  gtk_box_pack_start (GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dialog))), table, TRUE, TRUE, 0);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 5);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 10);
+  gtk_box_pack_start (GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dialog))), grid, TRUE, TRUE, 0);
+  gtk_widget_show (grid);
 
   image = gtk_image_new_from_icon_name ("stock_folder-copy", GTK_ICON_SIZE_BUTTON);
   gtk_widget_set_halign (image, GTK_ALIGN_CENTER);
   gtk_widget_set_valign (image, GTK_ALIGN_START);
   gtk_misc_set_padding (GTK_MISC (image), 6, 6);
-  gtk_table_attach (GTK_TABLE (table), image, 0, 1, 0, 1, GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
+  gtk_widget_set_vexpand (image, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), image, 0, 0, 1, 1);
   gtk_widget_show (image);
 
   if (thunar_file_is_symlink (dst_file))
@@ -594,7 +598,8 @@ thunar_dialogs_show_job_ask_replace (GtkWindow  *parent,
   label = gtk_label_new (text);
   gtk_label_set_xalign (GTK_LABEL (label), 0.0f);
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_big ());
-  gtk_table_attach (GTK_TABLE (table), label, 1, 3, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), label, 1, 0, 2, 1);
   gtk_widget_show (label);
   g_free (text);
 
@@ -607,14 +612,15 @@ thunar_dialogs_show_job_ask_replace (GtkWindow  *parent,
 
   label = gtk_label_new (text);
   gtk_label_set_xalign (GTK_LABEL (label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 1, 3, 1, 2, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), label, 1, 1, 2, 1);
   gtk_widget_show (label);
   g_free (text);
 
   icon = thunar_icon_factory_load_file_icon (icon_factory, dst_file, THUNAR_FILE_ICON_STATE_DEFAULT, 48);
   image = gtk_image_new_from_pixbuf (icon);
   gtk_misc_set_padding (GTK_MISC (image), 6, 6);
-  gtk_table_attach (GTK_TABLE (table), image, 1, 2, 2, 3, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), image, 1, 2, 1, 1);
   g_object_unref (G_OBJECT (icon));
   gtk_widget_show (image);
 
@@ -623,7 +629,8 @@ thunar_dialogs_show_job_ask_replace (GtkWindow  *parent,
   text = g_strdup_printf ("%s %s\n%s %s", _("Size:"), size_string, _("Modified:"), date_string);
   label = gtk_label_new (text);
   gtk_label_set_xalign (GTK_LABEL (label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 2, 3, 2, 3, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), label, 2, 2, 1, 1);
   gtk_widget_show (label);
   g_free (size_string);
   g_free (date_string);
@@ -638,14 +645,15 @@ thunar_dialogs_show_job_ask_replace (GtkWindow  *parent,
 
   label = gtk_label_new (text);
   gtk_label_set_xalign (GTK_LABEL (label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 1, 3, 3, 4, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), label, 1, 3, 2, 1);
   gtk_widget_show (label);
   g_free (text);
 
   icon = thunar_icon_factory_load_file_icon (icon_factory, src_file, THUNAR_FILE_ICON_STATE_DEFAULT, 48);
   image = gtk_image_new_from_pixbuf (icon);
   gtk_misc_set_padding (GTK_MISC (image), 6, 6);
-  gtk_table_attach (GTK_TABLE (table), image, 1, 2, 4, 5, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), image, 1, 4, 1, 1);
   g_object_unref (G_OBJECT (icon));
   gtk_widget_show (image);
 
@@ -654,7 +662,8 @@ thunar_dialogs_show_job_ask_replace (GtkWindow  *parent,
   text = g_strdup_printf ("%s %s\n%s %s", _("Size:"), size_string, _("Modified:"), date_string);
   label = gtk_label_new (text);
   gtk_label_set_xalign (GTK_LABEL (label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 2, 3, 4, 5, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), label, 2, 4, 1, 1);
   gtk_widget_show (label);
   g_free (size_string);
   g_free (date_string);
diff --git a/thunar/thunar-permissions-chooser.c b/thunar/thunar-permissions-chooser.c
index fc0a6ef..4768159 100644
--- a/thunar/thunar-permissions-chooser.c
+++ b/thunar/thunar-permissions-chooser.c
@@ -134,8 +134,8 @@ struct _ThunarPermissionsChooser
 
   GList      *files;
 
-  /* the main table widget, which contains everything but the job control stuff */
-  GtkWidget  *table;
+  /* the main grid widget, which contains everything but the job control stuff */
+  GtkWidget  *grid;
 
   GtkWidget  *user_label;
   GtkWidget  *group_combo;
@@ -212,20 +212,22 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
   /* allocate the shared renderer for the various combo boxes */
   renderer_text = gtk_cell_renderer_text_new ();
 
-  chooser->table = gtk_table_new (2, 2, FALSE);
-  gtk_table_set_col_spacings (GTK_TABLE (chooser->table), 12);
-  gtk_table_set_row_spacings (GTK_TABLE (chooser->table), 6);
-  gtk_box_pack_start (GTK_BOX (chooser), chooser->table, TRUE, TRUE, 0);
-  gtk_widget_show (chooser->table);
+  chooser->grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (chooser->grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (chooser->grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (chooser->grid), 10);
+  gtk_box_pack_start (GTK_BOX (chooser), chooser->grid, TRUE, TRUE, 0);
+  gtk_widget_show (chooser->grid);
 
   label = gtk_label_new (_("Owner:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
-  gtk_table_attach (GTK_TABLE (chooser->table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (chooser->grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
-  gtk_table_attach (GTK_TABLE (chooser->table), hbox, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 6);
+  gtk_widget_set_hexpand (hbox, TRUE);
+  gtk_grid_attach (GTK_GRID (chooser->grid), hbox, 1, row, 1, 1);
   gtk_widget_show (hbox);
 
   chooser->user_label = gtk_label_new (_("Unknown"));
@@ -239,7 +241,7 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
   label = gtk_label_new_with_mnemonic (_("_Access:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
-  gtk_table_attach (GTK_TABLE (chooser->table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (chooser->grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   chooser->access_combos[2] = gtk_combo_box_new ();
@@ -248,14 +250,15 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
   gtk_cell_layout_add_attribute (GTK_CELL_LAYOUT (chooser->access_combos[2]), renderer_text, "text", 0);
   exo_binding_new (G_OBJECT (chooser), "mutable", G_OBJECT (chooser->access_combos[2]), "sensitive");
   g_signal_connect_swapped (G_OBJECT (chooser->access_combos[2]), "changed", G_CALLBACK (thunar_permissions_chooser_access_changed), chooser);
-  gtk_table_attach (GTK_TABLE (chooser->table), chooser->access_combos[2], 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (chooser->access_combos[2], TRUE);
+  gtk_grid_attach (GTK_GRID (chooser->grid), chooser->access_combos[2], 1, row, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), chooser->access_combos[2]);
   gtk_widget_show (chooser->access_combos[2]);
 
   row += 1;
 
   separator = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
-  gtk_table_attach (GTK_TABLE (chooser->table), separator, 0, 2, row, row + 1, GTK_FILL, GTK_FILL, 0, 6);
+  gtk_grid_attach (GTK_GRID (chooser->grid), separator, 0, row, 2, 1);
   gtk_widget_show (separator);
 
   row += 1;
@@ -263,7 +266,7 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
   label = gtk_label_new_with_mnemonic (_("Gro_up:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
-  gtk_table_attach (GTK_TABLE (chooser->table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (chooser->grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   chooser->group_combo = gtk_combo_box_new ();
@@ -273,7 +276,8 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
   gtk_combo_box_set_row_separator_func (GTK_COMBO_BOX (chooser->group_combo), thunar_permissions_chooser_row_separator, NULL, NULL);
   exo_binding_new (G_OBJECT (chooser), "mutable", G_OBJECT (chooser->group_combo), "sensitive");
   g_signal_connect_swapped (G_OBJECT (chooser->group_combo), "changed", G_CALLBACK (thunar_permissions_chooser_group_changed), chooser);
-  gtk_table_attach (GTK_TABLE (chooser->table), chooser->group_combo, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (chooser->group_combo, TRUE);
+  gtk_grid_attach (GTK_GRID (chooser->grid), chooser->group_combo, 1, row, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), chooser->group_combo);
   gtk_widget_show (chooser->group_combo);
 
@@ -282,7 +286,7 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
   label = gtk_label_new_with_mnemonic (_("Acce_ss:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
-  gtk_table_attach (GTK_TABLE (chooser->table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (chooser->grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   chooser->access_combos[1] = gtk_combo_box_new ();
@@ -291,14 +295,15 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
   gtk_cell_layout_add_attribute (GTK_CELL_LAYOUT (chooser->access_combos[1]), renderer_text, "text", 0);
   exo_binding_new (G_OBJECT (chooser), "mutable", G_OBJECT (chooser->access_combos[1]), "sensitive");
   g_signal_connect_swapped (G_OBJECT (chooser->access_combos[1]), "changed", G_CALLBACK (thunar_permissions_chooser_access_changed), chooser);
-  gtk_table_attach (GTK_TABLE (chooser->table), chooser->access_combos[1], 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (chooser->access_combos[1], TRUE);
+  gtk_grid_attach (GTK_GRID (chooser->grid), chooser->access_combos[1], 1, row, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), chooser->access_combos[1]);
   gtk_widget_show (chooser->access_combos[1]);
 
   row += 1;
 
   separator = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
-  gtk_table_attach (GTK_TABLE (chooser->table), separator, 0, 2, row, row + 1, GTK_FILL, GTK_FILL, 0, 6);
+  gtk_grid_attach (GTK_GRID (chooser->grid), separator, 0, row, 2, 1);
   gtk_widget_show (separator);
 
   row += 1;
@@ -306,7 +311,7 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
   label = gtk_label_new_with_mnemonic (_("O_thers:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
-  gtk_table_attach (GTK_TABLE (chooser->table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (chooser->grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   chooser->access_combos[0] = gtk_combo_box_new ();
@@ -315,14 +320,15 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
   gtk_cell_layout_add_attribute (GTK_CELL_LAYOUT (chooser->access_combos[0]), renderer_text, "text", 0);
   exo_binding_new (G_OBJECT (chooser), "mutable", G_OBJECT (chooser->access_combos[0]), "sensitive");
   g_signal_connect_swapped (G_OBJECT (chooser->access_combos[0]), "changed", G_CALLBACK (thunar_permissions_chooser_access_changed), chooser);
-  gtk_table_attach (GTK_TABLE (chooser->table), chooser->access_combos[0], 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (chooser->access_combos[0], TRUE);
+  gtk_grid_attach (GTK_GRID (chooser->grid), chooser->access_combos[0], 1, row, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), chooser->access_combos[0]);
   gtk_widget_show (chooser->access_combos[0]);
 
   row += 1;
 
   separator = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
-  gtk_table_attach (GTK_TABLE (chooser->table), separator, 0, 2, row, row + 1, GTK_FILL, GTK_FILL, 0, 6);
+  gtk_grid_attach (GTK_GRID (chooser->grid), separator, 0, row, 2, 1);
   gtk_widget_show (separator);
 
   row += 1;
@@ -330,14 +336,14 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
   label = gtk_label_new (_("Program:"));
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
-  gtk_table_attach (GTK_TABLE (chooser->table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (chooser->grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   chooser->program_button = gtk_check_button_new_with_mnemonic (_("Allow this file to _run as a program"));
   exo_binding_new (G_OBJECT (chooser->program_button), "visible", G_OBJECT (label), "visible");
   exo_binding_new (G_OBJECT (chooser), "mutable", G_OBJECT (chooser->program_button), "sensitive");
   g_signal_connect_swapped (G_OBJECT (chooser->program_button), "toggled", G_CALLBACK (thunar_permissions_chooser_program_toggled), chooser);
-  gtk_table_attach (GTK_TABLE (chooser->table), chooser->program_button, 1, 2, row, row + 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (chooser->grid), chooser->program_button, 1, row, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), chooser->program_button);
   gtk_widget_show (chooser->program_button);
 
@@ -346,7 +352,7 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
   hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
   exo_binding_new (G_OBJECT (chooser), "mutable", G_OBJECT (hbox), "sensitive");
   exo_binding_new (G_OBJECT (chooser->program_button), "visible", G_OBJECT (hbox), "visible");
-  gtk_table_attach (GTK_TABLE (chooser->table), hbox, 1, 2, row, row + 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (chooser->grid), hbox, 1, row, 1, 1);
   gtk_widget_show (hbox);
 
   image = gtk_image_new_from_icon_name ("dialog-warning", GTK_ICON_SIZE_LARGE_TOOLBAR);
@@ -361,7 +367,7 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
 
   hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
   exo_binding_new (G_OBJECT (chooser), "mutable", G_OBJECT (hbox), "sensitive");
-  gtk_table_attach (GTK_TABLE (chooser->table), hbox, 1, 2, row, row + 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (chooser->grid), hbox, 1, row, 1, 1);
   gtk_widget_show (hbox);
 
   image = gtk_image_new_from_icon_name ("dialog-warning", GTK_ICON_SIZE_LARGE_TOOLBAR);
@@ -378,7 +384,7 @@ thunar_permissions_chooser_init (ThunarPermissionsChooser *chooser)
   row += 1;
 
   hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
-  gtk_table_attach (GTK_TABLE (chooser->table), hbox, 1, 2, row, row + 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (chooser->grid), hbox, 1, row, 1, 1);
   gtk_widget_show (hbox);
 
   chooser->fixperm_button = gtk_button_new_with_mnemonic (_("Correct _folder permissions..."));
@@ -1218,7 +1224,7 @@ thunar_permissions_chooser_job_cancel (ThunarPermissionsChooser *chooser)
   gtk_widget_hide (chooser->job_progress);
 
   /* make the remaining widgets sensitive again */
-  gtk_widget_set_sensitive (chooser->table, TRUE);
+  gtk_widget_set_sensitive (chooser->grid, TRUE);
 }
 
 
@@ -1301,7 +1307,7 @@ thunar_permissions_chooser_job_start (ThunarPermissionsChooser *chooser,
   gtk_progress_bar_set_fraction (GTK_PROGRESS_BAR (chooser->job_progress), 0.0);
 
   /* make the majority of widgets insensitive if doing recursively */
-  gtk_widget_set_sensitive (chooser->table, !recursive);
+  gtk_widget_set_sensitive (chooser->grid, !recursive);
 }
 
 
diff --git a/thunar/thunar-preferences-dialog.c b/thunar/thunar-preferences-dialog.c
index 9feb381..3c67329 100644
--- a/thunar/thunar-preferences-dialog.c
+++ b/thunar/thunar-preferences-dialog.c
@@ -209,7 +209,7 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   GtkWidget      *frame;
   GtkWidget      *label;
   GtkWidget      *range;
-  GtkWidget      *table;
+  GtkWidget      *grid;
   GtkWidget      *hbox;
   GtkWidget      *ibox;
   GtkWidget      *vbox;
@@ -254,16 +254,16 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_frame_set_label_widget (GTK_FRAME (frame), label);
   gtk_widget_show (label);
 
-  table = gtk_table_new (4, 3, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_container_set_border_width (GTK_CONTAINER (table), 12);
-  gtk_container_add (GTK_CONTAINER (frame), table);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 12);
+  gtk_container_add (GTK_CONTAINER (frame), grid);
+  gtk_widget_show (grid);
 
   label = gtk_label_new_with_mnemonic (_("View _new folders using:"));
   gtk_label_set_xalign (GTK_LABEL (label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 0, 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 1, 1);
   gtk_widget_show (label);
 
   combo = gtk_combo_box_text_new ();
@@ -273,14 +273,15 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_combo_box_text_append_text (GTK_COMBO_BOX_TEXT (combo), _("Last Active View"));
   exo_mutual_binding_new_full (G_OBJECT (dialog->preferences), "default-view", G_OBJECT (combo), "active",
                                transform_view_string_to_index, transform_view_index_to_string, NULL, NULL);
-  gtk_table_attach (GTK_TABLE (table), combo, 1, 2, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (combo, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), combo, 1, 0, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), combo);
   gtk_label_set_mnemonic_widget (GTK_LABEL (label), combo);
   gtk_widget_show (combo);
 
   label = gtk_label_new_with_mnemonic (_("Show thumbnails:"));
   gtk_label_set_xalign (GTK_LABEL (label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 1, 2, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 1, 1, 1);
   gtk_widget_show (label);
 
   combo = gtk_combo_box_text_new ();
@@ -289,7 +290,8 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_combo_box_text_append_text (GTK_COMBO_BOX_TEXT (combo), _("Always"));
   exo_mutual_binding_new_full (G_OBJECT (dialog->preferences), "misc-thumbnail-mode", G_OBJECT (combo), "active",
                                transform_thumbnail_mode_to_index, transform_thumbnail_index_to_mode, NULL, NULL);
-  gtk_table_attach (GTK_TABLE (table), combo, 1, 2, 1, 2, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (combo, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), combo, 1, 1, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), combo);
   gtk_label_set_mnemonic_widget (GTK_LABEL (label), combo);
   gtk_widget_show (combo);
@@ -297,13 +299,15 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   button = gtk_check_button_new_with_mnemonic (_("Sort _folders before files"));
   exo_mutual_binding_new (G_OBJECT (dialog->preferences), "misc-folders-first", G_OBJECT (button), "active");
   gtk_widget_set_tooltip_text (button, _("Select this option to list folders before files when you sort a folder."));
-  gtk_table_attach (GTK_TABLE (table), button, 0, 2, 2, 3, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (button, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), button, 0, 2, 2, 1);
   gtk_widget_show (button);
 
   button = gtk_check_button_new_with_mnemonic (_("Show file size in binary format"));
   exo_mutual_binding_new (G_OBJECT (dialog->preferences), "misc-file-size-binary", G_OBJECT (button), "active");
   gtk_widget_set_tooltip_text (button, _("Select this option to show file size in binary format instead of decimal."));
-  gtk_table_attach (GTK_TABLE (table), button, 0, 2, 3, 4, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (button, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), button, 0, 3, 2, 1);
   gtk_widget_show (button);
 
   frame = g_object_new (GTK_TYPE_FRAME, "border-width", 0, "shadow-type", GTK_SHADOW_NONE, NULL);
@@ -315,18 +319,19 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_frame_set_label_widget (GTK_FRAME (frame), label);
   gtk_widget_show (label);
 
-  table = gtk_table_new (1, 1, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_container_set_border_width (GTK_CONTAINER (table), 12);
-  gtk_container_add (GTK_CONTAINER (frame), table);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 12);
+  gtk_container_add (GTK_CONTAINER (frame), grid);
+  gtk_widget_show (grid);
 
   button = gtk_check_button_new_with_mnemonic (_("_Text beside icons"));
   exo_mutual_binding_new (G_OBJECT (dialog->preferences), "misc-text-beside-icons", G_OBJECT (button), "active");
   gtk_widget_set_tooltip_text (button, _("Select this option to place the icon captions for items "
                                          "beside the icon rather than below the icon."));
-  gtk_table_attach (GTK_TABLE (table), button, 0, 1, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (button, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), button, 0, 0, 1, 1);
   gtk_widget_show (button);
 
   frame = g_object_new (GTK_TYPE_FRAME, "border-width", 0, "shadow-type", GTK_SHADOW_NONE, NULL);
@@ -338,15 +343,15 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_frame_set_label_widget (GTK_FRAME (frame), label);
   gtk_widget_show (label);
 
-  table = gtk_table_new (1, 2, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_container_set_border_width (GTK_CONTAINER (table), 12);
-  gtk_container_add (GTK_CONTAINER (frame), table);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 12);
+  gtk_container_add (GTK_CONTAINER (frame), grid);
+  gtk_widget_show (grid);
 
   label = gtk_label_new_with_mnemonic (_("_Format:"));
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 0, 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 1, 1);
   gtk_widget_show (label);
 
   combo = gtk_combo_box_text_new ();
@@ -357,7 +362,8 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
       g_free (date);
     }
   exo_mutual_binding_new (G_OBJECT (dialog->preferences), "misc-date-style", G_OBJECT (combo), "active");
-  gtk_table_attach (GTK_TABLE (table), combo, 1, 2, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (combo, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), combo, 1, 0, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), combo);
   gtk_label_set_mnemonic_widget (GTK_LABEL (label), combo);
   gtk_widget_show (combo);
@@ -381,15 +387,15 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_frame_set_label_widget (GTK_FRAME (frame), label);
   gtk_widget_show (label);
 
-  table = gtk_table_new (2, 2, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_container_set_border_width (GTK_CONTAINER (table), 12);
-  gtk_container_add (GTK_CONTAINER (frame), table);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 12);
+  gtk_container_add (GTK_CONTAINER (frame), grid);
+  gtk_widget_show (grid);
 
   label = gtk_label_new_with_mnemonic (_("_Icon Size:"));
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 0, 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 1, 1);
   gtk_widget_show (label);
 
   combo = gtk_combo_box_text_new ();
@@ -402,7 +408,8 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_combo_box_text_append_text (GTK_COMBO_BOX_TEXT (combo), _("Very Large"));
   exo_mutual_binding_new_full (G_OBJECT (dialog->preferences), "shortcuts-icon-size", G_OBJECT (combo), "active",
                                transform_icon_size_to_index, transform_index_to_icon_size, NULL, NULL);
-  gtk_table_attach (GTK_TABLE (table), combo, 1, 2, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (combo, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), combo, 1, 0, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), combo);
   gtk_label_set_mnemonic_widget (GTK_LABEL (label), combo);
   gtk_widget_show (combo);
@@ -411,7 +418,8 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   exo_mutual_binding_new (G_OBJECT (dialog->preferences), "shortcuts-icon-emblems", G_OBJECT (button), "active");
   gtk_widget_set_tooltip_text (button, _("Select this option to display icon emblems in the shortcuts pane for all folders "
                                          "for which emblems have been defined in the folders properties dialog."));
-  gtk_table_attach (GTK_TABLE (table), button, 0, 2, 1, 2, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (button, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), button, 0, 1, 2, 1);
   gtk_widget_show (button);
 
   frame = g_object_new (GTK_TYPE_FRAME, "border-width", 0, "shadow-type", GTK_SHADOW_NONE, NULL);
@@ -423,15 +431,15 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_frame_set_label_widget (GTK_FRAME (frame), label);
   gtk_widget_show (label);
 
-  table = gtk_table_new (2, 2, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_container_set_border_width (GTK_CONTAINER (table), 12);
-  gtk_container_add (GTK_CONTAINER (frame), table);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 12);
+  gtk_container_add (GTK_CONTAINER (frame), grid);
+  gtk_widget_show (grid);
 
   label = gtk_label_new_with_mnemonic (_("Icon _Size:"));
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 0, 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 1, 1);
   gtk_widget_show (label);
 
   combo = gtk_combo_box_text_new ();
@@ -444,7 +452,8 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_combo_box_text_append_text (GTK_COMBO_BOX_TEXT (combo), _("Very Large"));
   exo_mutual_binding_new_full (G_OBJECT (dialog->preferences), "tree-icon-size", G_OBJECT (combo), "active",
                                transform_icon_size_to_index, transform_index_to_icon_size, NULL, NULL);
-  gtk_table_attach (GTK_TABLE (table), combo, 1, 2, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (combo, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), combo, 1, 0, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), combo);
   gtk_label_set_mnemonic_widget (GTK_LABEL (label), combo);
   gtk_widget_show (combo);
@@ -453,7 +462,8 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   exo_mutual_binding_new (G_OBJECT (dialog->preferences), "tree-icon-emblems", G_OBJECT (button), "active");
   gtk_widget_set_tooltip_text (button, _("Select this option to display icon emblems in the tree pane for all folders "
                                          "for which emblems have been defined in the folders properties dialog."));
-  gtk_table_attach (GTK_TABLE (table), button, 0, 2, 1, 2, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (button, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), button, 0, 1, 2, 1);
   gtk_widget_show (button);
 
 
@@ -475,17 +485,18 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_frame_set_label_widget (GTK_FRAME (frame), label);
   gtk_widget_show (label);
 
-  table = gtk_table_new (3, 1, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_container_set_border_width (GTK_CONTAINER (table), 12);
-  gtk_container_add (GTK_CONTAINER (frame), table);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 12);
+  gtk_container_add (GTK_CONTAINER (frame), grid);
+  gtk_widget_show (grid);
 
   button = gtk_radio_button_new_with_mnemonic (NULL, _("_Single click to activate items"));
   exo_mutual_binding_new (G_OBJECT (dialog->preferences), "misc-single-click", G_OBJECT (button), "active");
   g_signal_connect (G_OBJECT (button), "toggled", G_CALLBACK (g_object_notify), "active");
-  gtk_table_attach (GTK_TABLE (table), button, 0, 1, 0, 1, GTK_EXPAND | GTK_FILL, 0, 0, 0);
+  gtk_widget_set_hexpand (button, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), button, 0, 0, 1, 1);
   gtk_widget_show (button);
 
   ibox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
@@ -493,7 +504,8 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_widget_set_margin_bottom (ibox, 6);
   gtk_widget_set_margin_start (ibox, 18);
   exo_binding_new (G_OBJECT (button), "active", G_OBJECT (ibox), "sensitive");
-  gtk_table_attach (GTK_TABLE (table), ibox, 0, 1, 1, 2, GTK_EXPAND | GTK_FILL, 0, 0, 0);
+  gtk_widget_set_hexpand (ibox, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), ibox, 0, 1, 1, 1);
   gtk_widget_show (ibox);
 
   label = gtk_label_new_with_mnemonic (_("Specify the d_elay before an item gets selected\n"
@@ -548,7 +560,8 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   button = gtk_radio_button_new_with_mnemonic_from_widget (GTK_RADIO_BUTTON (button), _("_Double click to activate items"));
   exo_mutual_binding_new_with_negation (G_OBJECT (dialog->preferences), "misc-single-click", G_OBJECT (button), "active");
   g_signal_connect (G_OBJECT (button), "toggled", G_CALLBACK (g_object_notify), "active");
-  gtk_table_attach (GTK_TABLE (table), button, 0, 1, 2, 3, GTK_EXPAND | GTK_FILL, 0, 0, 0);
+  gtk_widget_set_hexpand (button, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), button, 0, 2, 1, 1);
   gtk_widget_show (button);
 
   frame = g_object_new (GTK_TYPE_FRAME, "border-width", 0, "shadow-type", GTK_SHADOW_NONE, NULL);
@@ -594,19 +607,19 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_frame_set_label_widget (GTK_FRAME (frame), label);
   gtk_widget_show (label);
 
-  table = gtk_table_new (2, 2, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_container_set_border_width (GTK_CONTAINER (table), 12);
-  gtk_container_add (GTK_CONTAINER (frame), table);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 12);
+  gtk_container_add (GTK_CONTAINER (frame), grid);
+  gtk_widget_show (grid);
 
   label = gtk_label_new_with_mnemonic (_("When changing the permissions of a folder, you\n"
                                          "can also apply the changes to the contents of the\n"
                                          "folder. Select the default behavior below:"));
   gtk_label_set_xalign (GTK_LABEL (label), 0.0f);
   gtk_label_set_yalign (GTK_LABEL (label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 0, 1, GTK_FILL, GTK_FILL, 0, 0);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 0, 1, 1);
   gtk_widget_show (label);
 
   combo = gtk_combo_box_text_new ();
@@ -614,7 +627,8 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_combo_box_text_append_text (GTK_COMBO_BOX_TEXT (combo), _("Apply to Folder Only"));
   gtk_combo_box_text_append_text (GTK_COMBO_BOX_TEXT (combo), _("Apply to Folder and Contents"));
   exo_mutual_binding_new (G_OBJECT (dialog->preferences), "misc-recursive-permissions", G_OBJECT (combo), "active");
-  gtk_table_attach (GTK_TABLE (table), combo, 0, 1, 1, 2, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (combo, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), combo, 0, 1, 1, 1);
   thunar_gtk_label_set_a11y_relation (GTK_LABEL (label), combo);
   gtk_widget_show (combo);
 
@@ -627,12 +641,12 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   gtk_frame_set_label_widget (GTK_FRAME (frame), label);
   gtk_widget_show (label);
 
-  table = gtk_table_new (2, 2, FALSE);
-  gtk_table_set_row_spacings (GTK_TABLE (table), 6);
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_container_set_border_width (GTK_CONTAINER (table), 12);
-  gtk_container_add (GTK_CONTAINER (frame), table);
-  gtk_widget_show (table);
+  grid = gtk_grid_new ();
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 12);
+  gtk_container_add (GTK_CONTAINER (frame), grid);
+  gtk_widget_show (grid);
 
   /* check if "thunar-volman" is found */
   path = g_find_program_in_path ("thunar-volman");
@@ -640,7 +654,8 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   /* add check button to enable/disable auto mounting */
   button = gtk_check_button_new_with_mnemonic (_("Enable _Volume Management"));
   exo_mutual_binding_new (G_OBJECT (dialog->preferences), "misc-volume-management", G_OBJECT (button), "active");
-  gtk_table_attach (GTK_TABLE (table), button, 0, 1, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (button, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), button, 0, 0, 1, 1);
   gtk_widget_show (button);
 
   label = gtk_label_new (NULL);
@@ -649,7 +664,8 @@ thunar_preferences_dialog_init (ThunarPreferencesDialog *dialog)
   g_signal_connect_swapped (G_OBJECT (label), "activate-link", G_CALLBACK (thunar_preferences_dialog_configure), dialog);
   gtk_label_set_markup (GTK_LABEL (label), _("<a href=\"volman-config:\">Configure</a> the management of removable drives\n"
                                              "and media (i.e. how cameras should be handled)."));
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, 1, 2, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, 1, 1, 1);
   gtk_widget_show (label);
 
   /* cleanup */
diff --git a/thunar/thunar-properties-dialog.c b/thunar/thunar-properties-dialog.c
index 9b0cf45..e4d0dc8 100644
--- a/thunar/thunar-properties-dialog.c
+++ b/thunar/thunar-properties-dialog.c
@@ -226,7 +226,7 @@ static void
 thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
 {
   GtkWidget *chooser;
-  GtkWidget *table;
+  GtkWidget *grid;
   GtkWidget *label;
   GtkWidget *box;
   GtkWidget *spacer;
@@ -260,20 +260,21 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   gtk_box_pack_start (GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dialog))), dialog->notebook, TRUE, TRUE, 0);
   gtk_widget_show (dialog->notebook);
 
-  table = gtk_table_new (16, 2, FALSE);
+  grid = gtk_grid_new ();
   label = gtk_label_new (_("General"));
-  gtk_table_set_col_spacings (GTK_TABLE (table), 12);
-  gtk_container_set_border_width (GTK_CONTAINER (table), 6);
-  gtk_notebook_append_page (GTK_NOTEBOOK (dialog->notebook), table, label);
+  gtk_grid_set_column_spacing (GTK_GRID (grid), 12);
+  gtk_grid_set_row_spacing (GTK_GRID (grid), 6);
+  gtk_container_set_border_width (GTK_CONTAINER (grid), 6);
+  gtk_notebook_append_page (GTK_NOTEBOOK (dialog->notebook), grid, label);
   gtk_widget_show (label);
-  gtk_widget_show (table);
+  gtk_widget_show (grid);
 
 
   /*
      First box (icon, name) for 1 file
    */
   dialog->single_box = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
-  gtk_table_attach (GTK_TABLE (table), dialog->single_box, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), dialog->single_box, 0, row, 1, 1);
 
   dialog->icon_button = gtk_button_new ();
   g_signal_connect (G_OBJECT (dialog->icon_button), "clicked", G_CALLBACK (thunar_properties_dialog_icon_button_clicked), dialog);
@@ -294,7 +295,8 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->name_entry);
   g_signal_connect (G_OBJECT (dialog->name_entry), "activate", G_CALLBACK (thunar_properties_dialog_name_activate), dialog);
   g_signal_connect (G_OBJECT (dialog->name_entry), "focus-out-event", G_CALLBACK (thunar_properties_dialog_name_focus_out_event), dialog);
-  gtk_table_attach (GTK_TABLE (table), dialog->name_entry, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (dialog->name_entry, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), dialog->name_entry, 1, row, 1, 1);
   exo_binding_new (G_OBJECT (dialog->single_box), "visible", G_OBJECT (dialog->name_entry), "visible");
 
   ++row;
@@ -304,7 +306,7 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
      First box (icon, name) for multiple files
    */
   box = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
-  gtk_table_attach (GTK_TABLE (table), box, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), box, 0, row, 1, 1);
   exo_binding_new_with_negation (G_OBJECT (dialog->single_box), "visible", G_OBJECT (box), "visible");
 
   image = gtk_image_new_from_icon_name ("text-x-generic", GTK_ICON_SIZE_DIALOG);
@@ -319,7 +321,8 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
 
   dialog->names_label = gtk_label_new ("");
   gtk_label_set_xalign (GTK_LABEL (dialog->names_label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), dialog->names_label, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (dialog->names_label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), dialog->names_label, 1, row, 1, 1);
   gtk_label_set_ellipsize (GTK_LABEL (dialog->names_label), PANGO_ELLIPSIZE_END);
   gtk_label_set_selectable (GTK_LABEL (dialog->names_label), TRUE);
   exo_binding_new (G_OBJECT (box), "visible", G_OBJECT (dialog->names_label), "visible");
@@ -334,14 +337,15 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   label = gtk_label_new (_("Kind:"));
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   dialog->kind_ebox = gtk_event_box_new ();
   gtk_event_box_set_above_child (GTK_EVENT_BOX (dialog->kind_ebox), TRUE);
   gtk_event_box_set_visible_window (GTK_EVENT_BOX (dialog->kind_ebox), FALSE);
   exo_binding_new (G_OBJECT (dialog->kind_ebox), "visible", G_OBJECT (label), "visible");
-  gtk_table_attach (GTK_TABLE (table), dialog->kind_ebox, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (dialog->kind_ebox, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), dialog->kind_ebox, 1, row, 1, 1);
   gtk_widget_show (dialog->kind_ebox);
 
   dialog->kind_label = g_object_new (GTK_TYPE_LABEL, "xalign", 0.0f, NULL);
@@ -355,13 +359,14 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   label = gtk_label_new_with_mnemonic (_("_Open With:"));
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   dialog->openwith_chooser = thunar_chooser_button_new ();
   gtk_label_set_mnemonic_widget (GTK_LABEL (label), dialog->openwith_chooser);
   exo_binding_new (G_OBJECT (dialog->openwith_chooser), "visible", G_OBJECT (label), "visible");
-  gtk_table_attach (GTK_TABLE (table), dialog->openwith_chooser, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (dialog->openwith_chooser, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), dialog->openwith_chooser, 1, row, 1, 1);
   gtk_widget_show (dialog->openwith_chooser);
 
   ++row;
@@ -369,13 +374,14 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   label = gtk_label_new (_("Link Target:"));
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   dialog->link_label = g_object_new (GTK_TYPE_LABEL, "ellipsize", PANGO_ELLIPSIZE_START, "xalign", 0.0f, NULL);
   gtk_label_set_selectable (GTK_LABEL (dialog->link_label), TRUE);
   exo_binding_new (G_OBJECT (dialog->link_label), "visible", G_OBJECT (label), "visible");
-  gtk_table_attach (GTK_TABLE (table), dialog->link_label, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (dialog->link_label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), dialog->link_label, 1, row, 1, 1);
   gtk_widget_show (dialog->link_label);
 
   ++row;
@@ -387,13 +393,14 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   label = gtk_label_new (_("Original Path:"));
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   dialog->origin_label = g_object_new (GTK_TYPE_LABEL, "ellipsize", PANGO_ELLIPSIZE_START, "xalign", 0.0f, NULL);
   gtk_label_set_selectable (GTK_LABEL (dialog->origin_label), TRUE);
   exo_binding_new (G_OBJECT (dialog->origin_label), "visible", G_OBJECT (label), "visible");
-  gtk_table_attach (GTK_TABLE (table), dialog->origin_label, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (dialog->origin_label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), dialog->origin_label, 1, row, 1, 1);
   gtk_widget_show (dialog->origin_label);
 
   ++row;
@@ -401,20 +408,21 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   label = gtk_label_new (_("Location:"));
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   dialog->location_label = g_object_new (GTK_TYPE_LABEL, "ellipsize", PANGO_ELLIPSIZE_START, "xalign", 0.0f, NULL);
   gtk_label_set_selectable (GTK_LABEL (dialog->location_label), TRUE);
   exo_binding_new (G_OBJECT (dialog->location_label), "visible", G_OBJECT (label), "visible");
-  gtk_table_attach (GTK_TABLE (table), dialog->location_label, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (dialog->location_label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), dialog->location_label, 1, row, 1, 1);
   gtk_widget_show (dialog->location_label);
 
   ++row;
 
 
   spacer = g_object_new (GTK_TYPE_BOX, "orientation", GTK_ORIENTATION_VERTICAL, "height-request", 12, NULL);
-  gtk_table_attach (GTK_TABLE (table), spacer, 0, 2, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), spacer, 0, row, 2, 1);
   gtk_widget_show (spacer);
 
   ++row;
@@ -426,13 +434,14 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   label = gtk_label_new (_("Deleted:"));
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   dialog->deleted_label = g_object_new (GTK_TYPE_LABEL, "xalign", 0.0f, NULL);
   gtk_label_set_selectable (GTK_LABEL (dialog->deleted_label), TRUE);
   exo_binding_new (G_OBJECT (dialog->deleted_label), "visible", G_OBJECT (label), "visible");
-  gtk_table_attach (GTK_TABLE (table), dialog->deleted_label, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (dialog->deleted_label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), dialog->deleted_label, 1, row, 1, 1);
   gtk_widget_show (dialog->deleted_label);
 
   ++row;
@@ -440,13 +449,14 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   label = gtk_label_new (_("Modified:"));
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   dialog->modified_label = g_object_new (GTK_TYPE_LABEL, "xalign", 0.0f, NULL);
   gtk_label_set_selectable (GTK_LABEL (dialog->modified_label), TRUE);
   exo_binding_new (G_OBJECT (dialog->modified_label), "visible", G_OBJECT (label), "visible");
-  gtk_table_attach (GTK_TABLE (table), dialog->modified_label, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (dialog->modified_label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), dialog->modified_label, 1, row, 1, 1);
   gtk_widget_show (dialog->modified_label);
 
   ++row;
@@ -454,20 +464,21 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   label = gtk_label_new (_("Accessed:"));
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   dialog->accessed_label = g_object_new (GTK_TYPE_LABEL, "xalign", 0.0f, NULL);
   gtk_label_set_selectable (GTK_LABEL (dialog->accessed_label), TRUE);
   exo_binding_new (G_OBJECT (dialog->accessed_label), "visible", G_OBJECT (label), "visible");
-  gtk_table_attach (GTK_TABLE (table), dialog->accessed_label, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (dialog->accessed_label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), dialog->accessed_label, 1, row, 1, 1);
   gtk_widget_show (dialog->accessed_label);
 
   ++row;
 
 
   spacer = g_object_new (GTK_TYPE_BOX, "orientation", GTK_ORIENTATION_VERTICAL, "height-request", 12, NULL);
-  gtk_table_attach (GTK_TABLE (table), spacer, 0, 2, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), spacer, 0, row, 2, 1);
   exo_binding_new (G_OBJECT (dialog->accessed_label), "visible", G_OBJECT (spacer), "visible");
 
   ++row;
@@ -479,12 +490,13 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   label = gtk_label_new (_("Size:"));
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   label = thunar_size_label_new ();
   exo_binding_new (G_OBJECT (dialog), "files", G_OBJECT (label), "files");
-  gtk_table_attach (GTK_TABLE (table), label, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (label, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), label, 1, row, 1, 1);
   gtk_widget_show (label);
 
   ++row;
@@ -492,12 +504,13 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   label = gtk_label_new (_("Volume:"));
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   box = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
   exo_binding_new (G_OBJECT (box), "visible", G_OBJECT (label), "visible");
-  gtk_table_attach (GTK_TABLE (table), box, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (box, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), box, 1, row, 1, 1);
   gtk_widget_show (box);
 
   dialog->volume_image = gtk_image_new ();
@@ -517,11 +530,12 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   gtk_label_set_attributes (GTK_LABEL (label), thunar_pango_attr_list_bold ());
   gtk_label_set_xalign (GTK_LABEL (label), 1.0f);
   gtk_label_set_yalign (GTK_LABEL (label), 0.0f);
-  gtk_table_attach (GTK_TABLE (table), label, 0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), label, 0, row, 1, 1);
   gtk_widget_show (label);
 
   dialog->freespace_vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 4);
-  gtk_table_attach (GTK_TABLE (table), dialog->freespace_vbox, 1, 2, row, row + 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 3);
+  gtk_widget_set_hexpand (dialog->freespace_vbox, TRUE);
+  gtk_grid_attach (GTK_GRID (grid), dialog->freespace_vbox, 1, row, 1, 1);
   exo_binding_new (G_OBJECT (dialog->freespace_vbox), "visible", G_OBJECT (label), "visible");
   gtk_widget_show (dialog->freespace_vbox);
 
@@ -538,7 +552,7 @@ thunar_properties_dialog_init (ThunarPropertiesDialog *dialog)
   ++row;
 
   spacer = g_object_new (GTK_TYPE_BOX, "orientation", GTK_ORIENTATION_VERTICAL, "height-request", 12, NULL);
-  gtk_table_attach (GTK_TABLE (table), spacer, 0, 2, row, row + 1, GTK_FILL, GTK_FILL, 0, 3);
+  gtk_grid_attach (GTK_GRID (grid), spacer, 0, row, 2, 1);
   gtk_widget_show (spacer);
 
   ++row;
diff --git a/thunar/thunar-window.c b/thunar/thunar-window.c
index 0cbdb82..f648efc 100644
--- a/thunar/thunar-window.c
+++ b/thunar/thunar-window.c
@@ -306,7 +306,7 @@ struct _ThunarWindow
   GtkActionGroup         *custom_actions;
   guint                   custom_merge_id;
 
-  GtkWidget              *table;
+  GtkWidget              *grid;
   GtkWidget              *menubar;
   GtkWidget              *spinner;
   GtkWidget              *paned;
@@ -812,12 +812,13 @@ thunar_window_init (ThunarWindow *window)
   if (G_UNLIKELY (last_window_maximized))
     gtk_window_maximize (GTK_WINDOW (window));
 
-  window->table = gtk_table_new (6, 1, FALSE);
-  gtk_container_add (GTK_CONTAINER (window), window->table);
-  gtk_widget_show (window->table);
+  window->grid = gtk_grid_new ();
+  gtk_container_add (GTK_CONTAINER (window), window->grid);
+  gtk_widget_show (window->grid);
 
   window->menubar = gtk_ui_manager_get_widget (window->ui_manager, "/main-menu");
-  gtk_table_attach (GTK_TABLE (window->table), window->menubar, 0, 1, 0, 1, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (window->menubar, TRUE);
+  gtk_grid_attach (GTK_GRID (window->grid), window->menubar, 0, 0, 1, 1);
 
   /* update menubar visibiliy */
   action = gtk_action_group_get_action (window->action_group, "view-menubar");
@@ -843,7 +844,8 @@ thunar_window_init (ThunarWindow *window)
       /* add the bar for the root warning */
       infobar = gtk_info_bar_new ();
       gtk_info_bar_set_message_type (GTK_INFO_BAR (infobar), GTK_MESSAGE_WARNING);
-      gtk_table_attach (GTK_TABLE (window->table), infobar, 0, 1, 2, 3, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+      gtk_widget_set_hexpand (infobar, TRUE);
+      gtk_grid_attach (GTK_GRID (window->grid), infobar, 0, 2, 1, 1);
       gtk_widget_show (infobar);
 
       /* add the label with the root warning */
@@ -854,7 +856,9 @@ thunar_window_init (ThunarWindow *window)
 
   window->paned = gtk_paned_new (GTK_ORIENTATION_HORIZONTAL);
   gtk_container_set_border_width (GTK_CONTAINER (window->paned), 0);
-  gtk_table_attach (GTK_TABLE (window->table), window->paned, 0, 1, 4, 5, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (window->paned, TRUE);
+  gtk_widget_set_vexpand (window->paned, TRUE);
+  gtk_grid_attach (GTK_GRID (window->grid), window->paned, 0, 4, 1, 1);
   gtk_widget_show (window->paned);
 
   /* determine the last separator position and apply it to the paned view */
@@ -862,13 +866,15 @@ thunar_window_init (ThunarWindow *window)
   g_signal_connect_swapped (window->paned, "accept-position", G_CALLBACK (thunar_window_save_paned), window);
   g_signal_connect_swapped (window->paned, "button-release-event", G_CALLBACK (thunar_window_save_paned), window);
 
-  window->view_box = gtk_table_new (3, 1, FALSE);
+  window->view_box = gtk_grid_new ();
   gtk_paned_pack2 (GTK_PANED (window->paned), window->view_box, TRUE, FALSE);
   gtk_widget_show (window->view_box);
 
   /* tabs */
   window->notebook = gtk_notebook_new ();
-  gtk_table_attach (GTK_TABLE (window->view_box), window->notebook, 0, 1, 1, 2, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (window->notebook, TRUE);
+  gtk_widget_set_vexpand (window->notebook, TRUE);
+  gtk_grid_attach (GTK_GRID (window->view_box), window->notebook, 0, 1, 1, 1);
   g_signal_connect (G_OBJECT (window->notebook), "switch-page", G_CALLBACK (thunar_window_notebook_switch_page), window);
   g_signal_connect (G_OBJECT (window->notebook), "page-added", G_CALLBACK (thunar_window_notebook_page_added), window);
   g_signal_connect (G_OBJECT (window->notebook), "page-removed", G_CALLBACK (thunar_window_notebook_page_removed), window);
@@ -900,7 +906,8 @@ thunar_window_init (ThunarWindow *window)
   gtk_toolbar_set_style (GTK_TOOLBAR (window->location_toolbar), GTK_TOOLBAR_ICONS);
   gtk_toolbar_set_icon_size (GTK_TOOLBAR (window->location_toolbar),
                               small_icons ? GTK_ICON_SIZE_SMALL_TOOLBAR : GTK_ICON_SIZE_LARGE_TOOLBAR);
-  gtk_table_attach (GTK_TABLE (window->table), window->location_toolbar, 0, 1, 1, 2, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+  gtk_widget_set_hexpand (window->location_toolbar, TRUE);
+  gtk_grid_attach (GTK_GRID (window->grid), window->location_toolbar, 0, 1, 1, 1);
 
   /* add the location bar tool item */
   tool_item = gtk_tool_item_new ();
@@ -2598,7 +2605,8 @@ thunar_window_action_statusbar_changed (GtkToggleAction *action,
     {
       /* setup a new statusbar */
       window->statusbar = thunar_statusbar_new ();
-      gtk_table_attach (GTK_TABLE (window->view_box), window->statusbar, 0, 1, 2, 3, GTK_EXPAND | GTK_FILL, GTK_FILL, 0, 0);
+      gtk_widget_set_hexpand (window->statusbar, TRUE);
+      gtk_grid_attach (GTK_GRID (window->view_box), window->statusbar, 0, 2, 1, 1);
       gtk_widget_show (window->statusbar);
 
       /* connect to the view (if any) */

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Xfce4-commits mailing list