r19627 - gnucash/trunk/src - Re-indentation of source code.

Christian Stimming cstim at code.gnucash.org
Sun Oct 3 08:27:44 EDT 2010


Author: cstim
Date: 2010-10-03 08:27:44 -0400 (Sun, 03 Oct 2010)
New Revision: 19627
Trac: http://svn.gnucash.org/trac/changeset/19627

Modified:
   gnucash/trunk/src/app-utils/gnc-sx-instance-model.c
   gnucash/trunk/src/app-utils/gnc-sx-instance-model.h
   gnucash/trunk/src/app-utils/gnc-ui-util.c
   gnucash/trunk/src/backend/xml/io-gncxml-v2.c
   gnucash/trunk/src/business/business-gnome/dialog-invoice.c
   gnucash/trunk/src/core-utils/gnc-path.c
   gnucash/trunk/src/engine/SchedXaction.c
   gnucash/trunk/src/engine/cap-gains.c
   gnucash/trunk/src/engine/gncBusiness.c
   gnucash/trunk/src/engine/gncIDSearch.c
   gnucash/trunk/src/gnome-search/dialog-search.c
   gnucash/trunk/src/gnome-utils/dialog-account.c
   gnucash/trunk/src/gnome-utils/gnc-file.c
   gnucash/trunk/src/gnome-utils/gnc-tree-view.c
   gnucash/trunk/src/gnome/dialog-print-check.c
   gnucash/trunk/src/gnome/dialog-sx-editor.c
   gnucash/trunk/src/gnome/gnc-plugin-page-register.c
   gnucash/trunk/src/import-export/aqbanking/gnc-ab-utils.c
   gnucash/trunk/src/import-export/aqbanking/gnc-gwen-gui.c
   gnucash/trunk/src/libqof/qof/gnc-date.c
   gnucash/trunk/src/register/register-gnome/gnucash-header.c
   gnucash/trunk/src/report/report-gnome/gnc-plugin-page-report.c
Log:
Re-indentation of source code.

This re-indentation was done using astyle-1.24 using the following options:

 astyle --indent=spaces=4 --brackets=break --pad-oper --pad-header --suffix=none

Modified: gnucash/trunk/src/app-utils/gnc-sx-instance-model.c
===================================================================
--- gnucash/trunk/src/app-utils/gnc-sx-instance-model.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/app-utils/gnc-sx-instance-model.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -962,7 +962,7 @@
                                       NULL);
     *numeric = kvp_value_get_numeric(kvp_val);
     if ((gnc_numeric_check(*numeric) == GNC_ERROR_OK)
-        && !gnc_numeric_zero_p(*numeric))
+            && !gnc_numeric_zero_p(*numeric))
     {
         /* Already a valid non-zero result? Then return and don't
          * parse the string. Luckily we avoid any locale problems with
@@ -1482,7 +1482,8 @@
                                   NULL, gnc_numeric_free);
 }
 
-typedef struct {
+typedef struct
+{
     GHashTable *hash;
     GList **creation_errors;
     const SchedXaction *sx;
@@ -1571,8 +1572,8 @@
     }
 
     for (;
-         template_splits;
-         template_splits = template_splits->next)
+            template_splits;
+            template_splits = template_splits->next)
     {
         Account *split_acct;
         const gnc_commodity *split_cmdty = NULL;
@@ -1653,8 +1654,8 @@
 
 static void
 instantiate_cashflow_internal(const SchedXaction* sx,
-                                     GHashTable* map,
-                                     GList **creation_errors, gint count)
+                              GHashTable* map,
+                              GList **creation_errors, gint count)
 {
     SxCashflowData create_cashflow_data;
     Account* sx_template_account = gnc_sx_get_template_transaction_account(sx);
@@ -1685,7 +1686,8 @@
     instantiate_cashflow_internal(sx, map, creation_errors, 1);
 }
 
-typedef struct {
+typedef struct
+{
     GHashTable *hash;
     GList **creation_errors;
     const GDate *range_start;

Modified: gnucash/trunk/src/app-utils/gnc-sx-instance-model.h
===================================================================
--- gnucash/trunk/src/app-utils/gnc-sx-instance-model.h	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/app-utils/gnc-sx-instance-model.h	2010-10-03 12:27:44 UTC (rev 19627)
@@ -240,7 +240,7 @@
  * occurred during creation, similar as in
  * gnc_sx_instance_model_effect_change(). */
 void gnc_sx_instantiate_cashflow(const SchedXaction* sx,
-								 GHashTable* map, GList **creation_errors);
+                                 GHashTable* map, GList **creation_errors);
 
 /** Instantiates the cash flow of all given SXs (in the given
  * GList<SchedXAction*>) into the GHashTable<GUID*, gnc_numeric*> for the
@@ -251,8 +251,8 @@
  * occurred during creation, similar as in
  * gnc_sx_instance_model_effect_change(). */
 void gnc_sx_all_instantiate_cashflow(GList *all_sxes,
-									 const GDate *range_start, const GDate *range_end,
-									 GHashTable* map, GList **creation_errors);
+                                     const GDate *range_start, const GDate *range_end,
+                                     GHashTable* map, GList **creation_errors);
 
 /** Simplified wrapper around gnc_sx_all_instantiate_cashflow(): Run
  * that function on all SX of the current book for the given date

Modified: gnucash/trunk/src/app-utils/gnc-ui-util.c
===================================================================
--- gnucash/trunk/src/app-utils/gnc-ui-util.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/app-utils/gnc-ui-util.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -495,7 +495,7 @@
     {
         const gchar *num_code = NULL;
         const gchar *prefix = "N";
-        
+
         tax_type = gnc_get_current_book_tax_type ();
         if (tax_type == NULL || (safe_strcmp (tax_type, "") == 0))
             return g_strdup (_("Tax entity type not specified"));

Modified: gnucash/trunk/src/backend/xml/io-gncxml-v2.c
===================================================================
--- gnucash/trunk/src/backend/xml/io-gncxml-v2.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/backend/xml/io-gncxml-v2.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -310,7 +310,7 @@
                 /* replace the gnc_book_init-created root account */
                 gnc_book_set_template_root(book, (Account *)n->data);
             }
