gnucash maint: Multiple changes pushed

Robert Fewell bobit at code.gnucash.org
Tue Nov 3 09:12:09 EST 2020


Updated	 via  https://github.com/Gnucash/gnucash/commit/d867a9d5 (commit)
	 via  https://github.com/Gnucash/gnucash/commit/0382859e (commit)
	 via  https://github.com/Gnucash/gnucash/commit/48fe2ea6 (commit)
	 via  https://github.com/Gnucash/gnucash/commit/bf483696 (commit)
	 via  https://github.com/Gnucash/gnucash/commit/aa71e469 (commit)
	 via  https://github.com/Gnucash/gnucash/commit/761797eb (commit)
	 via  https://github.com/Gnucash/gnucash/commit/504ca731 (commit)
	 via  https://github.com/Gnucash/gnucash/commit/c40ac765 (commit)
	 via  https://github.com/Gnucash/gnucash/commit/39827ce7 (commit)
	from  https://github.com/Gnucash/gnucash/commit/7b06b932 (commit)



commit d867a9d50d2ca0796f38486803814c5ce70661fb
Author: Robert Fewell <14uBobIT at gmail.com>
Date:   Tue Nov 3 14:07:52 2020 +0000

    Set the visibility of the account column in import-main-matcher
    
    After the import-main-matcher is shown, set the visibility of the
    account column based on the number of accounts being displayed.

diff --git a/gnucash/import-export/import-main-matcher.c b/gnucash/import-export/import-main-matcher.c
index 82ad17f17..92d3f7b08 100644
--- a/gnucash/import-export/import-main-matcher.c
+++ b/gnucash/import-export/import-main-matcher.c
@@ -235,6 +235,60 @@ gnc_gen_trans_list_empty (GNCImportMainMatcher *info)
     return !gtk_tree_model_get_iter_first (model, &iter) && !info->temp_trans_list;
 }
 
+static void
+gnc_gen_trans_list_show_accounts_column (GNCImportMainMatcher *info)
+{
+    GtkTreeModel *model;
+    GtkTreeIter iter;
+    GNCImportTransInfo *trans_info;
+    gboolean multiple_accounts = FALSE;
+    gboolean valid;
+
+    g_assert (info);
+
+    model = gtk_tree_view_get_model (info->view);
+
+    if (gtk_tree_model_iter_n_children (model, NULL) > 1)
+    {
+        /* Get first row in list store */
+        valid = gtk_tree_model_get_iter_first (model, &iter);
+        if (valid)
+        {
+            gchar *account_name;
+            gtk_tree_model_get (model, &iter, DOWNLOADED_COL_ACCOUNT, &account_name, -1);
+
+            valid = gtk_tree_model_iter_next (model, &iter);
+
+            while (valid)
+            {
+                gchar *test_account_name;
+
+                gtk_tree_model_get (model, &iter, DOWNLOADED_COL_ACCOUNT, &test_account_name, -1);
+                if (g_strcmp0 (account_name, test_account_name) != 0)
+                {
+                     multiple_accounts = TRUE;
+                     g_free (test_account_name);
+                     break;
+                }
+                valid = gtk_tree_model_iter_next (model, &iter);
+                g_free (test_account_name);
+            }
+            g_free (account_name);
+        }
+        // now toggle the column
+        if (multiple_accounts)
+        {
+            gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON(info->show_account_column), TRUE);
+            gtk_tree_view_expand_all (info->view);
+        }
+        else
+        {
+            gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON(info->show_account_column), FALSE);
+            gtk_tree_view_collapse_all (info->view);
+        }
+    }
+}
+
 // This returns the transaction ID of the first match candidate in match_list
 static const GncGUID*
 get_top_trans_match_id (GList* match_list)
@@ -395,6 +449,7 @@ gnc_gen_trans_list_show_all (GNCImportMainMatcher *info)
     gnc_gen_trans_list_create_matches (info);
     resolve_conflicts (info);
     gtk_widget_show_all (GTK_WIDGET(info->main_widget));
+    gnc_gen_trans_list_show_accounts_column (info);
 }
 
 void
diff --git a/gnucash/import-export/ofx/gnc-ofx-import.c b/gnucash/import-export/ofx/gnc-ofx-import.c
index 4f887b2dc..cfd67dbef 100644
--- a/gnucash/import-export/ofx/gnc-ofx-import.c
+++ b/gnucash/import-export/ofx/gnc-ofx-import.c
@@ -1163,7 +1163,7 @@ gnc_file_ofx_import_process_file (ofx_info* info)
     /*ofx_set_status_cb(libofx_context, ofx_proc_status_cb, 0);*/
 
     // Create the match dialog, and run the ofx file through the importer.
-    info->gnc_ofx_importer_gui = gnc_gen_trans_list_new (GTK_WIDGET(parent), NULL, TRUE, 42, FALSE);
+    info->gnc_ofx_importer_gui = gnc_gen_trans_list_new (GTK_WIDGET(parent), NULL, FALSE, 42, FALSE);
     libofx_proc_file (libofx_context, selected_filename, AUTODETECT);
 
     // Free the libofx context before recursing to process the next file

commit 0382859e0ae686d42d5cadba400df4ba5aabee89
Author: Robert Fewell <14uBobIT at gmail.com>
Date:   Tue Nov 3 14:06:49 2020 +0000

    Change source files import-main-matcher.* for space and tabs

diff --git a/gnucash/import-export/import-main-matcher.c b/gnucash/import-export/import-main-matcher.c
index d30c9b3dd..82ad17f17 100644
--- a/gnucash/import-export/import-main-matcher.c
+++ b/gnucash/import-export/import-main-matcher.c
@@ -68,16 +68,16 @@ struct _main_matcher_info
     GNCTransactionProcessedCB transaction_processed_cb;
     gpointer user_data;
     GNCImportPendingMatches *pending_matches;
-    GtkTreeViewColumn *account_column;
-    GtkTreeViewColumn *memo_column;
-    GtkWidget         *show_account_column;
-    GtkWidget         *show_matched_info;
-    GtkWidget         *reconcile_after_close;
-    gboolean add_toggled;   // flag to indicate that add has been toggled to stop selection
+    GtkTreeViewColumn       *account_column;
+    GtkTreeViewColumn       *memo_column;
+    GtkWidget               *show_account_column;
+    GtkWidget               *show_matched_info;
+    GtkWidget               *reconcile_after_close;
+    gboolean add_toggled;     // flag to indicate that add has been toggled to stop selection
     gint id;
-    GSList* temp_trans_list; // Temporary list of imported transactions
-    GHashTable* acct_id_hash;     // Hash table, per account, of list of transaction IDs.
-    GSList* edited_accounts; // List of accounts currently edited.
+    GSList* temp_trans_list;  // Temporary list of imported transactions
+    GHashTable* acct_id_hash; // Hash table, per account, of list of transaction IDs.
+    GSList* edited_accounts;  // List of accounts currently edited.
 };
 
 enum downloaded_cols
@@ -118,41 +118,36 @@ void on_matcher_help_close_clicked (GtkButton *button, gpointer user_data);
 static void gnc_gen_trans_list_create_matches (GNCImportMainMatcher *gui);
 
 /* Local prototypes */
-static void gnc_gen_trans_assign_transfer_account (
-                    GtkTreeView *treeview,
-                    gboolean *first,
-                    gboolean is_selection,
-                    GtkTreePath *path,
-                    Account **new_acc,
-                    GNCImportMainMatcher *info);
-static void gnc_gen_trans_assign_transfer_account_to_selection_cb (
-                    GtkMenuItem *menuitem,
-                    GNCImportMainMatcher *info);
-static void gnc_gen_trans_view_popup_menu (
-                    GtkTreeView *treeview,
-                    GdkEvent *event,
-                    GNCImportMainMatcher *info);
-static gboolean gnc_gen_trans_onButtonPressed_cb (
-                    GtkTreeView *treeview,
-                    GdkEvent *event,
-                    GNCImportMainMatcher *info);
-static gboolean gnc_gen_trans_onPopupMenu_cb (
-                    GtkTreeView *treeview,
-                    GNCImportMainMatcher *info);
-static void refresh_model_row (
-                    GNCImportMainMatcher *gui,
-                    GtkTreeModel *model,
-                    GtkTreeIter *iter,
-                    GNCImportTransInfo *info);
+static void gnc_gen_trans_assign_transfer_account (GtkTreeView *treeview,
+                                                   gboolean *first,
+                                                   gboolean is_selection,
+                                                   GtkTreePath *path,
+                                                   Account **new_acc,
+                                                   GNCImportMainMatcher *info);
+static void gnc_gen_trans_assign_transfer_account_to_selection_cb (GtkMenuItem *menuitem,
+                                                                   GNCImportMainMatcher *info);
+static void gnc_gen_trans_view_popup_menu (GtkTreeView *treeview,
+                                           GdkEvent *event,
+                                           GNCImportMainMatcher *info);
+static gboolean gnc_gen_trans_onButtonPressed_cb (GtkTreeView *treeview,
+                                                  GdkEvent *event,
+                                                  GNCImportMainMatcher *info);
+static gboolean gnc_gen_trans_onPopupMenu_cb (GtkTreeView *treeview,
+                                              GNCImportMainMatcher *info);
+static void refresh_model_row (GNCImportMainMatcher *gui,
+                               GtkTreeModel *model,
+                               GtkTreeIter *iter,
+                               GNCImportTransInfo *info);
 static gboolean query_tooltip_tree_view_cb (GtkWidget *widget, gint x, gint y,
                                             gboolean keyboard_tip,
                                             GtkTooltip *tooltip,
                                             gpointer user_data);
 /* end local prototypes */
 
-static gboolean delete_hash (gpointer key, gpointer value, gpointer user_data)
+static
+gboolean delete_hash (gpointer key, gpointer value, gpointer user_data)
 {
-    // Value is a hash table that needs to be destroyed. 
+    // Value is a hash table that needs to be destroyed.
     g_hash_table_destroy (value);
     return TRUE;
 }
@@ -162,8 +157,8 @@ update_all_balances (GNCImportMainMatcher *info)
 {
     for (GSList* iter = info->edited_accounts; iter; iter=iter->next)
     {
-        gnc_account_set_defer_bal_computation(iter->data,FALSE);
-        xaccAccountRecomputeBalance(iter->data);
+        gnc_account_set_defer_bal_computation (iter->data,FALSE);
+        xaccAccountRecomputeBalance (iter->data);
     }
     g_slist_free (info->edited_accounts);
     info->edited_accounts = NULL;
@@ -172,14 +167,15 @@ update_all_balances (GNCImportMainMatcher *info)
 static void
 defer_bal_computation (GNCImportMainMatcher *info, Account* acc)
 {
-    if (!gnc_account_get_defer_bal_computation(acc))
+    if (!gnc_account_get_defer_bal_computation (acc))
     {
         gnc_account_set_defer_bal_computation (acc, TRUE);
         info->edited_accounts = g_slist_prepend (info->edited_accounts, acc);
     }
 }
 
-void gnc_gen_trans_list_delete (GNCImportMainMatcher *info)
+void
+gnc_gen_trans_list_delete (GNCImportMainMatcher *info)
 {
     GtkTreeModel *model;
     GtkTreeIter iter;
@@ -211,23 +207,24 @@ void gnc_gen_trans_list_delete (GNCImportMainMatcher *info)
         gnc_save_window_size (GNC_PREFS_GROUP, GTK_WINDOW(info->main_widget));
         gnc_import_Settings_delete (info->user_settings);
         gnc_unregister_gui_component (info->id);
-        gtk_widget_destroy (GTK_WIDGET (info->main_widget));
+        gtk_widget_destroy (GTK_WIDGET(info->main_widget));
     }
     else
         gnc_import_Settings_delete (info->user_settings);
 
-    g_slist_free_full (info->temp_trans_list,(GDestroyNotify) gnc_import_TransInfo_delete);
+    g_slist_free_full (info->temp_trans_list, (GDestroyNotify) gnc_import_TransInfo_delete);
     info->temp_trans_list = NULL;
-    
+
     // We've deferred balance computations on many accounts. Let's do it now that we're done.
     update_all_balances (info);
-    
+
     g_hash_table_foreach_remove (info->acct_id_hash, delete_hash, NULL);
     info->acct_id_hash = NULL;
     g_free (info);
 }
 
-gboolean gnc_gen_trans_list_empty(GNCImportMainMatcher *info)
+gboolean
+gnc_gen_trans_list_empty (GNCImportMainMatcher *info)
 {
     GtkTreeModel *model;
     GtkTreeIter iter;
@@ -247,12 +244,12 @@ get_top_trans_match_id (GList* match_list)
     if (!match_list || !match_list->data) return NULL;
     match_info = match_list->data;
     trans = match_info->trans;
-    return xaccTransGetGUID(trans);
+    return xaccTransGetGUID (trans);
 }
 
 // This returns the transaction score of the first match candidate in match_list
 static gint
-get_top_trans_match_score(GList* match_list)
+get_top_trans_match_score (GList* match_list)
 {
     GNCImportMatchInfo* match_info;
     if (!match_list || !match_list->data) return 0;
@@ -271,7 +268,7 @@ get_trans_match_list (GtkTreeModel* model, GtkTreeIter* iter)
 }
 
 static GNCImportTransInfo*
-get_trans_info(GtkTreeModel* model, GtkTreeIter* iter)
+get_trans_info (GtkTreeModel* model, GtkTreeIter* iter)
 {
     GNCImportTransInfo* transaction_info;
     gtk_tree_model_get (model, iter,
@@ -342,7 +339,7 @@ static void
 resolve_conflicts (GNCImportMainMatcher *info)
 {
     GtkTreeModel* model = gtk_tree_view_get_model (info->view);
-    GtkListStore* store = GTK_LIST_STORE (model);
+    GtkListStore* store = GTK_LIST_STORE(model);
     GtkTreeIter import_iter, best_import;
     gint best_match = 0;
 
@@ -391,12 +388,13 @@ resolve_conflicts (GNCImportMainMatcher *info)
     }
 }
 
-void gnc_gen_trans_list_show_all(GNCImportMainMatcher *info)
+void
+gnc_gen_trans_list_show_all (GNCImportMainMatcher *info)
 {
     g_assert (info);
     gnc_gen_trans_list_create_matches (info);
     resolve_conflicts (info);
-    gtk_widget_show_all (GTK_WIDGET (info->main_widget));
+    gtk_widget_show_all (GTK_WIDGET(info->main_widget));
 }
 
 void
@@ -420,7 +418,7 @@ on_matcher_ok_clicked (GtkButton *button, GNCImportMainMatcher *info)
 
     /* Don't run any queries and/or split sorts while processing the matcher
     results. */
-    gnc_suspend_gui_refresh();
+    gnc_suspend_gui_refresh ();
     do
     {
         gtk_tree_model_get (model, &iter,
@@ -440,11 +438,11 @@ on_matcher_ok_clicked (GtkButton *button, GNCImportMainMatcher *info)
         }
     }
     while (gtk_tree_model_iter_next (model, &iter));
-    
+
     gnc_gen_trans_list_delete (info);
 
     /* Allow GUI refresh again. */
-    gnc_resume_gui_refresh();
+    gnc_resume_gui_refresh ();
 
     /* DEBUG ("End") */
 }
@@ -481,7 +479,7 @@ on_matcher_help_clicked (GtkButton *button, gpointer user_data)
     gchar *int_required_class, *int_prob_required_class, *int_not_required_class;
     gchar *class_extension = NULL;
 