-            else 
+            else
             {
                 /* This is an old data file that doesn't have a template root
                    account and this is a top level account.  Make it a child

Modified: gnucash/trunk/src/business/business-gnome/dialog-invoice.c
===================================================================
--- gnucash/trunk/src/business/business-gnome/dialog-invoice.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/business/business-gnome/dialog-invoice.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -676,7 +676,7 @@
     acct_commodities = gnc_business_commodities(&(iw->owner));
 
     /* Get the due date and posted account */
-    postdate=gncInvoiceGetDateOpened (invoice);
+    postdate = gncInvoiceGetDateOpened (invoice);
     ddue = postdate;
     memo = NULL;
 
@@ -2586,10 +2586,10 @@
         else
         {
             QofQueryPredData *inv_type_pred;
-            GSList *param_list=NULL;
+            GSList *param_list = NULL;
             inv_type_pred = qof_query_string_predicate(QOF_COMPARE_EQUAL,
-                                                       gncInvoiceGetTypeFromOwnerType(owner_type),
-                                                       QOF_STRING_MATCH_NORMAL, FALSE);
+                            gncInvoiceGetTypeFromOwnerType(owner_type),
+                            QOF_STRING_MATCH_NORMAL, FALSE);
             param_list = g_slist_prepend (param_list, INVOICE_TYPE);
             gncQueryAddTerm (q, param_list, inv_type_pred, QOF_QUERY_AND);
         }

Modified: gnucash/trunk/src/core-utils/gnc-path.c
===================================================================
--- gnucash/trunk/src/core-utils/gnc-path.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/core-utils/gnc-path.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -133,7 +133,7 @@
 {
     gchar *pkgdatadir = gnc_path_get_pkgdatadir ();
     gchar *result = g_build_filename (pkgdatadir, "guile-modules",
-            "gnucash", "report", (char*)NULL);
+                                      "gnucash", "report", (char*)NULL);
     g_free (pkgdatadir);
     //printf("Returning stdreportsdir %s\n", result);
     return result;

Modified: gnucash/trunk/src/engine/SchedXaction.c
===================================================================
--- gnucash/trunk/src/engine/SchedXaction.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/engine/SchedXaction.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -697,9 +697,9 @@
 
     /* SX still active? If not, return now. */
     if ((xaccSchedXactionHasOccurDef(sx)
-         && xaccSchedXactionGetRemOccur(sx) <= 0)
-        || (xaccSchedXactionHasEndDate(sx)
-            && g_date_compare(xaccSchedXactionGetEndDate(sx), start_date) < 0))
+            && xaccSchedXactionGetRemOccur(sx) <= 0)
+            || (xaccSchedXactionHasEndDate(sx)
+                && g_date_compare(xaccSchedXactionGetEndDate(sx), start_date) < 0))
     {
         return result;
     }
@@ -710,7 +710,7 @@
      * SX has not yet occurred so far, or if its last valid date was
      * before the start date. */
     countFirstDate = !g_date_valid(&tmpState->last_date)
-        || (g_date_compare(&tmpState->last_date, start_date) < 0);
+                     || (g_date_compare(&tmpState->last_date, start_date) < 0);
 
     /* No valid date? SX has never occurred so far. */
     if (!g_date_valid(&tmpState->last_date))
@@ -740,16 +740,16 @@
     /* Now we are in our interval of interest. Increment the
      * occurrence date until we are beyond the end of our interval. */
     while ((g_date_compare(&tmpState->last_date, end_date) <= 0)
-           && (!xaccSchedXactionHasEndDate(sx)
-               || g_date_compare(&tmpState->last_date, xaccSchedXactionGetEndDate(sx)) <= 0))
+            && (!xaccSchedXactionHasEndDate(sx)
+                || g_date_compare(&tmpState->last_date, xaccSchedXactionGetEndDate(sx)) <= 0))
     {
         ++result;
         gnc_sx_incr_temporal_state (sx, tmpState);
         /* Make sure to check for invalid dates here: It means the SX
          * has ended. */
         if (!g_date_valid(&tmpState->last_date)
-            || (xaccSchedXactionHasOccurDef(sx)
-                && tmpState->num_occur_rem <= 0))
+                || (xaccSchedXactionHasOccurDef(sx)
+                    && tmpState->num_occur_rem <= 0))
         {
             break;
         }

Modified: gnucash/trunk/src/engine/cap-gains.c
===================================================================
--- gnucash/trunk/src/engine/cap-gains.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/engine/cap-gains.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -974,7 +974,7 @@
         {
             trans = lot_split->parent;
             gain_split = xaccSplitGetOtherSplit (lot_split);
-            
+
             /* If the gains transaction has been edited so that it no longer has
                just two splits, ignore it and assume it's still correct. */
             if (!gain_split)
@@ -986,12 +986,12 @@
              * gnc_book_partition_txn and depending on the order in which things
              * happen some splits may be in the wrong book at that time. */
             else if (split->gains_split == lot_split &&
-                    lot_split->gains_split == split &&
-                    gain_split->gains_split == split &&
-                    gnc_numeric_equal (xaccSplitGetValue (lot_split), value) &&
-                    gnc_numeric_zero_p (xaccSplitGetAmount (lot_split)) &&
-                    gnc_numeric_equal (xaccSplitGetValue (gain_split), negvalue) &&
-                    gnc_numeric_equal (xaccSplitGetAmount (gain_split), negvalue))
+                     lot_split->gains_split == split &&
+                     gain_split->gains_split == split &&
+                     gnc_numeric_equal (xaccSplitGetValue (lot_split), value) &&
+                     gnc_numeric_zero_p (xaccSplitGetAmount (lot_split)) &&
+                     gnc_numeric_equal (xaccSplitGetValue (gain_split), negvalue) &&
+                     gnc_numeric_equal (xaccSplitGetAmount (gain_split), negvalue))
             {
                 new_gain_split = FALSE;
             }

Modified: gnucash/trunk/src/engine/gncBusiness.c
===================================================================
--- gnucash/trunk/src/engine/gncBusiness.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/engine/gncBusiness.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -31,8 +31,8 @@
 
 struct _get_list_userdata
 {
-        GList *result;
-        QofAccessFunc is_active_accessor_func;
+    GList *result;
+    QofAccessFunc is_active_accessor_func;
 };
 static void get_list_cb (QofInstance *inst, gpointer user_data)
 {

Modified: gnucash/trunk/src/engine/gncIDSearch.c
===================================================================
--- gnucash/trunk/src/engine/gncIDSearch.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/engine/gncIDSearch.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -34,38 +34,38 @@
 GncCustomer *
 gnc_search_customer_on_id (QofBook * book, const gchar *id)
 {
-	GncCustomer *customer = NULL;
-	GNCIdType type = GNC_CUSTOMER_MODULE_NAME;
-	customer = (GncCustomer*)search(book, id, customer, type);
-	return customer;
+    GncCustomer *customer = NULL;
+    GNCIdType type = GNC_CUSTOMER_MODULE_NAME;
+    customer = (GncCustomer*)search(book, id, customer, type);
+    return customer;
 }
 
 GncInvoice *
 gnc_search_invoice_on_id (QofBook * book, const gchar *id)
 {
-	GncInvoice *invoice = NULL;
-	GNCIdType type = GNC_INVOICE_MODULE_NAME;
-	invoice = (GncInvoice*)search(book,id, invoice, type);
-	return invoice;
-		}
+    GncInvoice *invoice = NULL;
+    GNCIdType type = GNC_INVOICE_MODULE_NAME;
+    invoice = (GncInvoice*)search(book, id, invoice, type);
+    return invoice;
+}
 
 /* Essentially identical to above.*/
 GncInvoice *
 gnc_search_bill_on_id (QofBook * book, const gchar *id)
 {
-	GncInvoice *bill =  NULL;
-	GNCIdType type = GNC_INVOICE_MODULE_NAME;
-	bill = (GncInvoice*)search(book, id, bill, type);
-	return bill;
-	}
+    GncInvoice *bill =  NULL;
+    GNCIdType type = GNC_INVOICE_MODULE_NAME;
+    bill = (GncInvoice*)search(book, id, bill, type);
+    return bill;
+}
 
 GncVendor *
 gnc_search_vendor_on_id (QofBook * book, const gchar *id)
 {
-	GncVendor *vendor =  NULL;
-	GNCIdType type = GNC_VENDOR_MODULE_NAME;
-	vendor = (GncVendor*)search(book, id, vendor, type);
-	return vendor;
+    GncVendor *vendor =  NULL;
+    GNCIdType type = GNC_VENDOR_MODULE_NAME;
+    vendor = (GncVendor*)search(book, id, vendor, type);
+    return vendor;
 }
 
 