-    builder = gtk_builder_new();
+    builder = gtk_builder_new ();
     gnc_builder_add_from_file (builder, "dialog-import.glade", "textbuffer2");
     gnc_builder_add_from_file (builder, "dialog-import.glade", "textbuffer3");
     gnc_builder_add_from_file (builder, "dialog-import.glade", "textbuffer4");
@@ -532,7 +530,7 @@ run_account_picker_dialog (GNCImportMainMatcher *info,
     old_acc = gnc_import_TransInfo_get_destacc (trans_info);
 
     new_acc = gnc_import_select_account (
-            info->main_widget,
+             info->main_widget,
              NULL,
              TRUE,
              _("Destination account for the auto-balance split."),
@@ -719,9 +717,8 @@ gnc_gen_trans_assign_transfer_account (GtkTreeView *treeview,
 }
 
 static void
-gnc_gen_trans_assign_transfer_account_to_selection_cb (
-            GtkMenuItem *menuitem,
-            GNCImportMainMatcher *info)
+gnc_gen_trans_assign_transfer_account_to_selection_cb (GtkMenuItem *menuitem,
+                                                       GNCImportMainMatcher *info)
 {
     GtkTreeView *treeview;
     GtkTreeSelection *selection;
@@ -753,16 +750,15 @@ gnc_gen_trans_assign_transfer_account_to_selection_cb (
             gchar *path_str = gtk_tree_path_to_string (l->data);
             GtkTreeRowReference *ref = gtk_tree_row_reference_new (model, l->data);
             DEBUG("passing first = %s", first ? "true" : "false");
-            DEBUG("passing is_selection = %s",
-                        is_selection ? "true" : "false");
+            DEBUG("passing is_selection = %s", is_selection ? "true" : "false");
             DEBUG("passing path = %s", path_str);
             g_free (path_str);
             refs = g_list_prepend (refs, ref);
             DEBUG("passing account value = %s",
                         gnc_account_get_full_name (assigned_account));
             gnc_gen_trans_assign_transfer_account (treeview,
-                        &first, is_selection, l->data,
-                        &assigned_account, info);
+                                                   &first, is_selection, l->data,
+                                                   &assigned_account, info);
             DEBUG("returned value of account = %s",
                         gnc_account_get_full_name (assigned_account));
             DEBUG("returned value of first = %s", first ? "true" : "false");
@@ -771,7 +767,7 @@ gnc_gen_trans_assign_transfer_account_to_selection_cb (
 
         }
     }
-    g_list_free_full (selected_rows, (GDestroyNotify) gtk_tree_path_free);
+    g_list_free_full (selected_rows, (GDestroyNotify)gtk_tree_path_free);
 
     // now reselect the transaction rows. This is very slow if there are lots of transactions.
     for (l = refs; l != NULL; l = l->next)
@@ -802,8 +798,8 @@ gnc_gen_trans_row_activated_cb (GtkTreeView *treeview,
     first = TRUE;
     is_selection = FALSE;
     gnc_gen_trans_assign_transfer_account (treeview,
-                            &first, is_selection, path,
-                            &assigned_account, info);
+                                           &first, is_selection, path,
+                                           &assigned_account, info);
 
     gtk_tree_selection_select_path (gtk_tree_view_get_selection (treeview), path);
 
@@ -840,9 +836,9 @@ gnc_gen_trans_row_changed_cb (GtkTreeSelection *selection,
             if (get_action_for_path (list->data, model) != GNCImport_ADD)
                 gtk_tree_selection_unselect_path (selection, list->data);
         }
-        g_list_free_full (list, (GDestroyNotify) gtk_tree_path_free);
+        g_list_free_full (list, (GDestroyNotify)gtk_tree_path_free);
     }
-    
+
     switch (mode)
     {
         case GTK_SELECTION_MULTIPLE:
@@ -876,7 +872,7 @@ gnc_gen_trans_view_popup_menu (GtkTreeView *treeview,
     ENTER ("");
     menu = gtk_menu_new();
     menuitem = gtk_menu_item_new_with_label (
-            _("Assign a transfer account to the selection."));
+                   _("Assign a transfer account to the selection."));
     g_signal_connect (menuitem, "activate",
                       G_CALLBACK(
                       gnc_gen_trans_assign_transfer_account_to_selection_cb),
@@ -923,7 +919,7 @@ gnc_gen_trans_onButtonPressed_cb (GtkTreeView *treeview,
                 get_action_for_path (selected->data, model);
                 if (get_action_for_path (selected->data, model) == GNCImport_ADD)
                     gnc_gen_trans_view_popup_menu (treeview, event, info);
-                g_list_free_full (selected, (GDestroyNotify) gtk_tree_path_free);
+                g_list_free_full (selected, (GDestroyNotify)gtk_tree_path_free);
             }
             LEAVE("return TRUE");
             return TRUE;
@@ -952,17 +948,17 @@ gnc_gen_trans_onPopupMenu_cb (GtkTreeView *treeview,
 }
 
 static GtkTreeViewColumn *
-add_text_column(GtkTreeView *view, const gchar *title, int col_num, gboolean ellipsize)
+add_text_column (GtkTreeView *view, const gchar *title, int col_num, gboolean ellipsize)
 {
     GtkCellRenderer *renderer;
     GtkTreeViewColumn *column;
 
-    renderer = gtk_cell_renderer_text_new();
-    column = gtk_tree_view_column_new_with_attributes
-             (title, renderer,
-              "text", col_num,
-              "background", DOWNLOADED_COL_COLOR,
-              NULL);
+    renderer = gtk_cell_renderer_text_new ();
+    column = gtk_tree_view_column_new_with_attributes (title,
+                                                       renderer,
+                                                       "text", col_num,
+                                                       "background", DOWNLOADED_COL_COLOR,
+                                                       NULL);
 
     if (ellipsize)
         g_object_set (renderer, "ellipsize", PANGO_ELLIPSIZE_END, NULL);
@@ -994,18 +990,15 @@ add_toggle_column (GtkTreeView *view, const gchar *title, int col_num,
     GtkCellRenderer *renderer;
     GtkTreeViewColumn *column;
 
-    renderer = gtk_cell_renderer_toggle_new();
-    column = gtk_tree_view_column_new_with_attributes
-             (title, renderer,
-              "active", col_num,
-              "cell-background", DOWNLOADED_COL_COLOR,
-              "activatable", DOWNLOADED_COL_ENABLE,
-              "visible", DOWNLOADED_COL_ENABLE,
-              NULL);
+    renderer = gtk_cell_renderer_toggle_new ();
+    column = gtk_tree_view_column_new_with_attributes (title, renderer,
+                                                       "active", col_num,
+                                                       "cell-background", DOWNLOADED_COL_COLOR,
+                                                       "activatable", DOWNLOADED_COL_ENABLE,
+                                                       "visible", DOWNLOADED_COL_ENABLE,
+                                                       NULL);
     gtk_tree_view_column_set_sort_column_id (column, col_num);
-    g_object_set (G_OBJECT(column),
-                  "reorderable", TRUE,
-                  NULL);
+    g_object_set (G_OBJECT(column), "reorderable", TRUE, NULL);
     g_signal_connect (renderer, "toggled", cb_fn, cb_arg);
     gtk_tree_view_append_column (view, column);
     return column;
@@ -1042,24 +1035,24 @@ gnc_gen_trans_init_view (GNCImportMainMatcher *info,
     add_text_column (view, _("Amount"), DOWNLOADED_COL_AMOUNT, FALSE);
     add_text_column (view, _("Description"), DOWNLOADED_COL_DESCRIPTION, FALSE);
     info->memo_column = add_text_column (view, _("Memo"), DOWNLOADED_COL_MEMO, TRUE);
-    add_toggle_column (view,
-                       C_("Column header for 'Adding transaction'", "A"), DOWNLOADED_COL_ACTION_ADD,
+    add_toggle_column (view, C_("Column header for 'Adding transaction'", "A"),
+                       DOWNLOADED_COL_ACTION_ADD,
                        G_CALLBACK(gnc_gen_trans_add_toggled_cb), info);
-    column = add_toggle_column (view,
-                               C_("Column header for 'Updating plus Clearing transaction'", "U+C"), DOWNLOADED_COL_ACTION_UPDATE,
-                               G_CALLBACK(gnc_gen_trans_update_toggled_cb), info);
+    column = add_toggle_column (view, C_("Column header for 'Updating plus Clearing transaction'", "U+C"),
+                                DOWNLOADED_COL_ACTION_UPDATE,
+                                G_CALLBACK(gnc_gen_trans_update_toggled_cb), info);
     gtk_tree_view_column_set_visible (column, show_update);
-    add_toggle_column (view,
-                       C_("Column header for 'Clearing transaction'", "C"), DOWNLOADED_COL_ACTION_CLEAR,
-                      G_CALLBACK(gnc_gen_trans_clear_toggled_cb), info);
+    add_toggle_column (view, C_("Column header for 'Clearing transaction'", "C"),
+                       DOWNLOADED_COL_ACTION_CLEAR,
+                       G_CALLBACK(gnc_gen_trans_clear_toggled_cb), info);
 
     /* The last column has multiple renderers */
-    renderer = gtk_cell_renderer_pixbuf_new();
+    renderer = gtk_cell_renderer_pixbuf_new ();
     g_object_set (renderer, "xalign", 0.0, NULL);
     column = gtk_tree_view_column_new_with_attributes (_("Info"), renderer,
-             "pixbuf", DOWNLOADED_COL_ACTION_PIXBUF,
-             "cell-background", DOWNLOADED_COL_COLOR,
-             NULL);
+                                                       "pixbuf", DOWNLOADED_COL_ACTION_PIXBUF,
+                                                       "cell-background", DOWNLOADED_COL_COLOR,
+                                                       NULL);
 
     gtk_tree_view_append_column (info->view, column);
 
@@ -1073,19 +1066,18 @@ gnc_gen_trans_init_view (GNCImportMainMatcher *info,
     selection = gtk_tree_view_get_selection (info->view);
 
     g_object_set (info->view, "has-tooltip", TRUE, NULL);
+
     g_signal_connect (G_OBJECT(info->view), "query-tooltip",
                       G_CALLBACK(query_tooltip_tree_view_cb), info);
-
     g_signal_connect (info->view, "row-activated",
                       G_CALLBACK(gnc_gen_trans_row_activated_cb), info);
     g_signal_connect (selection, "changed",
                       G_CALLBACK(gnc_gen_trans_row_changed_cb), info);
-
     g_signal_connect (view, "button-press-event",
                       G_CALLBACK(gnc_gen_trans_onButtonPressed_cb), info);
     g_signal_connect (view, "popup-menu",
                       G_CALLBACK(gnc_gen_trans_onPopupMenu_cb), info);
-    
+
     info->acct_id_hash = g_hash_table_new (g_direct_hash, g_direct_equal);
 }
 
@@ -1107,7 +1099,7 @@ show_memo_column_toggled_cb (GtkToggleButton *togglebutton,
 
 static void
 show_matched_info_toggled_cb (GtkToggleButton *togglebutton,
-                                GNCImportMainMatcher *info)
+                              GNCImportMainMatcher *info)
 {
     if (gtk_toggle_button_get_active (togglebutton))
     {
@@ -1197,7 +1189,7 @@ gnc_gen_trans_list_new (GtkWidget *parent,
     info = g_new0 (GNCImportMainMatcher, 1);
 
     /* Initialize the GtkDialog. */
-    builder = gtk_builder_new();
+    builder = gtk_builder_new ();
     gnc_builder_add_from_file (builder, "dialog-import.glade", "transaction_matcher_dialog");
     gnc_builder_add_from_file (builder, "dialog-import.glade", "transaction_matcher_content");
 
@@ -1250,7 +1242,7 @@ gnc_gen_trans_assist_new (GtkWidget *parent,
     info->main_widget = GTK_WIDGET(parent);
 
     /* load the interface */
-    builder = gtk_builder_new();
+    builder = gtk_builder_new ();
     gnc_builder_add_from_file (builder, "dialog-import.glade", "transaction_matcher_content");
 
     /* Pack content into Assistant page widget */
@@ -1265,7 +1257,8 @@ gnc_gen_trans_assist_new (GtkWidget *parent,
     return info;
 }
 
-void gnc_gen_trans_assist_start (GNCImportMainMatcher *info)
+void
+gnc_gen_trans_assist_start (GNCImportMainMatcher *info)
 {
     on_matcher_ok_clicked (NULL, info);
 }
@@ -1274,15 +1267,17 @@ void gnc_gen_trans_assist_start (GNCImportMainMatcher *info)
  *                   Assistant routines End                      *
  *****************************************************************/
 
-void gnc_gen_trans_list_add_tp_cb (GNCImportMainMatcher *info,
-                                   GNCTransactionProcessedCB trans_processed_cb,
-                                   gpointer user_data)
+void
+gnc_gen_trans_list_add_tp_cb (GNCImportMainMatcher *info,
+                              GNCTransactionProcessedCB trans_processed_cb,
+                              gpointer user_data)
 {
     info->user_data = user_data;
     info->transaction_processed_cb = trans_processed_cb;
 }
 
-gboolean gnc_gen_trans_list_run (GNCImportMainMatcher *info)
+gboolean
+gnc_gen_trans_list_run (GNCImportMainMatcher *info)
 {
     gboolean result;
 
@@ -1338,7 +1333,7 @@ update_child_row (GNCImportMatchInfo *sel_match, GtkTreeModel *model, GtkTreeIte
 
     gtk_tree_store_set (store, &child, DOWNLOADED_COL_DATE_TXT, text, -1);
 
-    if (xaccTransCountSplits(sel_match->trans) == 2)
+    if (xaccTransCountSplits (sel_match->trans) == 2)
         gtk_tree_store_set (store, &child, DOWNLOADED_COL_ACCOUNT, xaccAccountGetName (
                             xaccSplitGetAccount (xaccSplitGetOtherSplit (sel_match->split))), -1);
     else
@@ -1621,16 +1616,17 @@ refresh_model_row (GNCImportMainMatcher *gui,
     gtk_tree_selection_unselect_all (selection);
 }
 
-void gnc_gen_trans_list_add_trans (GNCImportMainMatcher *gui, Transaction *trans)
+void
+gnc_gen_trans_list_add_trans (GNCImportMainMatcher *gui, Transaction *trans)
 {
     Account* acc = NULL;
     Split* split = NULL;
     int i=0;
-    
+
     split = xaccTransGetSplit (trans, 0);
     acc = xaccSplitGetAccount (split);
     defer_bal_computation (gui, acc);
-    
+
     gnc_gen_trans_list_add_trans_with_ref_id (gui, trans, 0);
     return;
 }/* end gnc_import_add_trans() */
@@ -1650,14 +1646,15 @@ gnc_gen_trans_list_get_reconcile_after_close_button (GNCImportMainMatcher *info)
     return info->reconcile_after_close;
 }
 
-void gnc_gen_trans_list_add_trans_with_ref_id (GNCImportMainMatcher *gui, Transaction *trans, guint32 ref_id)
+void
+gnc_gen_trans_list_add_trans_with_ref_id (GNCImportMainMatcher *gui, Transaction *trans, guint32 ref_id)
 {
     GNCImportTransInfo * transaction_info = NULL;
     GtkTreeModel *model;
     GtkTreeIter iter;
     g_assert (gui);
     g_assert (trans);
-  
+
     if (gnc_import_exists_online_id (trans, gui->acct_id_hash))
         return;
     else
@@ -1671,7 +1668,6 @@ void gnc_gen_trans_list_add_trans_with_ref_id (GNCImportMainMatcher *gui, Transa
     return;
 }
 
-
 /* Query the accounts used by the imported transactions to find a list of
  * candidate matching transactions.
  */
@@ -1700,12 +1696,12 @@ query_imported_transaction_accounts (GNCImportMainMatcher *gui)
         time64 txn_time =
             xaccTransGetDate (gnc_import_TransInfo_get_trans (txn_info));
         all_accounts = g_list_prepend (all_accounts, txn_account);
-        min_time = MIN (min_time, txn_time);
-        max_time = MAX (max_time, txn_time);
+        min_time = MIN(min_time, txn_time);
+        max_time = MAX(max_time, txn_time);
     }
 
     // Make a query to find splits with the right accounts and dates.
-    qof_query_set_book (query, gnc_get_current_book());
+    qof_query_set_book (query, gnc_get_current_book ());
     xaccQueryAddAccountMatch (query, all_accounts,
                               QOF_GUID_MATCH_ANY, QOF_QUERY_AND);
     xaccQueryAddDateMatchTT (query,
@@ -1808,7 +1804,7 @@ void
 gnc_gen_trans_list_create_matches (GNCImportMainMatcher *gui)
 {
     GHashTable* account_hash =
-        g_hash_table_new_full(g_direct_hash, g_direct_equal, NULL,
+        g_hash_table_new_full (g_direct_hash, g_direct_equal, NULL,
                               (GDestroyNotify)g_slist_free);
     GList *candidate_txns;
     g_assert (gui);
@@ -1822,19 +1818,21 @@ gnc_gen_trans_list_create_matches (GNCImportMainMatcher *gui)
     return;
 }
 
-GtkWidget *gnc_gen_trans_list_widget (GNCImportMainMatcher *info)
+GtkWidget *
+gnc_gen_trans_list_widget (GNCImportMainMatcher *info)
 {
     g_assert (info);
     return info->main_widget;
 }
 
-gboolean query_tooltip_tree_view_cb (GtkWidget *widget, gint x, gint y,
-                                     gboolean keyboard_tip,
-                                     GtkTooltip *tooltip,
-                                     gpointer user_data)
+gboolean
+query_tooltip_tree_view_cb (GtkWidget *widget, gint x, gint y,
+                            gboolean keyboard_tip,
+                            GtkTooltip *tooltip,
+                            gpointer user_data)
 {
     GtkTreeView          *tree_view = GTK_TREE_VIEW(widget);
-    GtkTreeModel         *model = gtk_tree_view_get_model(tree_view);
+    GtkTreeModel         *model = gtk_tree_view_get_model (tree_view);
     GtkTreePath          *path  = NULL;
     GtkTreeViewColumn    *column = NULL;
     GtkTreeIter iter;
@@ -1846,19 +1844,19 @@ gboolean query_tooltip_tree_view_cb (GtkWidget *widget, gint x, gint y,
         return FALSE;
 
     // Get the iter pointing to our current column
-    if (gtk_tree_model_get_iter(model, &iter, path)
-            && column)
+    if (gtk_tree_model_get_iter(model, &iter, path) && column)
     {
         const gchar *tooltip_text = NULL;
 
         // Select text based on column
-        gint num_col = gtk_tree_view_column_get_sort_column_id(column);
-        switch (num_col) {
+        gint num_col = gtk_tree_view_column_get_sort_column_id (column);
+        switch (num_col)
+        {
         case DOWNLOADED_COL_DESCRIPTION:
-            gtk_tree_model_get(model, &iter, DOWNLOADED_COL_DESCRIPTION, &tooltip_text, -1);
+            gtk_tree_model_get (model, &iter, DOWNLOADED_COL_DESCRIPTION, &tooltip_text, -1);
             break;
         case DOWNLOADED_COL_MEMO:
-            gtk_tree_model_get(model, &iter, DOWNLOADED_COL_MEMO, &tooltip_text, -1);
+            gtk_tree_model_get (model, &iter, DOWNLOADED_COL_MEMO, &tooltip_text, -1);
             break;
         default:
             break;
@@ -1872,7 +1870,6 @@ gboolean query_tooltip_tree_view_cb (GtkWidget *widget, gint x, gint y,
             gtk_tree_view_set_tooltip_cell (tree_view, tooltip, path, column, NULL);
         }
     }
-
     // Clean up the object
     gtk_tree_path_free (path);
     return show_tooltip;
diff --git a/gnucash/import-export/import-main-matcher.h b/gnucash/import-export/import-main-matcher.h
index 06b98cf41..6b20c3d4f 100644
--- a/gnucash/import-export/import-main-matcher.h
+++ b/gnucash/import-export/import-main-matcher.h
@@ -39,8 +39,8 @@
 typedef struct _main_matcher_info GNCImportMainMatcher;
 
 typedef void (*GNCTransactionProcessedCB) (GNCImportTransInfo *trans_info,
-        gboolean imported, gpointer user_data);
-
+                                           gboolean imported,
+                                           gpointer user_data);
 
 /** Create a new generic transaction dialog window and return it.
  *
@@ -67,10 +67,10 @@ typedef void (*GNCTransactionProcessedCB) (GNCImportTransInfo *trans_info,
  * @return A pointer to the GNCImportMainMatcher which has been setup.
 */
 GNCImportMainMatcher *gnc_gen_trans_list_new (GtkWidget *parent,
-        const gchar* heading,
-        gboolean all_from_same_account,
-        gint match_date_hardlimit,
-        gboolean show_all);
+                                              const gchar* heading,
+                                              gboolean all_from_same_account,
+                                              gint match_date_hardlimit,
+                                              gboolean show_all);
 
 
 
@@ -103,8 +103,10 @@ GNCImportMainMatcher *gnc_gen_trans_list_new (GtkWidget *parent,
  * @return A pointer to the GNCImportMainMatcher which has been setup.
 */
 GNCImportMainMatcher * gnc_gen_trans_assist_new (GtkWidget *parent,
-        GtkWidget *assistant_page, const gchar* heading,
-        gboolean all_from_same_account, gint match_date_hardlimit);
+                                                 GtkWidget *assistant_page,
+                                                 const gchar* heading,
+                                                 gboolean all_from_same_account,
+                                                 gint match_date_hardlimit);
 
 
 /**  This starts the import process for transaction from an assistant.
@@ -131,9 +133,9 @@ void on_matcher_help_clicked (GtkButton *button, gpointer user_data);
  *
  * @param trans_processed_cb The callback function.
  */
-void gnc_gen_trans_list_add_tp_cb(GNCImportMainMatcher *info,
-                                  GNCTransactionProcessedCB trans_processed_cb,
-                                  gpointer user_data);
+void gnc_gen_trans_list_add_tp_cb (GNCImportMainMatcher *info,
+                                   GNCTransactionProcessedCB trans_processed_cb,
+                                   gpointer user_data);
 
 
 /** Deletes the given object. */
@@ -150,7 +152,7 @@ void gnc_gen_trans_list_delete (GNCImportMainMatcher *info);
  * must NOT be committed. The Importer takes over ownership of the
  * passed transaction.
  */
-void gnc_gen_trans_list_add_trans(GNCImportMainMatcher *gui, Transaction *trans);
+void gnc_gen_trans_list_add_trans (GNCImportMainMatcher *gui, Transaction *trans);
 
 
 /** Add a newly imported Transaction to the Transaction Importer and provide an
@@ -167,7 +169,9 @@ void gnc_gen_trans_list_add_trans(GNCImportMainMatcher *gui, Transaction *trans)
  *
  * @param ref_id Reference id which links an external object to the transaction.
  */
-void gnc_gen_trans_list_add_trans_with_ref_id(GNCImportMainMatcher *gui, Transaction *trans, guint32 ref_id);
+void gnc_gen_trans_list_add_trans_with_ref_id (GNCImportMainMatcher *gui,
+                                               Transaction *trans,
+                                               guint32 ref_id);
 
 
 /** Run this dialog and return only after the user pressed Ok, Cancel,
@@ -189,12 +193,12 @@ GtkWidget *gnc_gen_trans_list_widget (GNCImportMainMatcher *info);
  * @param info A pointer to a the GNCImportMainMatcher structure.
  * @return A boolean indicating whether the transaction list is empty.
  */
-gboolean gnc_gen_trans_list_empty(GNCImportMainMatcher *info);
+gboolean gnc_gen_trans_list_empty (GNCImportMainMatcher *info);
 
 /** Shows widgets.
  * @param info A pointer to a the GNCImportMainMatcher structure.
  */
-void gnc_gen_trans_list_show_all(GNCImportMainMatcher *info);
+void gnc_gen_trans_list_show_all (GNCImportMainMatcher *info);
 
 /** Show and set the reconcile after close check button.
  * @param info A pointer to a the GNCImportMainMatcher structure.

commit 48fe2ea60b8549249c4811069dd9cc71cc2f259a
Author: Robert Fewell <14uBobIT at gmail.com>
Date:   Tue Nov 3 14:05:38 2020 +0000

    Add option to hide memo column on import-main-matcher
    
    This has stemmed from cstim's PR #810 which I have added here after
    refactoring the gnc_gen_trans_list_new function in previous commit.

diff --git a/gnucash/gtkbuilder/dialog-import.glade b/gnucash/gtkbuilder/dialog-import.glade
index 71f7dac7b..76d6a6e49 100644
--- a/gnucash/gtkbuilder/dialog-import.glade
+++ b/gnucash/gtkbuilder/dialog-import.glade
@@ -926,7 +926,7 @@
         <property name="halign">center</property>
         <child>
           <object class="GtkCheckButton" id="show_source_account_button">
-            <property name="label" translatable="yes">Show the _Account column</property>
+            <property name="label" translatable="yes">Show _Account column</property>
             <property name="visible">True</property>
             <property name="can_focus">True</property>
             <property name="receives_default">False</property>
@@ -940,6 +940,22 @@
             <property name="position">0</property>
           </packing>
         </child>
+        <child>
+          <object class="GtkCheckButton" id="show_memo_column_button">
+            <property name="label" translatable="yes">Show _Memo column</property>
+            <property name="visible">True</property>
+            <property name="can_focus">True</property>
+            <property name="receives_default">False</property>
+            <property name="halign">center</property>
+            <property name="use_underline">True</property>
+            <property name="draw_indicator">True</property>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="position">1</property>
+          </packing>
+        </child>
         <child>
           <object class="GtkCheckButton" id="show_matched_info_button">
             <property name="label" translatable="yes">Show _matched information</property>
@@ -952,7 +968,7 @@
           <packing>
             <property name="expand">False</property>
             <property name="fill">True</property>
-            <property name="position">1</property>
+            <property name="position">2</property>
           </packing>
         </child>
         <child>
@@ -967,7 +983,7 @@
           <packing>
             <property name="expand">False</property>
             <property name="fill">True</property>
-            <property name="position">2</property>
+            <property name="position">3</property>
           </packing>
         </child>
       </object>
diff --git a/gnucash/import-export/import-main-matcher.c b/gnucash/import-export/import-main-matcher.c
index 26ffa744a..d30c9b3dd 100644
--- a/gnucash/import-export/import-main-matcher.c
+++ b/gnucash/import-export/import-main-matcher.c
@@ -69,6 +69,7 @@ struct _main_matcher_info
     gpointer user_data;
     GNCImportPendingMatches *pending_matches;
     GtkTreeViewColumn *account_column;
+    GtkTreeViewColumn *memo_column;
     GtkWidget         *show_account_column;
     GtkWidget         *show_matched_info;
     GtkWidget         *reconcile_after_close;
@@ -1040,7 +1041,7 @@ gnc_gen_trans_init_view (GNCImportMainMatcher *info,
     gtk_tree_view_column_set_visible (info->account_column, show_account);
     add_text_column (view, _("Amount"), DOWNLOADED_COL_AMOUNT, FALSE);
     add_text_column (view, _("Description"), DOWNLOADED_COL_DESCRIPTION, FALSE);
-    add_text_column (view, _("Memo"), DOWNLOADED_COL_MEMO, TRUE);
+    info->memo_column = add_text_column (view, _("Memo"), DOWNLOADED_COL_MEMO, TRUE);
     add_toggle_column (view,
                        C_("Column header for 'Adding transaction'", "A"), DOWNLOADED_COL_ACTION_ADD,
                        G_CALLBACK(gnc_gen_trans_add_toggled_cb), info);
@@ -1096,6 +1097,14 @@ show_account_column_toggled_cb (GtkToggleButton *togglebutton,
         gtk_toggle_button_get_active (togglebutton));
 }
 
+static void
+show_memo_column_toggled_cb (GtkToggleButton *togglebutton,
+                             GNCImportMainMatcher *info)
+{
+    gtk_tree_view_column_set_visible (info->memo_column,
+        gtk_toggle_button_get_active (togglebutton));
+}
+
 static void
 show_matched_info_toggled_cb (GtkToggleButton *togglebutton,
                                 GNCImportMainMatcher *info)
@@ -1123,7 +1132,7 @@ gnc_gen_trans_common_setup (GNCImportMainMatcher *info,
 {
     GtkStyleContext *stylectxt;
     GdkRGBA color;
-    GtkWidget *heading_label;
+    GtkWidget *heading_label, *button;
     gboolean show_update;
 
     info->pending_matches = gnc_import_PendingMatches_new ();
@@ -1145,6 +1154,11 @@ gnc_gen_trans_common_setup (GNCImportMainMatcher *info,
     g_signal_connect (G_OBJECT(info->show_account_column), "toggled",
                       G_CALLBACK(show_account_column_toggled_cb), info);
 
+    button = GTK_WIDGET(gtk_builder_get_object (builder, "show_memo_column_button"));
+    gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON(button), TRUE);
+    g_signal_connect (G_OBJECT(button), "toggled",
+                      G_CALLBACK(show_memo_column_toggled_cb), info);
+
     info->show_matched_info = GTK_WIDGET(gtk_builder_get_object (builder, "show_matched_info_button"));
     g_signal_connect (G_OBJECT(info->show_matched_info), "toggled",
                       G_CALLBACK(show_matched_info_toggled_cb), info);
@@ -1158,6 +1172,7 @@ gnc_gen_trans_common_setup (GNCImportMainMatcher *info,
     g_assert (heading_label != NULL);
 
     if (heading)
+        gtk_label_set_text (GTK_LABEL(heading_label), heading);
 
     info->transaction_processed_cb = NULL;
 
@@ -1596,6 +1611,7 @@ refresh_model_row (GNCImportMainMatcher *gui,
             GtkTreePath *path = gtk_tree_model_get_path (model, iter);
 
             gtk_tree_view_column_set_visible (gui->account_column, TRUE);
+            gtk_tree_view_column_set_visible (gui->memo_column, TRUE);
 
             gtk_tree_view_expand_row (GTK_TREE_VIEW(gui->view), path, TRUE);
             gtk_tree_path_free (path);

commit bf483696de01ebb6f336b4d03a33c4d763b95542
Author: Robert Fewell <14uBobIT at gmail.com>
Date:   Tue Nov 3 14:04:38 2020 +0000

    Factor out the common code for import-main-matcher
    
    There are two functions used for starting the import-main-matcher, one
    using dialogs and one for it being embedded in an assistant. These two
    functions gnc_gen_trans_list_new and gnc_gen_trans_assist_new share
    some common code so factor out that part to ease maintenance.

diff --git a/gnucash/import-export/import-main-matcher.c b/gnucash/import-export/import-main-matcher.c
index 5157889c9..26ffa744a 100644
--- a/gnucash/import-export/import-main-matcher.c
+++ b/gnucash/import-export/import-main-matcher.c
@@ -1113,23 +1113,20 @@ show_matched_info_toggled_cb (GtkToggleButton *togglebutton,
     }
 }
 
-GNCImportMainMatcher *gnc_gen_trans_list_new (GtkWidget *parent,
-        const gchar* heading,
-        gboolean all_from_same_account,
-        gint match_date_hardlimit,
-        gboolean show_all)
+static void
+gnc_gen_trans_common_setup (GNCImportMainMatcher *info,
+                            GtkWidget *parent,
+                            GtkBuilder *builder,
+                            const gchar* heading,
+                            gboolean all_from_same_account,
+                            gint match_date_hardlimit)
 {
-    GNCImportMainMatcher *info;
-    GtkBuilder *builder;
-    GtkWidget *heading_label;
-    GtkWidget *box, *pbox;
-    gboolean show_update;
     GtkStyleContext *stylectxt;
     GdkRGBA color;
-    GtkWidget *button;
+    GtkWidget *heading_label;
+    gboolean show_update;
 
-    info = g_new0 (GNCImportMainMatcher, 1);
-    info->pending_matches = gnc_import_PendingMatches_new();
+    info->pending_matches = gnc_import_PendingMatches_new ();
 
     /* Initialize user Settings. */
     info->user_settings = gnc_import_Settings_new ();
@@ -1139,18 +1136,6 @@ GNCImportMainMatcher *gnc_gen_trans_list_new (GtkWidget *parent,
     gtk_style_context_get_color (stylectxt, GTK_STATE_FLAG_NORMAL, &color);
     info->dark_theme = gnc_is_dark_theme (&color);
 
-    /* Initialize the GtkDialog. */
-    builder = gtk_builder_new();
-    gnc_builder_add_from_file (builder, "dialog-import.glade", "transaction_matcher_dialog");
-    gnc_builder_add_from_file (builder, "dialog-import.glade", "transaction_matcher_content");
-    info->main_widget = GTK_WIDGET(gtk_builder_get_object (builder, "transaction_matcher_dialog"));
-    g_assert (info->main_widget != NULL);
-
-    /* Pack the content into the dialog vbox */
-    pbox = GTK_WIDGET(gtk_builder_get_object (builder, "transaction_matcher_vbox"));
-    box = GTK_WIDGET(gtk_builder_get_object (builder, "transaction_matcher_content"));
-    gtk_box_pack_start (GTK_BOX(pbox), box, TRUE, TRUE, 0);
-
     /* Get the view */
     info->view = GTK_TREE_VIEW(gtk_builder_get_object (builder, "downloaded_view"));
     g_assert (info->view != NULL);
@@ -1172,15 +1157,7 @@ GNCImportMainMatcher *gnc_gen_trans_list_new (GtkWidget *parent,
     heading_label = GTK_WIDGET(gtk_builder_get_object (builder, "heading_label"));
     g_assert (heading_label != NULL);
 
-    if (parent)
-        gtk_window_set_transient_for (GTK_WINDOW (info->main_widget), GTK_WINDOW (parent));
-
     if (heading)
-        gtk_label_set_text (GTK_LABEL (heading_label), heading);
-
-    gnc_restore_window_size (GNC_PREFS_GROUP, GTK_WINDOW(info->main_widget), GTK_WINDOW (parent));
-    if(show_all)
-        gtk_widget_show_all (GTK_WIDGET (info->main_widget));
 
     info->transaction_processed_cb = NULL;
 
@@ -1188,6 +1165,46 @@ GNCImportMainMatcher *gnc_gen_trans_list_new (GtkWidget *parent,
     gtk_builder_connect_signals_full (builder, gnc_builder_connect_full_func, info);
 
     g_object_unref (G_OBJECT(builder));
+}
+
+
+GNCImportMainMatcher *
+gnc_gen_trans_list_new (GtkWidget *parent,
+                        const gchar* heading,
+                        gboolean all_from_same_account,
+                        gint match_date_hardlimit,
+                        gboolean show_all)
+{
+    GNCImportMainMatcher *info;
+    GtkBuilder *builder;
+    GtkWidget *box, *pbox;
+
+    info = g_new0 (GNCImportMainMatcher, 1);
+
+    /* Initialize the GtkDialog. */
+    builder = gtk_builder_new();
+    gnc_builder_add_from_file (builder, "dialog-import.glade", "transaction_matcher_dialog");
+    gnc_builder_add_from_file (builder, "dialog-import.glade", "transaction_matcher_content");
+
+    info->main_widget = GTK_WIDGET(gtk_builder_get_object (builder, "transaction_matcher_dialog"));
+    g_assert (info->main_widget != NULL);
+
+    /* Pack the content into the dialog vbox */
+    pbox = GTK_WIDGET(gtk_builder_get_object (builder, "transaction_matcher_vbox"));
+    box = GTK_WIDGET(gtk_builder_get_object (builder, "transaction_matcher_content"));
+    gtk_box_pack_start (GTK_BOX(pbox), box, TRUE, TRUE, 0);
+
+    /* setup the common parts */
+    gnc_gen_trans_common_setup (info, parent, builder, heading,
+                                all_from_same_account, match_date_hardlimit);
+
+    if (parent)
+        gtk_window_set_transient_for (GTK_WINDOW(info->main_widget), GTK_WINDOW(parent));
+
+    gnc_restore_window_size (GNC_PREFS_GROUP, GTK_WINDOW(info->main_widget), GTK_WINDOW(parent));
+
+    if (show_all)
+        gtk_widget_show_all (GTK_WIDGET(info->main_widget));
 
     // Register this UI, it needs to be closed when the session is closed.
     info->id = gnc_register_gui_component (IMPORT_MAIN_MATCHER_CM_CLASS,
@@ -1203,71 +1220,32 @@ GNCImportMainMatcher *gnc_gen_trans_list_new (GtkWidget *parent,
  *                 Assistant routines Start                      *
  *****************************************************************/
 
-GNCImportMainMatcher * gnc_gen_trans_assist_new (GtkWidget *parent,
-        GtkWidget *assistant_page, const gchar* heading,
-        gboolean all_from_same_account, gint match_date_hardlimit)
+GNCImportMainMatcher *
+gnc_gen_trans_assist_new (GtkWidget *parent,
+                          GtkWidget *assistant_page,
+                          const gchar* heading,
+                          gboolean all_from_same_account,
+                          gint match_date_hardlimit)
 {
     GNCImportMainMatcher *info;
     GtkBuilder *builder;
-    GtkWidget *heading_label;
     GtkWidget *box;
-    gboolean show_update;
-    GtkStyleContext *stylectxt;
-    GdkRGBA color;
 
     info = g_new0 (GNCImportMainMatcher, 1);
-    info->pending_matches = gnc_import_PendingMatches_new();
     info->main_widget = GTK_WIDGET(parent);
 
-    /* Initialize user Settings. */
-    info->user_settings = gnc_import_Settings_new ();
-    gnc_import_Settings_set_match_date_hardlimit (info->user_settings, match_date_hardlimit);
-
-    stylectxt = gtk_widget_get_style_context (GTK_WIDGET(parent));
-    gtk_style_context_get_color (stylectxt, GTK_STATE_FLAG_NORMAL, &color);
-    info->dark_theme = gnc_is_dark_theme (&color);
-
     /* load the interface */
     builder = gtk_builder_new();
     gnc_builder_add_from_file (builder, "dialog-import.glade", "transaction_matcher_content");
-    if (builder == NULL)
-    {
-        PERR("Error opening the glade builder interface");
-    }
+
     /* Pack content into Assistant page widget */
     box = GTK_WIDGET(gtk_builder_get_object (builder, "transaction_matcher_content"));
+    g_assert (box != NULL);
     gtk_box_pack_start (GTK_BOX(assistant_page), box, TRUE, TRUE, 6);
 
-    /* Get the view */
-    info->view = GTK_TREE_VIEW(gtk_builder_get_object (builder, "downloaded_view"));
-    g_assert (info->view != NULL);
-
-    info->show_account_column = GTK_WIDGET(gtk_builder_get_object (builder, "show_source_account_button"));
-    gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON(info->show_account_column), all_from_same_account);
-    g_signal_connect (G_OBJECT(info->show_account_column), "toggled",
-                      G_CALLBACK(show_account_column_toggled_cb), info);
-
-    info->show_matched_info = GTK_WIDGET(gtk_builder_get_object (builder, "show_matched_info_button"));
-    g_signal_connect (G_OBJECT(info->show_matched_info), "toggled",
-                      G_CALLBACK(show_matched_info_toggled_cb), info);
-
-    // Create the checkbox, but do not show it by default.
-    info->reconcile_after_close = GTK_WIDGET(gtk_builder_get_object (builder, "reconcile_after_close_button"));
-
-    show_update = gnc_import_Settings_get_action_update_enabled (info->user_settings);
-    gnc_gen_trans_init_view (info, all_from_same_account, show_update);
-    heading_label = GTK_WIDGET(gtk_builder_get_object (builder, "heading_label"));
-    g_assert (heading_label != NULL);
-
-    if (heading)
-        gtk_label_set_text (GTK_LABEL (heading_label), heading);
-
-    info->transaction_processed_cb = NULL;
-
-    /* Connect the signals */
-    gtk_builder_connect_signals_full (builder, gnc_builder_connect_full_func, info);
-
-    g_object_unref (G_OBJECT(builder));
+    /* setup the common parts */
+    gnc_gen_trans_common_setup (info, parent, builder, heading,
+                                all_from_same_account, match_date_hardlimit);
 
     return info;
 }

commit aa71e46901120c80a5412c539cb59a7c2eb9ed26
Author: Robert Fewell <14uBobIT at gmail.com>
Date:   Tue Nov 3 14:03:32 2020 +0000

    Fix for OFX import
    
    Pressing help button causes main-import-matcher to disappear

diff --git a/gnucash/import-export/ofx/gnc-ofx-import.c b/gnucash/import-export/ofx/gnc-ofx-import.c
index 442ecc9f8..4f887b2dc 100644
--- a/gnucash/import-export/ofx/gnc-ofx-import.c
+++ b/gnucash/import-export/ofx/gnc-ofx-import.c
@@ -1111,6 +1111,8 @@ gnc_ofx_match_done (GtkDialog *dialog, gint response_id, gpointer user_data)
                               G_CALLBACK(gnc_ofx_process_next_file), info);
         }
     }
+    else if (response_id == GTK_RESPONSE_HELP)
+        return;
     else
     {
         gtk_widget_hide (GTK_WIDGET(dialog));

commit 761797eb3d60bc6ee4c654cc07573157ba5a1621
Author: Robert Fewell <14uBobIT at gmail.com>
Date:   Tue Nov 3 14:02:13 2020 +0000

    Fix GdkDisplay error in trace file
    
    When OFX import is first used and the file chosen, an account select
    dialog will be shown but the parent was being obtained from a hidden
    import-main-matcher dialog. This fails so get the parent from the
    transient parent of the import-main-matcher dialog.

diff --git a/gnucash/import-export/ofx/gnc-ofx-import.c b/gnucash/import-export/ofx/gnc-ofx-import.c
index 405d069ca..442ecc9f8 100644
--- a/gnucash/import-export/ofx/gnc-ofx-import.c
+++ b/gnucash/import-export/ofx/gnc-ofx-import.c
@@ -926,6 +926,8 @@ int ofx_proc_account_cb(struct OfxAccountData data, void * account_user_data)
     gnc_commodity * default_commodity;
     GNCAccountType default_type = ACCT_TYPE_NONE;
     gchar * account_description;
+    GtkWidget * main_widget;
+    GtkWidget * parent;
     /* In order to trigger a book options display on the creation of a new book,
      * we need to detect when we are dealing with a new book. */
     gboolean new_book = gnc_is_new_book();
@@ -1006,7 +1008,17 @@ int ofx_proc_account_cb(struct OfxAccountData data, void * account_user_data)
                                                "%s \"%s\"",
                                                account_type_name,
                                                data.account_name);
-        account = gnc_import_select_account (gnc_gen_trans_list_widget(info->gnc_ofx_importer_gui),
+
+        main_widget = gnc_gen_trans_list_widget (info->gnc_ofx_importer_gui);
+
+        /* On first use, the import-main-matcher is hidden / not realized so to
+         * get a parent use the transient parent of the matcher */
+        if (gtk_widget_get_realized (main_widget))
+            parent = main_widget;
+        else
+            parent = GTK_WIDGET(gtk_window_get_transient_for (GTK_WINDOW(main_widget)));
+
+        account = gnc_import_select_account (parent,
                                              data.account_id, 1,
                                              account_description, default_commodity,
                                              default_type, NULL, NULL);
@@ -1151,7 +1163,7 @@ gnc_file_ofx_import_process_file (ofx_info* info)
     // Create the match dialog, and run the ofx file through the importer.
     info->gnc_ofx_importer_gui = gnc_gen_trans_list_new (GTK_WIDGET(parent), NULL, TRUE, 42, FALSE);
     libofx_proc_file (libofx_context, selected_filename, AUTODETECT);
-    
+
     // Free the libofx context before recursing to process the next file
     libofx_free_context(libofx_context);
 
@@ -1173,7 +1185,7 @@ gnc_file_ofx_import_process_file (ofx_info* info)
                           G_CALLBACK (gnc_ofx_match_done), info);
 
         gnc_gen_trans_list_show_all (info->gnc_ofx_importer_gui);
-        
+
         // Show or hide the check box for reconciling after match, depending on whether a statement was received.
         gnc_gen_trans_list_show_reconcile_after_close_button (info->gnc_ofx_importer_gui, info->statement != NULL, info->run_reconcile);
 
@@ -1199,7 +1211,7 @@ void gnc_file_ofx_import (GtkWindow *parent)
     GSList* iter = NULL;
     ofx_info* info = NULL;
     GtkFileFilter* filter = gtk_file_filter_new ();
-    
+
 
     ofx_PARSER_msg = false;
     ofx_DEBUG_msg = false;

commit 504ca731e25512a546226560f62601bc8c2b4bc7
Author: Robert Fewell <14uBobIT at gmail.com>
Date:   Tue Nov 3 14:01:27 2020 +0000

    Import matcher tooltip for columns update
    
    If there is no text to be displayed, do not show tooltip.

diff --git a/gnucash/import-export/import-main-matcher.c b/gnucash/import-export/import-main-matcher.c
index 58888b0aa..5157889c9 100644
--- a/gnucash/import-export/import-main-matcher.c
+++ b/gnucash/import-export/import-main-matcher.c
@@ -1841,7 +1841,6 @@ gboolean query_tooltip_tree_view_cb (GtkWidget *widget, gint x, gint y,
 {
     GtkTreeView          *tree_view = GTK_TREE_VIEW(widget);
     GtkTreeModel         *model = gtk_tree_view_get_model(tree_view);
-    //GNCImportMainMatcher *info = user_data;
     GtkTreePath          *path  = NULL;
     GtkTreeViewColumn    *column = NULL;
     GtkTreeIter iter;
@@ -1872,7 +1871,7 @@ gboolean query_tooltip_tree_view_cb (GtkWidget *widget, gint x, gint y,
         }
 
         // Did we select any text? If yes, display the tooltip
-        if (tooltip_text)
+        if (tooltip_text && *tooltip_text)
         {
             show_tooltip = TRUE;
             gtk_tooltip_set_text (tooltip, tooltip_text);

commit c40ac765b9cd029c8e7449f12004774933ca8cf3
Author: Robert Fewell <14uBobIT at gmail.com>
Date:   Tue Nov 3 14:00:50 2020 +0000

    Change source file dialog-preferences.c for space and tabs

diff --git a/gnucash/gnome-utils/dialog-preferences.c b/gnucash/gnome-utils/dialog-preferences.c
index 9b8137dcc..149b51bb3 100644
--- a/gnucash/gnome-utils/dialog-preferences.c
+++ b/gnucash/gnome-utils/dialog-preferences.c
@@ -88,7 +88,7 @@
 /** The debugging module that this .o belongs to.  */
 static QofLogModule log_module = GNC_MOD_PREFS;
 
-void gnc_preferences_response_cb(GtkDialog *dialog, gint response, GtkDialog *unused);
+void gnc_preferences_response_cb (GtkDialog *dialog, gint response, GtkDialog *unused);
 void gnc_account_separator_pref_changed_cb (GtkEntry *entry, GtkWidget *dialog);
 void gnc_save_on_close_expires_cb (GtkToggleButton *button, GtkWidget *dialog);
 gboolean gnc_preferences_delete_event_cb (GtkWidget *widget,
@@ -122,7 +122,7 @@ GSList *add_ins = NULL;
 static gchar *gnc_account_separator_is_valid (const gchar *separator,
                                               gchar **normalized_separator)
 {
-    QofBook *book = gnc_get_current_book();
+    QofBook *book = gnc_get_current_book ();
     GList *conflict_accts = NULL;
     gchar *message = NULL;
 
@@ -133,7 +133,6 @@ static gchar *gnc_account_separator_is_valid (const gchar *separator,
                                                       conflict_accts);
 
     g_list_free (conflict_accts);
-
     return message;
 }
 
@@ -156,29 +155,29 @@ gnc_account_separator_pref_changed_cb (GtkEntry *entry, GtkWidget *dialog)
 
     gchar *conflict_msg = gnc_account_separator_is_valid (gtk_entry_get_text (entry), &separator);
 
-    label = g_object_get_data(G_OBJECT(dialog), "sample_account");
-    DEBUG("Sample Account pointer is %p", label );
+    label = g_object_get_data (G_OBJECT(dialog), "sample_account");
+    DEBUG("Sample Account pointer is %p", label);
     /* Translators: Both %s will be the account separator character; the
        resulting string is a demonstration how the account separator
        character will look like. You can replace these three account
        names with other account names that are more suitable for your
        language - just keep in mind to have exactly two %s in your
        translation. */
-    sample = g_strdup_printf(_("Income%sSalary%sTaxable"),
-                             separator, separator);
+    sample = g_strdup_printf (_("Income%sSalary%sTaxable"),
+                              separator, separator);
     PINFO(" Label set to '%s'", sample);
-    gtk_label_set_text(GTK_LABEL(label), sample);
-    g_free(sample);
+    gtk_label_set_text (GTK_LABEL(label), sample);
+    g_free (sample);
 
     /* Check if the new separator clashes with existing account names */
-    image = g_object_get_data(G_OBJECT(dialog), "separator_error");
-    DEBUG("Separator Error Image pointer is %p", image );
+    image = g_object_get_data (G_OBJECT(dialog), "separator_error");
+    DEBUG("Separator Error Image pointer is %p", image);
 
     if (conflict_msg)
     {
-        gtk_widget_set_tooltip_text(GTK_WIDGET(image), conflict_msg);
+        gtk_widget_set_tooltip_text (GTK_WIDGET(image), conflict_msg);
         gtk_widget_show (GTK_WIDGET(image));
-        g_free ( conflict_msg );
+        g_free (conflict_msg);
     }
     else
         gtk_widget_hide (GTK_WIDGET(image));
@@ -207,12 +206,11 @@ gnc_account_separator_validate (GtkWidget *dialog)
     /* Check if the new separator clashes with existing account names */
     if (conflict_msg)
     {
-        GtkWidget   *msg_dialog;
+        GtkWidget   *msg_dialog, *msg_label;
         GtkBuilder  *builder;
-        GtkWidget   *msg_label;
         gint         response;
 
-        builder = gtk_builder_new();
+        builder = gtk_builder_new ();
         gnc_builder_add_from_file (builder, "dialog-preferences.glade", "separator_validation_dialog");
 
         msg_dialog = GTK_WIDGET(gtk_builder_get_object (builder, "separator_validation_dialog"));
@@ -285,9 +283,9 @@ gnc_preferences_select_account_page (GtkDialog *dialog)
 void
 gnc_save_on_close_expires_cb (GtkToggleButton *button, GtkWidget *dialog)
 {
-    GtkWidget *spinner = g_object_get_data (G_OBJECT (dialog),
+    GtkWidget *spinner = g_object_get_data (G_OBJECT(dialog),
                                             "save_on_close_wait_time");
-    gtk_widget_set_sensitive(spinner, gtk_toggle_button_get_active(button));
+    gtk_widget_set_sensitive (spinner, gtk_toggle_button_get_active (button));
 }
 
 /** This function compares two add-ins to see if they specify the same
@@ -305,7 +303,7 @@ static gint
 gnc_prefs_compare_addins (addition *a,
                           addition *b)
 {
-    return g_utf8_collate(a->tabname, b->tabname);
+    return g_utf8_collate (a->tabname, b->tabname);
 }
 
 
@@ -341,30 +339,30 @@ gnc_preferences_add_page_internal (const gchar *filename,
     ENTER("file %s, widget %s, tab %s full page %d",
           filename, widgetname, tabname, full_page);
 
-    add_in = g_malloc(sizeof(addition));
+    add_in = g_malloc (sizeof(addition));
     if (add_in == NULL)
     {
-        g_critical("Unable to allocate memory.\n");
+        g_critical ("Unable to allocate memory.\n");
         LEAVE("no memory");
         return;
     }
 
-    add_in->filename   = g_strdup(filename);
-    add_in->widgetname = g_strdup(widgetname);
-    add_in->tabname    = g_strdup(tabname);
+    add_in->filename   = g_strdup (filename);
+    add_in->widgetname = g_strdup (widgetname);
+    add_in->tabname    = g_strdup (tabname);
     add_in->full_page  = full_page;
     if (!add_in->filename || !add_in->widgetname || !add_in->tabname)
     {
-        g_critical("Unable to allocate memory.\n");
-        g_free(add_in->filename);
-        g_free(add_in->widgetname);
-        g_free(add_in->tabname);
-        g_free(add_in);
+        g_critical ("Unable to allocate memory.\n");
+        g_free (add_in->filename);
+        g_free (add_in->widgetname);
+        g_free (add_in->tabname);
+        g_free (add_in);
         LEAVE("no memory");
         return;
     }
 
-    ptr = g_slist_find_custom(add_ins, add_in, (GCompareFunc)gnc_prefs_compare_addins);
+    ptr = g_slist_find_custom (add_ins, add_in, (GCompareFunc)gnc_prefs_compare_addins);
     if (ptr)
     {
         /* problem? */
@@ -372,34 +370,34 @@ gnc_preferences_add_page_internal (const gchar *filename,
 
         if (preexisting->full_page)
         {
-            g_warning("New tab %s(%s/%s/%s) conflicts with existing tab %s(%s/%s/full)",
-                      add_in->tabname, add_in->filename, add_in->widgetname,
-                      add_in->full_page ? "full" : "partial",
-                      preexisting->tabname, preexisting->filename, preexisting->widgetname);
+            g_warning ("New tab %s(%s/%s/%s) conflicts with existing tab %s(%s/%s/full)",
+                       add_in->tabname, add_in->filename, add_in->widgetname,
+                       add_in->full_page ? "full" : "partial",
+                       preexisting->tabname, preexisting->filename, preexisting->widgetname);
             error = TRUE;
         }
         else if (add_in->full_page)
         {
-            g_warning("New tab %s(%s/%s/%s) conflicts with existing tab %s(%s/%s/partial)",
-                      add_in->tabname, add_in->filename, add_in->widgetname,
-                      add_in->full_page ? "full" : "partial",
-                      preexisting->tabname, preexisting->filename, preexisting->widgetname);
+            g_warning ("New tab %s(%s/%s/%s) conflicts with existing tab %s(%s/%s/partial)",
+                       add_in->tabname, add_in->filename, add_in->widgetname,
+                       add_in->full_page ? "full" : "partial",
+                       preexisting->tabname, preexisting->filename, preexisting->widgetname);
             error = TRUE;
         }
     }
 
     if (error)
     {
-        g_free(add_in->filename);
-        g_free(add_in->widgetname);
-        g_free(add_in->tabname);
-        g_free(add_in);
+        g_free (add_in->filename);
+        g_free (add_in->widgetname);
+        g_free (add_in->tabname);
+        g_free (add_in);
         LEAVE("err");
         return;
     }
     else
     {
-        add_ins = g_slist_append(add_ins, add_in);
+        add_ins = g_slist_append (add_ins, add_in);
     }
     LEAVE("");
 }
@@ -416,7 +414,7 @@ gnc_preferences_add_page (const gchar *filename,
                           const gchar *widgetname,
                           const gchar *tabname)
 {
-    gnc_preferences_add_page_internal(filename, widgetname, tabname, TRUE);
+    gnc_preferences_add_page_internal (filename, widgetname, tabname, TRUE);
 }
 
 
@@ -431,7 +429,7 @@ gnc_preferences_add_to_page (const gchar *filename,
                              const gchar *widgetname,
                              const gchar *tabname)
 {
-    gnc_preferences_add_page_internal(filename, widgetname, tabname, FALSE);
+    gnc_preferences_add_page_internal (filename, widgetname, tabname, FALSE);
 }
 
 
@@ -460,23 +458,23 @@ gnc_prefs_build_widget_table (GtkBuilder *builder,
     const gchar *wname;
     GtkWidget *widget;
 
-    prefs_table = g_object_get_data(G_OBJECT(dialog), PREFS_WIDGET_HASH);
+    prefs_table = g_object_get_data (G_OBJECT(dialog), PREFS_WIDGET_HASH);
 
-    interesting = gtk_builder_get_objects(builder);
+    interesting = gtk_builder_get_objects (builder);
 
     for (runner = interesting; runner; runner = g_slist_next(runner))
     {
         widget = runner->data;
         if (GTK_IS_WIDGET(widget))
         {
-            wname = gtk_widget_get_name(widget);
-            name = gtk_buildable_get_name(GTK_BUILDABLE(widget));
+            wname = gtk_widget_get_name (widget);
+            name = gtk_buildable_get_name (GTK_BUILDABLE(widget));
             DEBUG("Widget type is %s and buildable get name is %s", wname, name);
             if (g_str_has_prefix (name, "pref"))
-                g_hash_table_insert(prefs_table, (gchar *)name, widget);
+                g_hash_table_insert (prefs_table, (gchar *)name, widget);
         }
     }
-    g_slist_free(interesting);
+    g_slist_free (interesting);
 
 }
 
@@ -504,7 +502,7 @@ gnc_prefs_find_page (GtkNotebook *notebook, const gchar *name)
     GtkWidget *child;
     const gchar *child_name;
 
-    g_return_val_if_fail (GTK_IS_NOTEBOOK (notebook), NULL);
+    g_return_val_if_fail (GTK_IS_NOTEBOOK(notebook), NULL);
     g_return_val_if_fail (name, NULL);
 
     ENTER("");
@@ -548,12 +546,12 @@ gnc_prefs_get_grid_size (GtkWidget *child, gpointer data)
     struct copy_data *copydata = data;
     gint top, left, height, width;
 
-    gtk_container_child_get(GTK_CONTAINER(copydata->grid_to), child,
-                            "left-attach", &left,
-                            "top-attach", &top,
-                            "height", &height,
-                            "width", &width,
-                            NULL);
+    gtk_container_child_get (GTK_CONTAINER(copydata->grid_to), child,
+                             "left-attach", &left,
+                             "top-attach", &top,
+                             "height", &height,
+                             "width", &width,
+                             NULL);
 
     if (left + width >= copydata->cols)
         copydata->cols = left + width;
@@ -586,12 +584,12 @@ gnc_prefs_move_grid_entry (GtkWidget *child,
     gint topm, bottomm, leftm, rightm;
 
     ENTER("child %p, copy data %p", child, data);
-    gtk_container_child_get(GTK_CONTAINER(copydata->grid_from), child,
-                            "left-attach", &left,
-                            "top-attach", &top,
-                            "height", &height,
-                            "width", &width,
-                            NULL);
+    gtk_container_child_get (GTK_CONTAINER(copydata->grid_from), child,
+                             "left-attach", &left,
+                             "top-attach", &top,
+                             "height", &height,
+                             "width", &width,
+                             NULL);
     hexpand = gtk_widget_get_hexpand (child);
     vexpand = gtk_widget_get_vexpand (child);
     halign = gtk_widget_get_halign (child);
@@ -600,10 +598,10 @@ gnc_prefs_move_grid_entry (GtkWidget *child,
     g_object_get (child, "margin-top", &topm, "margin-bottom", &bottomm, NULL);
     g_object_get (child, "margin-left", &leftm, "margin-right", &rightm, NULL);
 
-    g_object_ref(child);
-    gtk_container_remove(GTK_CONTAINER(copydata->grid_from), child);
+    g_object_ref (child);
+    gtk_container_remove (GTK_CONTAINER(copydata->grid_from), child);
 
-    gtk_grid_attach(copydata->grid_to, child, left, copydata->rows + top , width, height);
+    gtk_grid_attach (copydata->grid_to, child, left, copydata->rows + top , width, height);
 
     gtk_widget_set_hexpand (child, hexpand);
     gtk_widget_set_vexpand (child, vexpand);
@@ -613,7 +611,7 @@ gnc_prefs_move_grid_entry (GtkWidget *child,
     g_object_set (child, "margin-left", leftm, "margin-right", rightm, NULL);
     g_object_set (child, "margin-top", topm, "margin-bottom", bottomm, NULL);
 
-    g_object_unref(child);
+    g_object_unref (child);
     LEAVE(" ");
 }
 
@@ -646,10 +644,10 @@ gnc_preferences_build_page (gpointer data,
     dialog = user_data;
 
     DEBUG("Opening %s to get %s", add_in->filename, add_in->widgetname);
-    builder = gtk_builder_new();
+    builder = gtk_builder_new ();
 
     /* Adjustments etc... must come before dialog information */
-    widgetname = g_strsplit(add_in->widgetname, ",", -1);
+    widgetname = g_strsplit (add_in->widgetname, ",", -1);
 
     for (i = 0; widgetname[i]; i++)
     {
@@ -660,11 +658,11 @@ gnc_preferences_build_page (gpointer data,
     DEBUG("Widget Content is %s", widgetname[i - 1]);
     new_content = GTK_WIDGET(gtk_builder_get_object (builder, widgetname[i - 1]));
 
-    g_strfreev(widgetname);
+    g_strfreev (widgetname);
     DEBUG("done");
 
     /* Add to the list of interesting widgets */
-    gnc_prefs_build_widget_table(builder, dialog);
+    gnc_prefs_build_widget_table (builder, dialog);
 
     /* Connect the signals in this glade file. The dialog is passed in
      * so the callback can find "interesting" widgets from other
@@ -672,14 +670,14 @@ gnc_preferences_build_page (gpointer data,
     gtk_builder_connect_signals_full (builder, gnc_builder_connect_full_func, dialog);
 
     /* Prepare for recursion */
-    notebook = g_object_get_data(G_OBJECT(dialog), NOTEBOOK);
+    notebook = g_object_get_data (G_OBJECT(dialog), NOTEBOOK);
 
     if (add_in->full_page)
     {
-        label = gtk_label_new(add_in->tabname);
-        gnc_label_set_alignment(label, 0.0, 0.5);
-        gtk_notebook_append_page(notebook, new_content, label);
-        g_object_unref(G_OBJECT(builder));
+        label = gtk_label_new (add_in->tabname);
+        gnc_label_set_alignment (label, 0.0, 0.5);
+        gtk_notebook_append_page (notebook, new_content, label);
+        g_object_unref (G_OBJECT(builder));
         LEAVE("appended page");
         return;
     }
@@ -687,33 +685,33 @@ gnc_preferences_build_page (gpointer data,
     /* Copied grids must be grids */
     if (!GTK_IS_GRID(new_content))
     {
-        g_critical("The object name %s in file %s is not a GtkGrid. It cannot "
-                   "be added to the preferences dialog.",
-                   add_in->widgetname, add_in->filename);
-        g_object_unref(G_OBJECT(builder));
+        g_critical ("The object name %s in file %s is not a GtkGrid. It cannot "
+                    "be added to the preferences dialog.",
+                    add_in->widgetname, add_in->filename);
+        g_object_unref (G_OBJECT(builder));
         LEAVE("");
         return;
     }
 
     /* Does the page exist or must we create it */
-    existing_content = gnc_prefs_find_page(notebook, add_in->tabname);
+    existing_content = gnc_prefs_find_page (notebook, add_in->tabname);
 
     if (!existing_content)
     {
         /* No existing content with this name.  Create a blank page */
-        existing_content = gtk_grid_new();
-        gtk_container_set_border_width(GTK_CONTAINER(existing_content), 6);
-        label = gtk_label_new(add_in->tabname);
-        gnc_label_set_alignment(label, 0.0, 0.5);
-        gtk_notebook_append_page(notebook, existing_content, label);
-        gtk_widget_show_all(existing_content);
+        existing_content = gtk_grid_new ();
+        gtk_container_set_border_width (GTK_CONTAINER(existing_content), 6);
+        label = gtk_label_new (add_in->tabname);
+        gnc_label_set_alignment (label, 0.0, 0.5);
+        gtk_notebook_append_page (notebook, existing_content, label);
+        gtk_widget_show_all (existing_content);
         DEBUG("created new page %s, appended it", add_in->tabname);
     }
     else
     {
         /* Lets get the size of the existing grid */
         copydata.grid_to = GTK_GRID(existing_content);
-        gtk_container_foreach(GTK_CONTAINER(existing_content), gnc_prefs_get_grid_size, &copydata);
+        gtk_container_foreach (GTK_CONTAINER(existing_content), gnc_prefs_get_grid_size, &copydata);
 
         DEBUG("found existing page %s, grid size is %d x %d", add_in->tabname, copydata.rows, copydata.cols);
     }
@@ -721,8 +719,8 @@ gnc_preferences_build_page (gpointer data,
     /* Maybe add a spacer row */
     if (copydata.rows > 0)
     {
-        label = gtk_label_new("");
-        gtk_widget_show(label);
+        label = gtk_label_new ("");
+        gtk_widget_show (label);
         gtk_grid_attach (GTK_GRID(existing_content), label, 0, copydata.rows, 1, 1);
         copydata.rows = copydata.rows + 1;
 
@@ -732,10 +730,10 @@ gnc_preferences_build_page (gpointer data,
     /* Now copy all the entries in the grid */
     copydata.grid_from = GTK_GRID(new_content);
     copydata.grid_to = GTK_GRID(existing_content);
-    gtk_container_foreach(GTK_CONTAINER(new_content), gnc_prefs_move_grid_entry, &copydata);
+    gtk_container_foreach (GTK_CONTAINER(new_content), gnc_prefs_move_grid_entry, &copydata);
 
-    g_object_ref_sink(new_content);
-    g_object_unref(G_OBJECT(builder));
+    g_object_ref_sink (new_content);
+    g_object_unref (G_OBJECT(builder));
 
     LEAVE("added content to page");
 }
@@ -755,7 +753,7 @@ gnc_prefs_sort_pages (GtkNotebook *notebook)
     gint n_pages, i;
     GList *tabs = NULL, *iter = NULL;
 
-    g_return_if_fail (GTK_IS_NOTEBOOK (notebook));
+    g_return_if_fail (GTK_IS_NOTEBOOK(notebook));
 
     /* gather tabs */
     n_pages = gtk_notebook_get_n_pages (notebook);
@@ -767,7 +765,7 @@ gnc_prefs_sort_pages (GtkNotebook *notebook)
 
     /* reorder tabs */
     for (i = 0, iter = tabs; iter; i++, iter = iter->next)
-        gtk_notebook_reorder_child (notebook, GTK_WIDGET (iter->data), i);
+        gtk_notebook_reorder_child (notebook, GTK_WIDGET(iter->data), i);
 
     g_list_free (tabs);
 }
@@ -801,15 +799,15 @@ gnc_prefs_connect_font_button (GtkFontButton *fb)
 {
     gchar *group, *pref;
 
-    g_return_if_fail(GTK_IS_FONT_BUTTON(fb));
+    g_return_if_fail (GTK_IS_FONT_BUTTON(fb));
 
-    gnc_prefs_split_widget_name (gtk_buildable_get_name(GTK_BUILDABLE(fb)), &group, &pref);
+    gnc_prefs_split_widget_name (gtk_buildable_get_name (GTK_BUILDABLE(fb)), &group, &pref);
     gnc_prefs_bind (group, pref, G_OBJECT (fb), "font-name");
 
     g_free (group);
     g_free (pref);
 
-    gtk_widget_show_all(GTK_WIDGET(fb));
+    gtk_widget_show_all (GTK_WIDGET(fb));
 }
 
 /****************************************************************************/
@@ -844,7 +842,7 @@ file_chooser_selected_cb (GtkFileChooser *fc, gpointer user_data)
         PINFO("Failed to save preference at %s, %s with %s", group, pref, folder_uri);
     else
         gnc_doclink_pref_path_head_changed (
-            GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (fc))),
+            GTK_WINDOW(gtk_widget_get_toplevel (GTK_WIDGET(fc))),
             old_path_head_uri);
 
     g_free (old_path_head_uri);
@@ -949,13 +947,13 @@ file_chooser_clear_cb (GtkButton *button, gpointer user_data)
         PINFO("Failed to Clear preference at %s, %s", group, pref);
     else
         gnc_doclink_pref_path_head_changed (
-            GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (fcb))),
+            GTK_WINDOW(gtk_widget_get_toplevel (GTK_WIDGET(fcb))),
             old_path_head_uri);
 
     gtk_widget_destroy (GTK_WIDGET(fcb));
 
     fcb_new = gtk_file_chooser_button_new (_("Select a folder"),
-                             GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER);
+                                           GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER);
 
     g_object_set_data (G_OBJECT(fcb_new), "path_head_error", image);
     g_object_set_data_full (G_OBJECT(fcb_new),"group", g_strdup (group), (GDestroyNotify) g_free);
@@ -989,11 +987,11 @@ gnc_prefs_connect_radio_button (GtkRadioButton *button)
 {
     gchar *group, *pref;
 
-    g_return_if_fail(GTK_IS_RADIO_BUTTON(button));
+    g_return_if_fail (GTK_IS_RADIO_BUTTON(button));
 
-    gnc_prefs_split_widget_name (gtk_buildable_get_name(GTK_BUILDABLE(button)), &group, &pref);
+    gnc_prefs_split_widget_name (gtk_buildable_get_name (GTK_BUILDABLE(button)), &group, &pref);
 
-    gnc_prefs_bind (group, pref, G_OBJECT (button), "active");
+    gnc_prefs_bind (group, pref, G_OBJECT(button), "active");
 
     g_free (group);
     g_free (pref);
@@ -1013,11 +1011,11 @@ gnc_prefs_connect_check_button (GtkCheckButton *button)
 {
     gchar *group, *pref;
 
-    g_return_if_fail(GTK_IS_CHECK_BUTTON(button));
+    g_return_if_fail (GTK_IS_CHECK_BUTTON(button));
 
-    gnc_prefs_split_widget_name (gtk_buildable_get_name(GTK_BUILDABLE(button)), &group, &pref);
+    gnc_prefs_split_widget_name (gtk_buildable_get_name (GTK_BUILDABLE(button)), &group, &pref);
 
-    gnc_prefs_bind (group, pref, G_OBJECT (button), "active");
+    gnc_prefs_bind (group, pref, G_OBJECT(button), "active");
 
     g_free (group);
     g_free (pref);
@@ -1037,11 +1035,11 @@ gnc_prefs_connect_spin_button (GtkSpinButton *spin)
 {
     gchar *group, *pref;
 
-    g_return_if_fail(GTK_IS_SPIN_BUTTON(spin));
+    g_return_if_fail (GTK_IS_SPIN_BUTTON(spin));
 
-    gnc_prefs_split_widget_name (gtk_buildable_get_name(GTK_BUILDABLE(spin)), &group, &pref);
+    gnc_prefs_split_widget_name (gtk_buildable_get_name (GTK_BUILDABLE(spin)), &group, &pref);
 
-    gnc_prefs_bind (group, pref, G_OBJECT (spin), "value");
+    gnc_prefs_bind (group, pref, G_OBJECT(spin), "value");
 
     g_free (group);
     g_free (pref);
@@ -1060,11 +1058,11 @@ gnc_prefs_connect_combo_box (GtkComboBox *box)
 {
     gchar *group, *pref;
 
-    g_return_if_fail(GTK_IS_COMBO_BOX(box));
+    g_return_if_fail (GTK_IS_COMBO_BOX(box));
 
-    gnc_prefs_split_widget_name (gtk_buildable_get_name(GTK_BUILDABLE(box)), &group, &pref);
+    gnc_prefs_split_widget_name (gtk_buildable_get_name (GTK_BUILDABLE(box)), &group, &pref);
 
-    gnc_prefs_bind (group, pref, G_OBJECT (box), "active");
+    gnc_prefs_bind (group, pref, G_OBJECT(box), "active");
 
     g_free (group);
     g_free (pref);
@@ -1083,16 +1081,16 @@ gnc_prefs_connect_currency_edit (GNCCurrencyEdit *gce, const gchar *boxname )
 {
     gchar *group, *pref;
 
-    g_return_if_fail(GNC_IS_CURRENCY_EDIT(gce));
+    g_return_if_fail (GNC_IS_CURRENCY_EDIT(gce));
 
     gnc_prefs_split_widget_name (boxname, &group, &pref);
 
-    gnc_prefs_bind (group, pref, G_OBJECT (gce), "mnemonic");
+    gnc_prefs_bind (group, pref, G_OBJECT(gce), "mnemonic");
 
     g_free (group);
     g_free (pref);
 
-    gtk_widget_show_all(GTK_WIDGET(gce));
+    gtk_widget_show_all (GTK_WIDGET(gce));
 }
 
 /****************************************************************************/
@@ -1108,11 +1106,11 @@ gnc_prefs_connect_entry (GtkEntry *entry)
 {
     gchar *group, *pref;
 
-    g_return_if_fail(GTK_IS_ENTRY(entry));
+    g_return_if_fail (GTK_IS_ENTRY(entry));
 
-    gnc_prefs_split_widget_name (gtk_buildable_get_name(GTK_BUILDABLE(entry)), &group, &pref);
+    gnc_prefs_split_widget_name (gtk_buildable_get_name (GTK_BUILDABLE(entry)), &group, &pref);
 
-    gnc_prefs_bind (group, pref, G_OBJECT (entry), "text");
+    gnc_prefs_bind (group, pref, G_OBJECT(entry), "text");
 
     g_free (group);
     g_free (pref);
@@ -1131,11 +1129,11 @@ gnc_prefs_connect_period_select (GncPeriodSelect *period, const gchar *boxname )
 {
     gchar *group, *pref;
 
-    g_return_if_fail(GNC_IS_PERIOD_SELECT(period));
+    g_return_if_fail (GNC_IS_PERIOD_SELECT(period));
 
     gnc_prefs_split_widget_name (boxname, &group, &pref);
 
-    gnc_prefs_bind (group, pref, G_OBJECT (period), "active");
+    gnc_prefs_bind (group, pref, G_OBJECT(period), "active");
 
     g_free (group);
     g_free (pref);
@@ -1154,11 +1152,11 @@ gnc_prefs_connect_date_edit (GNCDateEdit *gde , const gchar *boxname )
 {
     gchar *group, *pref;
 
-    g_return_if_fail(GNC_IS_DATE_EDIT(gde));
+    g_return_if_fail (GNC_IS_DATE_EDIT(gde));
 
     gnc_prefs_split_widget_name (boxname, &group, &pref);
 
-    gnc_prefs_bind (group, pref, G_OBJECT (gde), "time");
+    gnc_prefs_bind (group, pref, G_OBJECT(gde), "time");
 
     g_free (group);
     g_free (pref);
@@ -1194,12 +1192,12 @@ gnc_preferences_delete_event_cb (GtkWidget *widget,
  *  @param unused
  */
 void
-gnc_preferences_response_cb(GtkDialog *dialog, gint response, GtkDialog *unused)
+gnc_preferences_response_cb (GtkDialog *dialog, gint response, GtkDialog *unused)
 {
     switch (response)
     {
     case GTK_RESPONSE_HELP:
-        gnc_gnome_help(HF_HELP, HL_GLOBPREFS);
+        gnc_gnome_help (HF_HELP, HL_GLOBPREFS);
         break;
 
     case GTK_RESPONSE_DELETE_EVENT:
@@ -1244,66 +1242,66 @@ gnc_prefs_connect_one (const gchar *name,
     if (GTK_IS_FONT_BUTTON(widget))
     {
         DEBUG("  %s - font button", name);
-        gnc_prefs_connect_font_button(GTK_FONT_BUTTON(widget));
+        gnc_prefs_connect_font_button (GTK_FONT_BUTTON(widget));
     }
     else if (GTK_IS_FILE_CHOOSER_BUTTON(widget))
     {
         DEBUG("  %s - file chooser button", name);
-        gnc_prefs_connect_file_chooser_button(GTK_FILE_CHOOSER_BUTTON(widget), NULL);
+        gnc_prefs_connect_file_chooser_button (GTK_FILE_CHOOSER_BUTTON(widget), NULL);
     }
     else if (GTK_IS_RADIO_BUTTON(widget))
     {
         DEBUG("  %s - radio button", name);
-        gnc_prefs_connect_radio_button(GTK_RADIO_BUTTON(widget));
+        gnc_prefs_connect_radio_button (GTK_RADIO_BUTTON(widget));
     }
     else if (GTK_IS_CHECK_BUTTON(widget))
     {
         DEBUG("  %s - check button", name);
-        gnc_prefs_connect_check_button(GTK_CHECK_BUTTON(widget));
+        gnc_prefs_connect_check_button (GTK_CHECK_BUTTON(widget));
     }
     else if (GTK_IS_SPIN_BUTTON(widget))
     {
         DEBUG("  %s - spin button", name);
-        gnc_prefs_connect_spin_button(GTK_SPIN_BUTTON(widget));
+        gnc_prefs_connect_spin_button (GTK_SPIN_BUTTON(widget));
     }
     else if (GTK_IS_COMBO_BOX(widget))
     {
         DEBUG("  %s - combo box", name);
-        gnc_prefs_connect_combo_box(GTK_COMBO_BOX(widget));
+        gnc_prefs_connect_combo_box (GTK_COMBO_BOX(widget));
     }
     else if (GTK_IS_ENTRY(widget))
     {
         DEBUG("  %s - entry", name);
-        gnc_prefs_connect_entry(GTK_ENTRY(widget));
+        gnc_prefs_connect_entry (GTK_ENTRY(widget));
     }
     else if (GTK_IS_BOX(widget))
     {
         /* Test custom widgets are all children of a hbox */
         GtkWidget *widget_child;
-        GList* child = gtk_container_get_children(GTK_CONTAINER(widget));
+        GList* child = gtk_container_get_children (GTK_CONTAINER(widget));
         widget_child = child->data;
-        g_list_free(child);
+        g_list_free (child);
         DEBUG("  %s - box", name);
-        DEBUG("Box widget type is %s and name is %s", gtk_widget_get_name(GTK_WIDGET(widget_child)), name);
+        DEBUG("Box widget type is %s and name is %s", gtk_widget_get_name (GTK_WIDGET(widget_child)), name);
         if (GNC_IS_CURRENCY_EDIT(widget_child))
         {
             DEBUG("  %s - currency_edit", name);
-            gnc_prefs_connect_currency_edit(GNC_CURRENCY_EDIT(widget_child), name );
+            gnc_prefs_connect_currency_edit (GNC_CURRENCY_EDIT(widget_child), name );
         }
         else if (GNC_IS_PERIOD_SELECT(widget_child))
         {
             DEBUG("  %s - period_select", name);
-            gnc_prefs_connect_period_select(GNC_PERIOD_SELECT(widget_child), name );
+            gnc_prefs_connect_period_select (GNC_PERIOD_SELECT(widget_child), name );
         }
         else if (GNC_IS_DATE_EDIT(widget_child))
         {
             DEBUG("  %s - date_edit", name);
-            gnc_prefs_connect_date_edit(GNC_DATE_EDIT(widget_child), name );
+            gnc_prefs_connect_date_edit (GNC_DATE_EDIT(widget_child), name );
         }
         else if (GTK_FILE_CHOOSER_BUTTON(widget_child))
         {
             DEBUG("  %s - file chooser button", name);
-            gnc_prefs_connect_file_chooser_button(GTK_FILE_CHOOSER_BUTTON(widget_child), name );
+            gnc_prefs_connect_file_chooser_button (GTK_FILE_CHOOSER_BUTTON(widget_child), name );
         }
     }
     else
@@ -1326,7 +1324,7 @@ gnc_prefs_connect_one (const gchar *name,
  *  @return A pointer to the newly created dialog.
  */
 static GtkWidget *
-gnc_preferences_dialog_create(GtkWindow *parent)
+gnc_preferences_dialog_create (GtkWindow *parent)
 {
     GtkBuilder *builder;
     GtkWidget *dialog, *notebook, *label, *image, *spinner, *entry;
@@ -1345,7 +1343,7 @@ gnc_preferences_dialog_create(GtkWindow *parent)
 
     ENTER("");
     DEBUG("Opening dialog-preferences.glade:");
-    builder = gtk_builder_new();
+    builder = gtk_builder_new ();
 
     gnc_builder_add_from_file (builder, "dialog-preferences.glade", "auto_decimal_places_adj");
     gnc_builder_add_from_file (builder, "dialog-preferences.glade", "autosave_interval_minutes_adj");
@@ -1374,31 +1372,31 @@ gnc_preferences_dialog_create(GtkWindow *parent)
 
 #ifndef REGISTER2_ENABLED
     /* Hide preferences that are related to register2 */
-    box = GTK_WIDGET (gtk_builder_get_object (builder, "label14"));
+    box = GTK_WIDGET(gtk_builder_get_object (builder, "label14"));
     gtk_widget_hide (box);
-    box = GTK_WIDGET (gtk_builder_get_object (builder, "pref/general.register/key-length"));
+    box = GTK_WIDGET(gtk_builder_get_object (builder, "pref/general.register/key-length"));
     gtk_widget_hide (box);
-    box = GTK_WIDGET (gtk_builder_get_object (builder, "pref/general.register/show-extra-dates"));
+    box = GTK_WIDGET(gtk_builder_get_object (builder, "pref/general.register/show-extra-dates"));
     gtk_widget_hide (box);
-    box = GTK_WIDGET (gtk_builder_get_object (builder, "pref/general.register/show-calendar-buttons"));
+    box = GTK_WIDGET(gtk_builder_get_object (builder, "pref/general.register/show-calendar-buttons"));
     gtk_widget_hide (box);
-    box = GTK_WIDGET (gtk_builder_get_object (builder, "pref/general.register/selection-to-blank-on-expand"));
+    box = GTK_WIDGET(gtk_builder_get_object (builder, "pref/general.register/selection-to-blank-on-expand"));
     gtk_widget_hide (box);
-    box = GTK_WIDGET (gtk_builder_get_object (builder, "pref/general.register/show-extra-dates-on-selection"));
+    box = GTK_WIDGET(gtk_builder_get_object (builder, "pref/general.register/show-extra-dates-on-selection"));
     gtk_widget_hide (box);
 #endif
 
     label = GTK_WIDGET(gtk_builder_get_object (builder, "sample_account"));
-    g_object_set_data(G_OBJECT(dialog), "sample_account", label);
+    g_object_set_data (G_OBJECT(dialog), "sample_account", label);
 
     image = GTK_WIDGET(gtk_builder_get_object (builder, "separator_error"));
-    g_object_set_data(G_OBJECT(dialog), "separator_error", image);
+    g_object_set_data (G_OBJECT(dialog), "separator_error", image);
 
     entry = GTK_WIDGET(gtk_builder_get_object (builder, "pref/general/account-separator"));
     g_object_set_data (G_OBJECT(dialog), "account-separator", entry);
 
     spinner = GTK_WIDGET(gtk_builder_get_object (builder, "pref/general/save-on-close-wait-time"));
-    g_object_set_data(G_OBJECT(dialog), "save_on_close_wait_time", spinner);
+    g_object_set_data (G_OBJECT(dialog), "save_on_close_wait_time", spinner);
 
     DEBUG("autoconnect");
     gtk_builder_connect_signals_full (builder, gnc_builder_connect_full_func, dialog);
@@ -1406,109 +1404,109 @@ gnc_preferences_dialog_create(GtkWindow *parent)
     DEBUG("done");
 
     notebook = GTK_WIDGET(gtk_builder_get_object (builder, "notebook1"));
-    prefs_table = g_hash_table_new(g_str_hash, g_str_equal);
-    g_object_set_data(G_OBJECT(dialog), NOTEBOOK, notebook);
-    g_object_set_data_full(G_OBJECT(dialog), PREFS_WIDGET_HASH,
-                           prefs_table, (GDestroyNotify)g_hash_table_destroy);
+    prefs_table = g_hash_table_new (g_str_hash, g_str_equal);
+    g_object_set_data (G_OBJECT(dialog), NOTEBOOK, notebook);
+    g_object_set_data_full (G_OBJECT(dialog), PREFS_WIDGET_HASH,
+                            prefs_table, (GDestroyNotify)g_hash_table_destroy);
 
 
-    book = gnc_get_current_book();
+    book = gnc_get_current_book ();
     g_date_clear (&fy_end, 1);
-    qof_instance_get (QOF_INSTANCE (book),
-              "fy-end", &fy_end,
-              NULL);
+    qof_instance_get (QOF_INSTANCE(book),
+                      "fy-end", &fy_end,
+                      NULL);
     box = GTK_WIDGET(gtk_builder_get_object (builder,
                      "pref/" GNC_PREFS_GROUP_ACCT_SUMMARY "/" GNC_PREF_START_PERIOD));
-    period = gnc_period_select_new(TRUE);
+    period = gnc_period_select_new (TRUE);
     gtk_widget_show (period);
-    gtk_box_pack_start (GTK_BOX (box), period, TRUE, TRUE, 0);
+    gtk_box_pack_start (GTK_BOX(box), period, TRUE, TRUE, 0);
     if (date_is_valid)
-        gnc_period_select_set_fy_end(GNC_PERIOD_SELECT (period), &fy_end);
+        gnc_period_select_set_fy_end (GNC_PERIOD_SELECT(period), &fy_end);
 
     box = GTK_WIDGET(gtk_builder_get_object (builder,
                      "pref/" GNC_PREFS_GROUP_ACCT_SUMMARY "/" GNC_PREF_END_PERIOD));
-    period = gnc_period_select_new(FALSE);
+    period = gnc_period_select_new (FALSE);
     gtk_widget_show (period);
-    gtk_box_pack_start (GTK_BOX (box), period, TRUE, TRUE, 0);
+    gtk_box_pack_start (GTK_BOX(box), period, TRUE, TRUE, 0);
     if (date_is_valid)
-        gnc_period_select_set_fy_end(GNC_PERIOD_SELECT (period), &fy_end);
+        gnc_period_select_set_fy_end (GNC_PERIOD_SELECT(period), &fy_end);
 
     box = GTK_WIDGET(gtk_builder_get_object (builder,
                      "pref/" GNC_PREFS_GROUP_ACCT_SUMMARY "/" GNC_PREF_START_DATE));
-    date = gnc_date_edit_new(gnc_time (NULL), FALSE, FALSE);
+    date = gnc_date_edit_new (gnc_time (NULL), FALSE, FALSE);
     gtk_widget_show (date);
-    gtk_box_pack_start (GTK_BOX (box), date, TRUE, TRUE, 0);
+    gtk_box_pack_start (GTK_BOX(box), date, TRUE, TRUE, 0);
 
     box = GTK_WIDGET(gtk_builder_get_object (builder,
                      "pref/" GNC_PREFS_GROUP_ACCT_SUMMARY "/" GNC_PREF_END_DATE));
-    date = gnc_date_edit_new(gnc_time (NULL), FALSE, FALSE);
+    date = gnc_date_edit_new (gnc_time (NULL), FALSE, FALSE);
     gtk_widget_show (date);
-    gtk_box_pack_start (GTK_BOX (box), date, TRUE, TRUE, 0);
+    gtk_box_pack_start (GTK_BOX(box), date, TRUE, TRUE, 0);
 
     box = GTK_WIDGET(gtk_builder_get_object (builder,
                      "pref/" GNC_PREFS_GROUP_GENERAL "/" GNC_PREF_CURRENCY_OTHER));
-    currency = gnc_currency_edit_new();
+    currency = gnc_currency_edit_new ();
     gnc_currency_edit_set_currency (GNC_CURRENCY_EDIT(currency), gnc_default_currency());
     gtk_widget_show (currency);
-    gtk_box_pack_start(GTK_BOX (box), currency, TRUE, TRUE, 0);
+    gtk_box_pack_start (GTK_BOX(box), currency, TRUE, TRUE, 0);
 
     box = GTK_WIDGET(gtk_builder_get_object (builder,
                      "pref/" GNC_PREFS_GROUP_GENERAL_REPORT "/" GNC_PREF_CURRENCY_OTHER));
-    currency = gnc_currency_edit_new();
+    currency = gnc_currency_edit_new ();
     gnc_currency_edit_set_currency (GNC_CURRENCY_EDIT(currency), gnc_default_currency());
     gtk_widget_show (currency);
-    gtk_box_pack_start(GTK_BOX (box), currency, TRUE, TRUE, 0);
+    gtk_box_pack_start (GTK_BOX(box), currency, TRUE, TRUE, 0);
 
     box = GTK_WIDGET(gtk_builder_get_object (builder,
                      "pref/" GNC_PREFS_GROUP_GENERAL "/" GNC_DOC_LINK_PATH_HEAD));
     fcb = gtk_file_chooser_button_new (_("Select a folder"),
-                             GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER);
-    gtk_box_pack_start (GTK_BOX (box), fcb, TRUE, TRUE, 0);
+                                       GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER);
+    gtk_box_pack_start (GTK_BOX(box), fcb, TRUE, TRUE, 0);
     button = gtk_button_new_with_label (_("Clear"));
-    gtk_box_pack_start (GTK_BOX (box), button, TRUE, TRUE, 0);
+    gtk_box_pack_start (GTK_BOX(box), button, TRUE, TRUE, 0);
     gtk_widget_show (button);
     g_signal_connect (GTK_BUTTON(button), "clicked",
                       G_CALLBACK(file_chooser_clear_cb), fcb);
 
     image = GTK_WIDGET(gtk_builder_get_object (builder, "path_head_error"));
-    g_object_set_data(G_OBJECT(fcb), "path_head_error", image);
+    g_object_set_data (G_OBJECT(fcb), "path_head_error", image);
 
     /* Add to the list of interesting widgets */
-    gnc_prefs_build_widget_table(builder, dialog);
+    gnc_prefs_build_widget_table (builder, dialog);
 
-    g_slist_foreach(add_ins, gnc_preferences_build_page, dialog);
+    g_slist_foreach (add_ins, gnc_preferences_build_page, dialog);
 
     /* Sort tabs alphabetically */
-    gnc_prefs_sort_pages(GTK_NOTEBOOK(notebook));
-    gtk_notebook_set_current_page(GTK_NOTEBOOK(notebook), 0);
+    gnc_prefs_sort_pages (GTK_NOTEBOOK(notebook));
+    gtk_notebook_set_current_page (GTK_NOTEBOOK(notebook), 0);
 
     DEBUG("We have the following interesting widgets:");
-    gnc_prefs_block_all(); // Block All Registered callbacks
-    g_hash_table_foreach(prefs_table, (GHFunc)gnc_prefs_connect_one, dialog);
-    gnc_prefs_unblock_all(); // UnBlock All Registered callbacks
+    gnc_prefs_block_all (); // Block All Registered callbacks
+    g_hash_table_foreach (prefs_table, (GHFunc)gnc_prefs_connect_one, dialog);
+    gnc_prefs_unblock_all (); // UnBlock All Registered callbacks
     DEBUG("Done with interesting widgets.");
 
     /* Other stuff */
-    gdate = g_date_new_dmy(31, G_DATE_JULY, 2013);
-    g_date_strftime(buf, sizeof(buf), "%x", gdate);
+    gdate = g_date_new_dmy (31, G_DATE_JULY, 2013);
+    g_date_strftime (buf, sizeof(buf), "%x", gdate);
     store = GTK_LIST_STORE(gtk_builder_get_object (builder, "date_formats"));
     path = gtk_tree_path_new_from_indices (QOF_DATE_FORMAT_LOCALE, -1);
-    if (gtk_tree_model_get_iter (GTK_TREE_MODEL (store), &iter, path))
-            gtk_list_store_set (store, &iter, 1, buf, -1);
-    g_date_free(gdate);
+    if (gtk_tree_model_get_iter (GTK_TREE_MODEL(store), &iter, path))
+        gtk_list_store_set (store, &iter, 1, buf, -1);
+    g_date_free (gdate);
     gtk_tree_path_free (path);
 
     locale_currency = gnc_locale_default_currency ();
-    currency_name = gnc_commodity_get_printname(locale_currency);
+    currency_name = gnc_commodity_get_printname (locale_currency);
     label = GTK_WIDGET(gtk_builder_get_object (builder, "locale_currency"));
-    gtk_label_set_label(GTK_LABEL(label), currency_name);
+    gtk_label_set_label (GTK_LABEL(label), currency_name);
     label = GTK_WIDGET(gtk_builder_get_object (builder, "locale_currency2"));
-    gtk_label_set_label(GTK_LABEL(label), currency_name);
+    gtk_label_set_label (GTK_LABEL(label), currency_name);
 
     button = GTK_WIDGET(gtk_builder_get_object (builder, "pref/general/save-on-close-expires"));
     gnc_save_on_close_expires_cb (GTK_TOGGLE_BUTTON(button), dialog);
 
-    g_object_unref(G_OBJECT(builder));
+    g_object_unref (G_OBJECT(builder));
 
     /* save the original account separator incase it changes */
     g_object_set_data_full (G_OBJECT(entry), "original_text",
@@ -1548,7 +1546,7 @@ show_handler (const char *class_name, gint component_id,
 
     ENTER(" ");
     dialog = GTK_WIDGET(user_data);
-    gtk_window_present(GTK_WINDOW(dialog));
+    gtk_window_present (GTK_WINDOW(dialog));
     LEAVE(" ");
     return(TRUE);
 }
@@ -1567,8 +1565,8 @@ close_handler (gpointer user_data)
 
     ENTER(" ");
     dialog = GTK_WIDGET(user_data);
-    gnc_unregister_gui_component_by_data(DIALOG_PREFERENCES_CM_CLASS, dialog);
-    gtk_widget_destroy(dialog);
+    gnc_unregister_gui_component_by_data (DIALOG_PREFERENCES_CM_CLASS, dialog);
+    gtk_widget_destroy (dialog);
     LEAVE(" ");
 }
 
@@ -1583,8 +1581,8 @@ gnc_preferences_dialog (GtkWindow *parent)
     GtkWidget *dialog;
 
     ENTER("");
-    if (gnc_forall_gui_components(DIALOG_PREFERENCES_CM_CLASS,
-                                  show_handler, NULL))
+    if (gnc_forall_gui_components (DIALOG_PREFERENCES_CM_CLASS,
+                                   show_handler, NULL))
     {
         LEAVE("existing window");
         return;
@@ -1592,11 +1590,11 @@ gnc_preferences_dialog (GtkWindow *parent)
 
     dialog = gnc_preferences_dialog_create(parent);
 
-    gnc_restore_window_size(GNC_PREFS_GROUP, GTK_WINDOW(dialog), parent);
-    gtk_widget_show(dialog);
+    gnc_restore_window_size (GNC_PREFS_GROUP, GTK_WINDOW(dialog), parent);
+    gtk_widget_show (dialog);
 
-    gnc_register_gui_component(DIALOG_PREFERENCES_CM_CLASS,
-                               NULL, close_handler, dialog);
+    gnc_register_gui_component (DIALOG_PREFERENCES_CM_CLASS,
+                                NULL, close_handler, dialog);
 
     LEAVE(" ");
 }

commit 39827ce7bba8d87dd40921c33cde666446e559e6
Author: Robert Fewell <14uBobIT at gmail.com>
Date:   Tue Nov 3 13:59:14 2020 +0000

    Change Preference dialog account separator validation
    
    If the account separator is changed and is invalid the warning dialog
    may be shown many times. To fix this the validation is done on closing
    the preference dialog when a validation dialog will present two options,
    The first is to reset the separator to the original value and close the
    preference dialog and the second is to return to the 'Accounts' page of
    the preference dialog.
    
    The warning symbol is still displayed when the separator is changed
    giving an indication of a problem.
    
    This has stemmed from PR #766 and all this commit does is the minimum
    recommended there.

diff --git a/gnucash/gnome-utils/dialog-preferences.c b/gnucash/gnome-utils/dialog-preferences.c
index 5b9e1bf8b..9b8137dcc 100644
--- a/gnucash/gnome-utils/dialog-preferences.c
+++ b/gnucash/gnome-utils/dialog-preferences.c
@@ -90,8 +90,10 @@ static QofLogModule log_module = GNC_MOD_PREFS;
 
 void gnc_preferences_response_cb(GtkDialog *dialog, gint response, GtkDialog *unused);
 void gnc_account_separator_pref_changed_cb (GtkEntry *entry, GtkWidget *dialog);
-gboolean gnc_account_separator_validate_cb (GtkEntry *entry, GdkEvent *event, GtkWidget *dialog);
 void gnc_save_on_close_expires_cb (GtkToggleButton *button, GtkWidget *dialog);
+gboolean gnc_preferences_delete_event_cb (GtkWidget *widget,
+                                          GdkEvent  *event,
+                                          gpointer   user_data);
 
 /** This data structure holds the information for a single addition to
  *  the preferences dialog. */
@@ -185,23 +187,96 @@ gnc_account_separator_pref_changed_cb (GtkEntry *entry, GtkWidget *dialog)
 }
 
 
-gboolean
-gnc_account_separator_validate_cb (GtkEntry *entry, GdkEvent *event, GtkWidget *dialog)
+/** Called when the 'Close' button pressed or preference dialog closes
+ *  to check if the account separator is valid.
+ *  Offers two choices, to reset separator to original value and exit
+ *  or go back to the 'Accounts' page to change separator
+ *
+ *  @internal
+ *
+ *  @param dialog the prefs dialog.
+ */
+static gboolean
+gnc_account_separator_validate (GtkWidget *dialog)
 {
+    GtkWidget *entry = g_object_get_data (G_OBJECT(dialog), "account-separator");
+    gboolean ret = TRUE;
     gchar *separator;
-    gchar *conflict_msg = gnc_account_separator_is_valid (gtk_entry_get_text (entry), &separator);
+    gchar *conflict_msg = gnc_account_separator_is_valid (gtk_entry_get_text (GTK_ENTRY(entry)), &separator);
 
     /* Check if the new separator clashes with existing account names */
-
     if (conflict_msg)
     {
-        gnc_warning_dialog (GTK_WINDOW (dialog), "%s", conflict_msg);
-        g_free ( conflict_msg );
+        GtkWidget   *msg_dialog;
+        GtkBuilder  *builder;
+        GtkWidget   *msg_label;
+        gint         response;
+
+        builder = gtk_builder_new();
+        gnc_builder_add_from_file (builder, "dialog-preferences.glade", "separator_validation_dialog");
+
+        msg_dialog = GTK_WIDGET(gtk_builder_get_object (builder, "separator_validation_dialog"));
+
+        msg_label = GTK_WIDGET(gtk_builder_get_object (builder, "conflict_message"));
+
+        gtk_label_set_text (GTK_LABEL(msg_label), conflict_msg);
+
+        g_object_unref (G_OBJECT(builder));
+        gtk_widget_show_all (msg_dialog);
+
+        response = gtk_dialog_run (GTK_DIALOG(msg_dialog));
+        if (response == GTK_RESPONSE_ACCEPT) // reset to original
+        {
+            gchar *original_sep = g_object_get_data (G_OBJECT(entry), "original_text");
+
+            if (original_sep != NULL)
+                gtk_entry_set_text (GTK_ENTRY(entry), original_sep);
+        }
+        else
+            ret = FALSE;
+
+        g_free (conflict_msg);
+        gtk_widget_destroy (msg_dialog);
     }
     g_free (separator);
-    return FALSE;
+    return ret;
 }
 
+
+/** Used to select the 'Accounts' page when the user wants
+ *  to return from the account separator validation dialog
+ *  to the preference dialog.
+ *
+ *  @internal
+ *
+ *  @param user_data A pointer to the dialog.
+ */
+static void
+gnc_preferences_select_account_page (GtkDialog *dialog)
+{
+    GtkWidget *notebook = g_object_get_data (G_OBJECT(dialog), NOTEBOOK);
+    GList *children = gtk_container_get_children (GTK_CONTAINER(notebook));
+
+    if (children)
+    {
+        GtkWidget *acc_page = NULL;
+        GList *node;
+
+        for (node = children; node; node = node->next)
+        {
+            if (g_strcmp0 (gtk_widget_get_name (GTK_WIDGET(node->data)), "accounts_page") == 0)
+                acc_page = node->data;
+        }
+
+        if (acc_page)
+            gtk_notebook_set_current_page (GTK_NOTEBOOK(notebook),
+                                           gtk_notebook_page_num (GTK_NOTEBOOK(notebook),
+                                           acc_page));
+    }
+    g_list_free (children);
+}
+
+
 /** Called when the save-on-close checkbutton is toggled.
  * @internal
  * @param button the toggle button.
@@ -1096,6 +1171,15 @@ gnc_prefs_connect_date_edit (GNCDateEdit *gde , const gchar *boxname )
 /*    Callbacks     */
 /********************/
 
+gboolean
+gnc_preferences_delete_event_cb (GtkWidget *widget,
+                                 GdkEvent  *event,
+                                 gpointer   user_data)
+{
+    /* need to block this for the account separator test */
+    return TRUE;
+}
+
 /** Handle a user click on one of the buttons at the bottom of the
  *  preference dialog.  Also handles delete_window events, which have
  *  conveniently converted to a response by GtkDialog.
@@ -1118,11 +1202,17 @@ gnc_preferences_response_cb(GtkDialog *dialog, gint response, GtkDialog *unused)
         gnc_gnome_help(HF_HELP, HL_GLOBPREFS);
         break;
 
+    case GTK_RESPONSE_DELETE_EVENT:
     default:
-        gnc_save_window_size(GNC_PREFS_GROUP, GTK_WINDOW(dialog));
-        gnc_unregister_gui_component_by_data(DIALOG_PREFERENCES_CM_CLASS,
-                                             dialog);
-        gtk_widget_destroy(GTK_WIDGET(dialog));
+        if (gnc_account_separator_validate (GTK_WIDGET(dialog)))
+        {
+            gnc_save_window_size (GNC_PREFS_GROUP, GTK_WINDOW(dialog));
+            gnc_unregister_gui_component_by_data (DIALOG_PREFERENCES_CM_CLASS,
+                                                  dialog);
+            gtk_widget_destroy (GTK_WIDGET(dialog));
+        }
+        else
+            gnc_preferences_select_account_page (dialog);
         break;
     }
 }
@@ -1239,7 +1329,7 @@ static GtkWidget *
 gnc_preferences_dialog_create(GtkWindow *parent)
 {
     GtkBuilder *builder;
-    GtkWidget *dialog, *notebook, *label, *image, *spinner;
+    GtkWidget *dialog, *notebook, *label, *image, *spinner, *entry;
     GtkWidget *box, *date, *period, *currency, *fcb, *button;
     GHashTable *prefs_table;
     GDate* gdate = NULL;
@@ -1304,6 +1394,9 @@ gnc_preferences_dialog_create(GtkWindow *parent)
     image = GTK_WIDGET(gtk_builder_get_object (builder, "separator_error"));
     g_object_set_data(G_OBJECT(dialog), "separator_error", image);
 
+    entry = GTK_WIDGET(gtk_builder_get_object (builder, "pref/general/account-separator"));
+    g_object_set_data (G_OBJECT(dialog), "account-separator", entry);
+
     spinner = GTK_WIDGET(gtk_builder_get_object (builder, "pref/general/save-on-close-wait-time"));
     g_object_set_data(G_OBJECT(dialog), "save_on_close_wait_time", spinner);
 
@@ -1417,6 +1510,11 @@ gnc_preferences_dialog_create(GtkWindow *parent)
 
     g_object_unref(G_OBJECT(builder));
 
+    /* save the original account separator incase it changes */
+    g_object_set_data_full (G_OBJECT(entry), "original_text",
+                            g_strdup (gtk_entry_get_text (GTK_ENTRY(entry))),
+                            g_free);
+
     LEAVE("dialog %p", dialog);
     return dialog;
 }
diff --git a/gnucash/gtkbuilder/dialog-preferences.glade b/gnucash/gtkbuilder/dialog-preferences.glade
index 3233c736c..43c574508 100644
--- a/gnucash/gtkbuilder/dialog-preferences.glade
+++ b/gnucash/gtkbuilder/dialog-preferences.glade
@@ -113,6 +113,121 @@
     <property name="step_increment">1</property>
     <property name="page_increment">10</property>
   </object>
+  <object class="GtkDialog" id="separator_validation_dialog">
+    <property name="can_focus">False</property>
+    <property name="modal">True</property>
+    <property name="default_width">600</property>
+    <property name="destroy_with_parent">True</property>
+    <property name="type_hint">dialog</property>
+    <child internal-child="vbox">
+      <object class="GtkBox">
+        <property name="can_focus">False</property>
+        <property name="orientation">vertical</property>
+        <property name="spacing">2</property>
+        <child internal-child="action_area">
+          <object class="GtkButtonBox">
+            <property name="can_focus">False</property>
+            <property name="layout_style">end</property>
+            <child>
+              <object class="GtkButton" id="button1">
+                <property name="label" translatable="yes">_Reset</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">True</property>
+                <property name="use_underline">True</property>
+              </object>
+              <packing>
+                <property name="expand">True</property>
+                <property name="fill">True</property>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkButton" id="button2">
+                <property name="label" translatable="yes">_Close</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="can_default">True</property>
+                <property name="has_default">True</property>
+                <property name="receives_default">True</property>
+                <property name="use_underline">True</property>
+              </object>
+              <packing>
+                <property name="expand">True</property>
+                <property name="fill">True</property>
+                <property name="position">1</property>
+              </packing>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">False</property>
+            <property name="position">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkBox">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="orientation">vertical</property>
+            <property name="spacing">6</property>
+            <child>
+              <object class="GtkLabel" id="sep_label">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes"><b>Separator Character</b></property>
+                <property name="use_markup">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkLabel" id="conflict_message">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="wrap">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">1</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkLabel" id="message">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="margin_top">12</property>
+                <property name="label" translatable="yes">Press 'Reset' to use the original account separator and close the preference window
+Press 'Close' to return to the preference window
+</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">2</property>
+              </packing>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="position">1</property>
+          </packing>
+        </child>
+      </object>
+    </child>
+    <action-widgets>
+      <action-widget response="-3">button1</action-widget>
+      <action-widget response="-7">button2</action-widget>
+    </action-widgets>
+    <child type="titlebar">
+      <placeholder/>
+    </child>
+  </object>
   <object class="GtkAdjustment" id="tab_width_adj">
     <property name="lower">1</property>
     <property name="upper">100</property>
@@ -126,6 +241,7 @@
     <property name="default_width">600</property>
     <property name="default_height">400</property>
     <property name="type_hint">normal</property>
+    <signal name="delete-event" handler="gnc_preferences_delete_event_cb" swapped="no"/>
     <signal name="response" handler="gnc_preferences_response_cb" swapped="no"/>
     <child internal-child="vbox">
       <object class="GtkBox">
@@ -449,6 +565,7 @@
             </child>
             <child>
               <object class="GtkGrid" id="table1">
+                <property name="name">accounts_page</property>
                 <property name="visible">True</property>
                 <property name="can_focus">False</property>
                 <property name="border_width">6</property>
@@ -739,6 +856,7 @@
                         <property name="can_focus">False</property>
                         <property name="halign">start</property>
                         <property name="icon_name">dialog-warning</property>
+                        <property name="icon_size">3</property>
                       </object>
                       <packing>
                         <property name="expand">False</property>
@@ -758,7 +876,6 @@
                         <property name="primary_icon_activatable">False</property>
                         <property name="secondary_icon_activatable">False</property>
                         <signal name="changed" handler="gnc_account_separator_pref_changed_cb" swapped="no"/>
-                        <signal name="focus-out-event" handler="gnc_account_separator_validate_cb" swapped="no"/>
                       </object>
                       <packing>
                         <property name="expand">True</property>



Summary of changes:
 gnucash/gnome-utils/dialog-preferences.c    | 520 ++++++++++++++++------------
 gnucash/gtkbuilder/dialog-import.glade      |  22 +-
 gnucash/gtkbuilder/dialog-preferences.glade | 119 ++++++-
 gnucash/import-export/import-main-matcher.c | 485 ++++++++++++++------------
 gnucash/import-export/import-main-matcher.h |  34 +-
 gnucash/import-export/ofx/gnc-ofx-import.c  |  24 +-
 6 files changed, 748 insertions(+), 456 deletions(-)



More information about the gnucash-changes mailing list