@@ -75,54 +75,57 @@
  ****************************************************************/
 static void * search(QofBook * book, const gchar *id, void * object, GNCIdType type)
 {
-	void *c;
-	GList *result;
-	QueryNew *q;
-	gint len;
-	QueryPredData_t string_pred_data;
-	g_return_val_if_fail (type, NULL);
-	g_return_val_if_fail (id, NULL);
-	g_return_val_if_fail (book, NULL);
+    void *c;
+    GList *result;
+    QueryNew *q;
+    gint len;
+    QueryPredData_t string_pred_data;
+    g_return_val_if_fail (type, NULL);
+    g_return_val_if_fail (id, NULL);
+    g_return_val_if_fail (book, NULL);
 
-	// Build the query
-	q = gncQueryCreateFor (type);
-	gncQuerySetBook (q, book);
-	// Search only the id field
-	string_pred_data = gncQueryStringPredicate (COMPARE_EQUAL, id, STRING_MATCH_NORMAL, FALSE);
+    // Build the query
+    q = gncQueryCreateFor (type);
+    gncQuerySetBook (q, book);
+    // Search only the id field
+    string_pred_data = gncQueryStringPredicate (COMPARE_EQUAL, id, STRING_MATCH_NORMAL, FALSE);
 
-	if (strcmp(type,GNC_CUSTOMER_MODULE_NAME))
-	{
-		GncCustomer *c = NULL;
-		gncQueryAddTerm (q, gncQueryBuildParamList("CUSTOMER_ID"), string_pred_data, QUERY_AND);
-	}
-	else if (strcmp(type,GNC_INVOICE_MODULE_NAME))
-	{
-		GncInvoice *c = NULL;
-		gncQueryAddTerm (q, gncQueryBuildParamList("INVOICE_ID"), string_pred_data, QUERY_AND);
-	}
-	else if (strcmp(type,GNC_VENDOR_MODULE_NAME))
-	{
-		GncVendor *c = NULL;
-		gncQueryAddTerm (q, gncQueryBuildParamList("VENDOR_ID"), string_pred_data, QUERY_AND);
-	}
+    if (strcmp(type, GNC_CUSTOMER_MODULE_NAME))
+    {
+        GncCustomer *c = NULL;
+        gncQueryAddTerm (q, gncQueryBuildParamList("CUSTOMER_ID"), string_pred_data, QUERY_AND);
+    }
+    else if (strcmp(type, GNC_INVOICE_MODULE_NAME))
+    {
+        GncInvoice *c = NULL;
+        gncQueryAddTerm (q, gncQueryBuildParamList("INVOICE_ID"), string_pred_data, QUERY_AND);
+    }
+    else if (strcmp(type, GNC_VENDOR_MODULE_NAME))
+    {
+        GncVendor *c = NULL;
+        gncQueryAddTerm (q, gncQueryBuildParamList("VENDOR_ID"), string_pred_data, QUERY_AND);
+    }
 
-	// Run the query
-	result = gncQueryRun (q);
+    // Run the query
+    result = gncQueryRun (q);
 
-	// now compare _exactly_
-	len = g_list_length (result);
-	if (result && (len>0)) {
-		result = g_list_first (result);
-		while (result) {
-			c = result->data;
-			if (strcmp(id,gncCustomerGetID(c)) == 0) {
-				// correct id found
-				object = c;
-				break;
-			}
-			result = g_list_next (result);
-		}
-	}
-	gncQueryDestroy (q);
-	return object;
+    // now compare _exactly_
+    len = g_list_length (result);
+    if (result && (len > 0))
+    {
+        result = g_list_first (result);
+        while (result)
+        {
+            c = result->data;
+            if (strcmp(id, gncCustomerGetID(c)) == 0)
+            {
+                // correct id found
+                object = c;
+                break;
+            }
+            result = g_list_next (result);
+        }
+    }
+    gncQueryDestroy (q);
+    return object;
 }

Modified: gnucash/trunk/src/gnome/dialog-print-check.c
===================================================================
--- gnucash/trunk/src/gnome/dialog-print-check.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/gnome/dialog-print-check.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -520,7 +520,7 @@
     /* If we're printing more than one check no addresses are allowed */
     if (g_list_length(pcd->splits) != 1)
         return FALSE;
-        
+
     /* if format is NULL, then the custom format is being used
      * which has an ADDRESS item by definition */
     format = pcd->selected_format;
@@ -2193,7 +2193,7 @@
  *  pattern (if requested), and calls a helper function to print all check items */
 static void
 draw_check_format(GncPrintContext * context, gint position,
-                 check_format_t * format, gpointer user_data)
+                  check_format_t * format, gpointer user_data)
 {
     PrintCheckDialog *pcd = (PrintCheckDialog *) user_data;
     cairo_t *cr;
@@ -2337,8 +2337,8 @@
     pango_font_description_free(desc);
 }
 
-/* Print a page of checks. This takes into account the number of checks to print, 
- * the number of checks on a page, and the starting check position on the page. 
+/* Print a page of checks. This takes into account the number of checks to print,
+ * the number of checks on a page, and the starting check position on the page.
  * This function is called once by the GtkPrint code once for each page to be printed. */
 static void
 draw_page(GtkPrintOperation * operation,
@@ -2357,7 +2357,7 @@
         gint    position = gtk_combo_box_get_active(GTK_COMBO_BOX(pcd->position_combobox));
         gint    checks_per_page;
         GList   *next_split;
-        
+
         position = gtk_combo_box_get_active(GTK_COMBO_BOX(pcd->position_combobox));
         if (position == pcd->position_max)
         {
@@ -2370,7 +2370,7 @@
             checks_per_page = pcd->position_max;
             first_page_count = gtk_spin_button_get_value_as_int(pcd->first_page_count);
         }
-            
+
         if (page_nr == 0)
         {
             first_check = 0;
@@ -2386,9 +2386,9 @@
             if (position < pcd->position_max)
                 position = 0;
         }
-        
-        for (check_number = first_check; check_number <= last_check; 
-             check_number++, position++)
+
+        for (check_number = first_check; check_number <= last_check;
+                check_number++, position++)
         {
             pcd->split = (Split *) next_split->data;
             next_split = g_list_next(next_split);
@@ -2417,11 +2417,11 @@
     gint first_page_count;
     gint pages;
     gint position = gtk_combo_box_get_active(GTK_COMBO_BOX(pcd->position_combobox));
-    
+
     if (pcd->selected_format && pcd->position_max > 1 && position < pcd->position_max)
     {
         first_page_count = gtk_spin_button_get_value_as_int(pcd->first_page_count);
-        pages = ((check_count - first_page_count) + pcd->position_max - 1) / 
+        pages = ((check_count - first_page_count) + pcd->position_max - 1) /
                 pcd->position_max + 1;
     }
     else
@@ -2517,7 +2517,7 @@
         pcd->position_max = 0;
     }
     gtk_combo_box_append_text(GTK_COMBO_BOX(pcd->position_combobox), _("Custom"));
-    
+
     /* If there's only one thing in the position combobox, make it insensitive */
     sensitive = (pcd->position_max > 0);
     gtk_widget_set_sensitive(GTK_WIDGET(pcd->position_combobox), sensitive);
@@ -2530,7 +2530,7 @@
                           gnc_print_check_set_sensitive,
                           GINT_TO_POINTER(sensitive));
 
-    /* Set the active entry in the position combo box, this will trigger a 
+    /* Set the active entry in the position combo box, this will trigger a
        call to gnc_print_check_position_changed */
     pnum = MAX(MIN(pnum, pcd->position_max), 0);
     gtk_combo_box_set_active(GTK_COMBO_BOX(pcd->position_combobox), pnum);
@@ -2552,23 +2552,23 @@
     gint pnum;
     guint check_count;
     gint first_page_max, first_page_min, first_page_value;
-    gdouble fpmin,fpmax;
-    
+    gdouble fpmin, fpmax;
+
     pnum = gtk_combo_box_get_active(GTK_COMBO_BOX(pcd->position_combobox));
-    
+
     /* Make the translation and rotation fields active if the position is "custom" */
     sensitive = pnum == pcd->position_max;
     gtk_widget_set_sensitive(GTK_WIDGET(pcd->translation_x), sensitive);
     gtk_widget_set_sensitive(GTK_WIDGET(pcd->translation_y), sensitive);
     gtk_widget_set_sensitive(GTK_WIDGET(pcd->check_rotation), sensitive);
     gtk_widget_set_sensitive(GTK_WIDGET(pcd->units_combobox), sensitive);
-    
+
     /* Set up the first page check count spin box */
     check_count = g_list_length(pcd->splits);
     first_page_max = MAX(1, MIN(pcd->position_max - pnum, check_count));
     first_page_min = 1;
     pnum = gtk_spin_button_get_value_as_int(pcd->first_page_count);
-    first_page_value = MAX(MIN(pnum, first_page_max), first_page_min);    
+    first_page_value = MAX(MIN(pnum, first_page_max), first_page_min);
     gtk_spin_button_set_range(pcd->first_page_count, (gdouble)first_page_min, (gdouble)first_page_max);
     gtk_spin_button_set_value(pcd->first_page_count, (gdouble)first_page_value);
     sensitive = first_page_max > 1;

Modified: gnucash/trunk/src/gnome/dialog-sx-editor.c
===================================================================
--- gnucash/trunk/src/gnome/dialog-sx-editor.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/gnome/dialog-sx-editor.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -218,8 +218,8 @@
             _( "This SX has changed; are you "
                "sure you want to cancel?" );
 #else
-        /* Translators: This message is currently not yet used; it
-         * will be used once the 2.4.0 string freeze is lifted. */
+            /* Translators: This message is currently not yet used; it
+             * will be used once the 2.4.0 string freeze is lifted. */
             _( "This Scheduled Transaction has changed; are you "
                "sure you want to cancel?" );
 #endif

Modified: gnucash/trunk/src/gnome/gnc-plugin-page-register.c
===================================================================
--- gnucash/trunk/src/gnome/gnc-plugin-page-register.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/gnome/gnc-plugin-page-register.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -2106,7 +2106,7 @@
     {
         split    = gnc_split_register_get_current_split(reg);
         trans    = xaccSplitGetParent(split);
-    
+
         if (split && trans)
         {
             splits = g_list_append(splits, split);
@@ -2162,7 +2162,7 @@
     }
     else
     {
-        gnc_error_dialog(gnc_plugin_page_get_window(GNC_PLUGIN_PAGE(plugin_page)), "%s", 
+        gnc_error_dialog(gnc_plugin_page_get_window(GNC_PLUGIN_PAGE(plugin_page)), "%s",
                          _("You can only print checks from a bank account register or search results."));
         LEAVE("Unsupported ledger type");
         return;

Modified: gnucash/trunk/src/gnome-search/dialog-search.c
===================================================================
--- gnucash/trunk/src/gnome-search/dialog-search.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/gnome-search/dialog-search.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -827,25 +827,44 @@
 static const gchar *
 type_label_to_new_button(const gchar* type_label)
 {
-    if (g_strcmp0(type_label, "Bill") == 0) {
+    if (g_strcmp0(type_label, "Bill") == 0)
+    {
         return _("New Bill");
-    } else if (g_strcmp0(type_label, "Customer") == 0) {
+    }
+    else if (g_strcmp0(type_label, "Customer") == 0)
+    {
         return _("New Customer");
-    } else if (g_strcmp0(type_label, "Employee") == 0) {
+    }
+    else if (g_strcmp0(type_label, "Employee") == 0)
+    {
         return _("New Employee");
-    } else if (g_strcmp0(type_label, "Expense Voucher") == 0) {
+    }
+    else if (g_strcmp0(type_label, "Expense Voucher") == 0)
+    {
         return _("New Expense Voucher");
-    } else if (g_strcmp0(type_label, "Invoice") == 0) {
+    }
+    else if (g_strcmp0(type_label, "Invoice") == 0)
+    {
         return _("New Invoice");
-    } else if (g_strcmp0(type_label, "Job") == 0) {
+    }
+    else if (g_strcmp0(type_label, "Job") == 0)
+    {
         return _("New Job");
-    } else if (g_strcmp0(type_label, "Order") == 0) {
+    }
+    else if (g_strcmp0(type_label, "Order") == 0)
+    {
         return _("New Order");
-    } else if (g_strcmp0(type_label, "Transaction") == 0) {
+    }
+    else if (g_strcmp0(type_label, "Transaction") == 0)
+    {
         return _("New Transaction");
-    } else if (g_strcmp0(type_label, "Vendor") == 0) {
+    }
+    else if (g_strcmp0(type_label, "Vendor") == 0)
+    {
         return _("New Vendor");
-    } else {
+    }
+    else
+    {
         PWARN("No translatable new-button label found for search type \"%s\", please add one into dialog-search.c!", type_label);
         return _("New item");
     }

Modified: gnucash/trunk/src/gnome-utils/dialog-account.c
===================================================================
--- gnucash/trunk/src/gnome-utils/dialog-account.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/gnome-utils/dialog-account.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -373,7 +373,7 @@
     string = g_strdup_printf("#%04X%04X%04X", color.red, color.green, color.blue);
 #endif
     if (safe_strcmp (string, DEFAULT_COLOR) == 0)
-	string = "Not Set";
+        string = "Not Set";
 
     old_string = xaccAccountGetColor (account);
     if (safe_strcmp (string, old_string) != 0)

Modified: gnucash/trunk/src/gnome-utils/gnc-file.c
===================================================================
--- gnucash/trunk/src/gnome-utils/gnc-file.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/gnome-utils/gnc-file.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -981,7 +981,7 @@
     /* Save As can't use the generic 'file' protocol. If the user didn't set
      * a specific protocol, assume the default 'xml'.
      */
-    if (g_strcmp0 (protocol,"file") == 0)
+    if (g_strcmp0 (protocol, "file") == 0)
     {
         g_free (protocol);
         protocol = g_strdup ("xml");
@@ -1193,7 +1193,7 @@
     /* Save As can't use the generic 'file' protocol. If the user didn't set
      * a specific protocol, assume the default 'xml'.
      */
-    if (g_strcmp0 (protocol,"file") == 0)
+    if (g_strcmp0 (protocol, "file") == 0)
     {
         g_free (protocol);
         protocol = g_strdup ("xml");

Modified: gnucash/trunk/src/gnome-utils/gnc-tree-view.c
===================================================================
--- gnucash/trunk/src/gnome-utils/gnc-tree-view.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/gnome-utils/gnc-tree-view.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -1819,7 +1819,7 @@
     visible = gnc_tree_view_column_visible(view, NULL, pref_name);
 
     /* Get width */
-    if(default_width == 0)
+    if (default_width == 0)
     {
         sizing = GTK_TREE_VIEW_COLUMN_AUTOSIZE;
     }

Modified: gnucash/trunk/src/import-export/aqbanking/gnc-ab-utils.c
===================================================================
--- gnucash/trunk/src/import-export/aqbanking/gnc-ab-utils.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/import-export/aqbanking/gnc-ab-utils.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -146,20 +146,20 @@
 # ifndef AQBANKING_VERSION_5_PLUS
                                 , 0
 # endif
-                ) != 0)
+                               ) != 0)
         {
             if (AB_Banking_HasConf3(api
 # ifndef AQBANKING_VERSION_5_PLUS
                                     , 0
 # endif
-                    ) == 0)
+                                   ) == 0)
             {
                 g_message("gnc_AB_BANKING_new: importing aqbanking3 configuration\n");
                 if (AB_Banking_ImportConf3(api
 # ifndef AQBANKING_VERSION_5_PLUS
                                            , 0
 # endif
-                        ) < 0)
+                                          ) < 0)
                 {
                     g_message("gnc_AB_BANKING_new: unable to import aqbanking3 configuration\n");
                 }
@@ -168,21 +168,21 @@
 # ifndef AQBANKING_VERSION_5_PLUS
                                          , 0
 # endif
-                         ) == 0)
+                                        ) == 0)
             {
                 g_message("gnc_AB_BANKING_new: importing aqbanking2 configuration\n");
                 if (AB_Banking_ImportConf2(api
 # ifndef AQBANKING_VERSION_5_PLUS
                                            , 0
 # endif
-                        ) < 0)
+                                          ) < 0)
                 {
                     g_message("gnc_AB_BANKING_new: unable to import aqbanking2 configuration\n");
                 }
             }
-        } 
-#endif /* AQBANKING_VERSION_4_PLUS */        
-        
+        }
+#endif /* AQBANKING_VERSION_4_PLUS */
+
         /* Init the API */
         g_return_val_if_fail(AB_Banking_Init(api) == 0, NULL);
 

Modified: gnucash/trunk/src/import-export/aqbanking/gnc-gwen-gui.c
===================================================================
--- gnucash/trunk/src/import-export/aqbanking/gnc-gwen-gui.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/import-export/aqbanking/gnc-gwen-gui.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -174,18 +174,18 @@
                             GWEN_LOGGER_LEVEL level, const gchar *text);
 static gint progress_end_cb(GWEN_GUI *gwen_gui, guint32 id);
 static gint GNC_GWENHYWFAR_CB getpassword_cb(GWEN_GUI *gwen_gui, guint32 flags, const gchar *token,
-                           const gchar *title, const gchar *text, gchar *buffer,
-                           gint min_len, gint max_len, guint32 guiid);
+        const gchar *title, const gchar *text, gchar *buffer,
+        gint min_len, gint max_len, guint32 guiid);
 static gint GNC_GWENHYWFAR_CB setpasswordstatus_cb(GWEN_GUI *gwen_gui, const gchar *token,
-                                 const gchar *pin,
-                                 GWEN_GUI_PASSWORD_STATUS status, guint32 guiid);
+        const gchar *pin,
+        GWEN_GUI_PASSWORD_STATUS status, guint32 guiid);
 static gint GNC_GWENHYWFAR_CB loghook_cb(GWEN_GUI *gwen_gui, const gchar *log_domain,
-                       GWEN_LOGGER_LEVEL priority, const gchar *text);
+        GWEN_LOGGER_LEVEL priority, const gchar *text);
 #ifdef AQBANKING_VERSION_5_PLUS
 typedef GWEN_SYNCIO GWEN_IO_LAYER;
 #endif
 static gint GNC_GWENHYWFAR_CB checkcert_cb(GWEN_GUI *gwen_gui, const GWEN_SSLCERTDESCR *cert,
-                         GWEN_IO_LAYER *io, guint32 guiid);
+        GWEN_IO_LAYER *io, guint32 guiid);
 
 gboolean ggg_delete_event_cb(GtkWidget *widget, GdkEvent *event,
                              gpointer user_data);

Modified: gnucash/trunk/src/libqof/qof/gnc-date.c
===================================================================
--- gnucash/trunk/src/libqof/qof/gnc-date.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/libqof/qof/gnc-date.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -72,11 +72,11 @@
 
 const char *gnc_default_strftime_date_format =
 #ifdef G_OS_WIN32
-/* The default date format for use with strftime in Win32. */
+    /* The default date format for use with strftime in Win32. */
     N_("%B %#d, %Y")
 #else
-/* The default date format for use with strftime in other OS. */
-/* Translators: call "man strftime" for possible values. */
+    /* The default date format for use with strftime in other OS. */
+    /* Translators: call "man strftime" for possible values. */
     N_("%B %e, %Y")
 #endif
     ;

Modified: gnucash/trunk/src/register/register-gnome/gnucash-header.c
===================================================================
--- gnucash/trunk/src/register/register-gnome/gnucash-header.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/register/register-gnome/gnucash-header.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -563,14 +563,14 @@
                           &x, &y);
 
         on_line = pointer_on_resize_line (header, x, y, &ptr_col);
-       
+
         /* If we're on a resize line and the column to the right is zero
            width, resize that one. */
         if (on_line)
             resize_col = find_resize_col (header, ptr_col);
         else
             resize_col = ptr_col;
-       
+
         if (resize_col > -1)
         {
             header->in_resize = FALSE;

Modified: gnucash/trunk/src/report/report-gnome/gnc-plugin-page-report.c
===================================================================
--- gnucash/trunk/src/report/report-gnome/gnc-plugin-page-report.c	2010-10-03 12:23:19 UTC (rev 19626)
+++ gnucash/trunk/src/report/report-gnome/gnc-plugin-page-report.c	2010-10-03 12:27:44 UTC (rev 19627)
@@ -1407,8 +1407,8 @@
     filepath = gnc_file_dialog (title, NULL, default_dir, GNC_FILE_DIALOG_EXPORT);
 
     /* Try to test for extension on file name, add if missing */
-    if (g_strrstr(filepath,".") == NULL)
-	filepath = g_strconcat(filepath,".",g_ascii_strdown(type,strlen(type)),NULL);
+    if (g_strrstr(filepath, ".") == NULL)
+        filepath = g_strconcat(filepath, ".", g_ascii_strdown(type, strlen(type)), NULL);
 
     g_free (title);
     g_free (default_dir);



More information about the gnucash-changes mailing list