r23245 - gnucash/trunk/src - Gnc-Prefs: migrate date_format preference

Geert Janssens gjanssens at code.gnucash.org
Mon Oct 7 10:15:56 EDT 2013


Author: gjanssens
Date: 2013-10-07 10:15:55 -0400 (Mon, 07 Oct 2013)
New Revision: 23245
Trac: http://svn.gnucash.org/trac/changeset/23245

Modified:
   gnucash/trunk/src/gnome-utils/dialog-preferences.c
   gnucash/trunk/src/gnome-utils/gnc-gnome-utils.c
   gnucash/trunk/src/gnome-utils/gnc-period-select.c
   gnucash/trunk/src/gnome-utils/gtkbuilder/dialog-preferences.glade
   gnucash/trunk/src/gnome/gschemas/org.gnucash.gschema.xml.in
   gnucash/trunk/src/libqof/qof/gnc-date.h
Log:
Gnc-Prefs: migrate date_format preference

This includes converting the radio button group in preferences
into a combobox

Modified: gnucash/trunk/src/gnome/gschemas/org.gnucash.gschema.xml.in
===================================================================
--- gnucash/trunk/src/gnome/gschemas/org.gnucash.gschema.xml.in	2013-10-07 14:15:43 UTC (rev 23244)
+++ gnucash/trunk/src/gnome/gschemas/org.gnucash.gschema.xml.in	2013-10-07 14:15:55 UTC (rev 23245)
@@ -104,8 +104,8 @@
       <summary>Use 24 hour time format</summary>
       <description>If active, use a 24 hour time format. Otherwise use a 12 hour time format.</description>
     </key>
-    <key name="date_format" type="s">
-      <default>'locale'</default>
+    <key name="date_format" type="i">
+      <default>4</default>
       <summary>Date format choice</summary>
       <description>This setting chooses the way dates are displayed in GnuCash. Possible values for this setting are "locale" to use the system locale setting, "ce" for Continental Europe style dates, "iso" for ISO 8601 standard dates , "uk" for United Kingdom style dates, and "us" for United States style dates.</description>
     </key>

Modified: gnucash/trunk/src/gnome-utils/dialog-preferences.c
===================================================================
--- gnucash/trunk/src/gnome-utils/dialog-preferences.c	2013-10-07 14:15:43 UTC (rev 23244)
+++ gnucash/trunk/src/gnome-utils/dialog-preferences.c	2013-10-07 14:15:55 UTC (rev 23245)
@@ -1391,6 +1391,9 @@
     GHashTable *prefs_table;
     GDate* gdate;
     gchar buf[128];
+    GtkListStore *store;
+    GtkTreePath *path;
+    GtkTreeIter iter;
     gnc_commodity *locale_currency;
     const gchar *currency_name;
 
@@ -1406,6 +1409,7 @@
     gnc_builder_add_from_file (builder, "dialog-preferences.glade", "new_search_limit_adj");
     gnc_builder_add_from_file (builder, "dialog-preferences.glade", "retain_days_adj");
     gnc_builder_add_from_file (builder, "dialog-preferences.glade", "tab_width_adj");
+    gnc_builder_add_from_file (builder, "dialog-preferences.glade", "date_formats");
     gnc_builder_add_from_file (builder, "dialog-preferences.glade", "GnuCash Preferences");
     dialog = GTK_WIDGET(gtk_builder_get_object (builder, "GnuCash Preferences"));
 
@@ -1477,10 +1481,12 @@
     DEBUG("Done with interesting widgets.");
 
     /* Other stuff */
-    gdate = g_date_new_dmy(31, G_DATE_JULY, 2005);
+    gdate = g_date_new_dmy(31, G_DATE_JULY, 2013);
     g_date_strftime(buf, sizeof(buf), "%x", gdate);
-    label = GTK_WIDGET(gtk_builder_get_object (builder, "locale_date_sample"));
-    gtk_label_set_text(GTK_LABEL(label), buf);
+    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);
 
     locale_currency = gnc_locale_default_currency ();

Modified: gnucash/trunk/src/gnome-utils/gnc-gnome-utils.c
===================================================================
--- gnucash/trunk/src/gnome-utils/gnc-gnome-utils.c	2013-10-07 14:15:43 UTC (rev 23244)
+++ gnucash/trunk/src/gnome-utils/gnc-gnome-utils.c	2013-10-07 14:15:55 UTC (rev 23245)
@@ -127,31 +127,20 @@
 static void
 gnc_configure_date_format (void)
 {
-    char *format_code = gnc_gconf_get_string(GCONF_GENERAL,
-                        KEY_DATE_FORMAT, NULL);
+    QofDateFormat df = gnc_prefs_get_int(GCONF_GENERAL,
+                                         GNC_PREF_DATE_FORMAT);
 
-    QofDateFormat df;
-
-    if (format_code == NULL)
-        format_code = g_strdup("locale");
-    if (*format_code == '\0')
+    /* Only a subset of the qof date formats is currently
+     * supported for date entry.
+     */
+    if ((df > QOF_DATE_FORMAT_LOCALE)
+            || (df > QOF_DATE_FORMAT_LOCALE))
     {
-        g_free(format_code);
-        format_code = g_strdup("locale");
-    }
-
-    if (gnc_date_string_to_dateformat(format_code, &df))
-    {
-        PERR("Incorrect date format code");
-        if (format_code != NULL)
-            free(format_code);
+        PERR("Incorrect date format");
         return;
     }
 
     qof_date_format_set(df);
-
-    if (format_code != NULL)
-        free(format_code);
 }
 
 /* gnc_configure_date_completion
@@ -643,9 +632,11 @@
     gnc_configure_date_format();
     gnc_configure_date_completion();
 
+    gnc_prefs_register_cb (GNC_PREFS_GROUP_GENERAL,
+                           GNC_PREF_DATE_FORMAT,
+                           gnc_configure_date_format,
+                           NULL);
     gnc_gconf_general_register_cb(
-        KEY_DATE_FORMAT, (GncGconfGeneralCb)gnc_configure_date_format, NULL);
-    gnc_gconf_general_register_cb(
         KEY_DATE_COMPLETION, (GncGconfGeneralCb)gnc_configure_date_completion, NULL);
     gnc_prefs_register_cb (GNC_PREFS_GROUP_GENERAL,
                            GNC_PREF_DATE_BACKMONTHS,

Modified: gnucash/trunk/src/gnome-utils/gnc-period-select.c
===================================================================
--- gnucash/trunk/src/gnome-utils/gnc-period-select.c	2013-10-07 14:15:43 UTC (rev 23244)
+++ gnucash/trunk/src/gnome-utils/gnc-period-select.c	2013-10-07 14:15:55 UTC (rev 23245)
@@ -35,8 +35,8 @@
 #include <glib/gi18n.h>
 
 #include "gnc-date.h"
-#include "gnc-gconf-utils.h"
 #include "gnc-period-select.h"
+#include "gnc-prefs.h"
 #include <gnc-gdate-utils.h>
 
 enum
@@ -150,7 +150,7 @@
         return;
     which = gtk_combo_box_get_active (GTK_COMBO_BOX (priv->selector));
     if (which == -1)
-        date = g_date_new_dmy (1, 1, 1970);
+        date = g_date_new_dmy (31, 7, 2013);
 
     else if (priv->start)
         date = gnc_accounting_period_start_gdate (which, priv->fy_end,
@@ -186,17 +186,19 @@
 
 
 /** Handle an application wide change in the date format.  This
- *  function will be called when the GConf key for the date format is
+ *  function will be called when the preference for the date format is
  *  updated.  It doesn't really care what the new format is, because
  *  the date string is generated elsewhere.  It just needs to know to
  *  update the date label so that it matches the newly selected format.
  *
- *  @param unused The new value for the Gnucash date format.
+ *  @param prefs Unused.
  *
+ *  @param pref Unused.
+ *
  *  @param period The GncPeriodSelect that needs to be updated.
  */
 static void
-gnc_period_sample_new_date_format (GConfEntry *unused,
+gnc_period_sample_new_date_format (gpointer prefs, gchar *pref,
                                    GncPeriodSelect *period)
 {
     gnc_period_sample_update_date_label(period);
@@ -639,8 +641,8 @@
     priv = GNC_PERIOD_SELECT_GET_PRIVATE(period);
 
     /* Stop tracking changes to date formatting */
-    gnc_gconf_general_remove_cb(KEY_DATE_FORMAT,
-                                (GncGconfGeneralCb)gnc_period_sample_new_date_format, period);
+    gnc_prefs_remove_cb_by_func (GNC_PREFS_GROUP_GENERAL, GNC_PREF_DATE_FORMAT,
+                                 gnc_period_sample_new_date_format, period);
 
     /* The selector and date_label were added to the hbox.  They will be
      * freed automatically. */
@@ -697,8 +699,8 @@
     }
 
     /* Track changes to date formatting */
-    gnc_gconf_general_register_cb(KEY_DATE_FORMAT,
-                                  (GncGconfGeneralCb)gnc_period_sample_new_date_format, period);
+    gnc_prefs_register_cb (GNC_PREFS_GROUP_GENERAL, GNC_PREF_DATE_FORMAT,
+                           gnc_period_sample_new_date_format, period);
 
     return GTK_WIDGET (period);
 }

Modified: gnucash/trunk/src/gnome-utils/gtkbuilder/dialog-preferences.glade
===================================================================
--- gnucash/trunk/src/gnome-utils/gtkbuilder/dialog-preferences.glade	2013-10-07 14:15:43 UTC (rev 23244)
+++ gnucash/trunk/src/gnome-utils/gtkbuilder/dialog-preferences.glade	2013-10-07 14:15:55 UTC (rev 23245)
@@ -21,6 +21,36 @@
     <property name="step_increment">1</property>
     <property name="page_increment">4</property>
   </object>
+  <object class="GtkListStore" id="date_formats">
+    <columns>
+      <!-- column-name name -->
+      <column type="gchararray"/>
+      <!-- column-name example -->
+      <column type="gchararray"/>
+    </columns>
+    <data>
+      <row>
+        <col id="0" translatable="yes">US</col>
+        <col id="1" translatable="yes">07/31/2013</col>
+      </row>
+      <row>
+        <col id="0" translatable="yes">UK</col>
+        <col id="1" translatable="yes">31/07/2013</col>
+      </row>
+      <row>
+        <col id="0" translatable="yes">Europe</col>
+        <col id="1" translatable="yes">31.07.2013</col>
+      </row>
+      <row>
+        <col id="0" translatable="yes">ISO</col>
+        <col id="1" translatable="yes">2013-07-31</col>
+      </row>
+      <row>
+        <col id="0" translatable="yes">Locale</col>
+        <col id="1" translatable="yes">(dummy)</col>
+      </row>
+    </data>
+  </object>
   <object class="GtkDialog" id="GnuCash Preferences">
     <property name="can_focus">False</property>
     <property name="title" translatable="yes">GnuCash Preferences</property>
@@ -942,7 +972,7 @@
                 <property name="visible">True</property>
                 <property name="can_focus">False</property>
                 <property name="border_width">6</property>
-                <property name="n_rows">17</property>
+                <property name="n_rows">14</property>
                 <property name="n_columns">4</property>
                 <child>
                   <placeholder/>
@@ -1026,15 +1056,6 @@
                   <placeholder/>
                 </child>
                 <child>
-                  <placeholder/>
-                </child>
-                <child>
-                  <placeholder/>
-                </child>
-                <child>
-                  <placeholder/>
-                </child>
-                <child>
                   <object class="GtkLabel" id="label104">
                     <property name="can_focus">False</property>
                     <property name="xalign">0</property>
@@ -1043,67 +1064,6 @@
                   </object>
                   <packing>
                     <property name="right_attach">4</property>
-                    <property name="top_attach">10</property>
-                    <property name="bottom_attach">11</property>
-                    <property name="x_options">GTK_FILL</property>
-                    <property name="y_options"/>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkLabel" id="label103">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="xalign">0</property>
-                  </object>
-                  <packing>
-                    <property name="top_attach">9</property>
-                    <property name="bottom_attach">10</property>
-                    <property name="x_options">GTK_FILL</property>
-                    <property name="y_options"/>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkLabel" id="label102">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="xalign">0</property>
-                    <property name="label" translatable="yes">2005-07-31</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">1</property>
-                    <property name="right_attach">2</property>
-                    <property name="top_attach">8</property>
-                    <property name="bottom_attach">9</property>
-                    <property name="x_options">GTK_FILL</property>
-                    <property name="y_options"/>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkLabel" id="label101">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="xalign">0</property>
-                    <property name="label" translatable="yes">31.07.2005</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">1</property>
-                    <property name="right_attach">2</property>
-                    <property name="top_attach">7</property>
-                    <property name="bottom_attach">8</property>
-                    <property name="x_options">GTK_FILL</property>
-                    <property name="y_options"/>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkLabel" id="label100">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="xalign">0</property>
-                    <property name="label" translatable="yes">31/07/2005</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">1</property>
-                    <property name="right_attach">2</property>
                     <property name="top_attach">6</property>
                     <property name="bottom_attach">7</property>
                     <property name="x_options">GTK_FILL</property>
@@ -1111,15 +1071,12 @@
                   </packing>
                 </child>
                 <child>
-                  <object class="GtkLabel" id="label99">
+                  <object class="GtkLabel" id="label103">
                     <property name="visible">True</property>
                     <property name="can_focus">False</property>
                     <property name="xalign">0</property>
-                    <property name="label" translatable="yes">07/31/2005</property>
                   </object>
                   <packing>
-                    <property name="left_attach">1</property>
-                    <property name="right_attach">2</property>
                     <property name="top_attach">5</property>
                     <property name="bottom_attach">6</property>
                     <property name="x_options">GTK_FILL</property>
@@ -1127,126 +1084,6 @@
                   </packing>
                 </child>
                 <child>
-                  <object class="GtkLabel" id="locale_date_sample">
-                    <property name="visible">True</property>
-                    <property name="can_focus">False</property>
-                    <property name="xalign">0</property>
-                  </object>
-                  <packing>
-                    <property name="left_attach">1</property>
-                    <property name="right_attach">2</property>
-                    <property name="top_attach">4</property>
-                    <property name="bottom_attach">5</property>
-                    <property name="x_options">GTK_FILL</property>
-                    <property name="y_options"/>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkRadioButton" id="gconf/general/date_format/iso">
-                    <property name="label" translatable="yes">_ISO:</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="has_tooltip">True</property>
-                    <property name="tooltip_markup">Use the date format specified by the ISO-8601 standard.</property>
-                    <property name="tooltip_text" translatable="yes">Use the date format specified by the ISO-8601 standard.</property>
-                    <property name="use_underline">True</property>
-                    <property name="active">True</property>
-                    <property name="draw_indicator">True</property>
-                  </object>
-                  <packing>
-                    <property name="top_attach">8</property>
-                    <property name="bottom_attach">9</property>
-                    <property name="x_options">GTK_FILL</property>
-                    <property name="y_options"/>
-                    <property name="x_padding">12</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkRadioButton" id="gconf/general/date_format/ce">
-                    <property name="label" translatable="yes">_Europe:</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="has_tooltip">True</property>
-                    <property name="tooltip_markup">Use the date format common in continental Europe.</property>
-                    <property name="tooltip_text" translatable="yes">Use the date format common in continental Europe.</property>
-                    <property name="use_underline">True</property>
-                    <property name="draw_indicator">True</property>
-                    <property name="group">gconf/general/date_format/iso</property>
-                  </object>
-                  <packing>
-                    <property name="top_attach">7</property>
-                    <property name="bottom_attach">8</property>
-                    <property name="x_options">GTK_FILL</property>
-                    <property name="y_options"/>
-                    <property name="x_padding">12</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkRadioButton" id="gconf/general/date_format/uk">
-                    <property name="label" translatable="yes">U_K:</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="has_tooltip">True</property>
-                    <property name="tooltip_markup">Use the date format common in the United Kingdom.</property>
-                    <property name="tooltip_text" translatable="yes">Use the date format common in the United Kingdom.</property>
-                    <property name="use_underline">True</property>
-                    <property name="draw_indicator">True</property>
-                    <property name="group">gconf/general/date_format/iso</property>
-                  </object>
-                  <packing>
-                    <property name="top_attach">6</property>
-                    <property name="bottom_attach">7</property>
-                    <property name="x_options">GTK_FILL</property>
-                    <property name="y_options"/>
-                    <property name="x_padding">12</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkRadioButton" id="gconf/general/date_format/us">
-                    <property name="label" translatable="yes">_US:</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="has_tooltip">True</property>
-                    <property name="tooltip_markup">Use the date format common in the United States.</property>
-                    <property name="tooltip_text" translatable="yes">Use the date format common in the United States.</property>
-                    <property name="use_underline">True</property>
-                    <property name="draw_indicator">True</property>
-                    <property name="group">gconf/general/date_format/iso</property>
-                  </object>
-                  <packing>
-                    <property name="top_attach">5</property>
-                    <property name="bottom_attach">6</property>
-                    <property name="x_options">GTK_FILL</property>
-                    <property name="y_options"/>
-                    <property name="x_padding">12</property>
-                  </packing>
-                </child>
-                <child>
-                  <object class="GtkRadioButton" id="gconf/general/date_format/locale">
-                    <property name="label" translatable="yes">Loc_ale:</property>
-                    <property name="visible">True</property>
-                    <property name="can_focus">True</property>
-                    <property name="receives_default">False</property>
-                    <property name="has_tooltip">True</property>
-                    <property name="tooltip_markup">Use the date format specified by the system locale.</property>
-                    <property name="tooltip_text" translatable="yes">Use the date format specified by the system locale.</property>
-                    <property name="use_underline">True</property>
-                    <property name="draw_indicator">True</property>
-                    <property name="group">gconf/general/date_format/iso</property>
-                  </object>
-                  <packing>
-                    <property name="top_attach">4</property>
-                    <property name="bottom_attach">5</property>
-                    <property name="x_options">GTK_FILL</property>
-                    <property name="y_options"/>
-                    <property name="x_padding">12</property>
-                  </packing>
-                </child>
-                <child>
                   <object class="GtkLabel" id="label97">
                     <property name="visible">True</property>
                     <property name="can_focus">False</property>
@@ -1318,8 +1155,8 @@
                     <property name="use_markup">True</property>
                   </object>
                   <packing>
-                    <property name="top_attach">12</property>
-                    <property name="bottom_attach">13</property>
+                    <property name="top_attach">8</property>
+                    <property name="bottom_attach">9</property>
                     <property name="x_options">GTK_FILL</property>
                     <property name="y_options"/>
                   </packing>
@@ -1334,8 +1171,8 @@
                   </object>
                   <packing>
                     <property name="right_attach">4</property>
-                    <property name="top_attach">13</property>
-                    <property name="bottom_attach">14</property>
+                    <property name="top_attach">9</property>
+                    <property name="bottom_attach">10</property>
                     <property name="x_options">GTK_FILL</property>
                     <property name="y_options"/>
                   </packing>
@@ -1358,8 +1195,8 @@
                   </object>
                   <packing>
                     <property name="right_attach">2</property>
-                    <property name="top_attach">14</property>
-                    <property name="bottom_attach">15</property>
+                    <property name="top_attach">10</property>
+                    <property name="bottom_attach">11</property>
                     <property name="x_options">GTK_FILL</property>
                     <property name="y_options"/>
                     <property name="x_padding">12</property>
@@ -1381,8 +1218,8 @@
                   </object>
                   <packing>
                     <property name="right_attach">2</property>
-                    <property name="top_attach">15</property>
-                    <property name="bottom_attach">16</property>
+                    <property name="top_attach">11</property>
+                    <property name="bottom_attach">12</property>
                     <property name="x_options">GTK_FILL</property>
                     <property name="y_options"/>
                     <property name="x_padding">12</property>
@@ -1408,12 +1245,40 @@
                     <property name="climb_rate">1</property>
                   </object>
                   <packing>
-                    <property name="top_attach">16</property>
-                    <property name="bottom_attach">17</property>
+                    <property name="top_attach">12</property>
+                    <property name="bottom_attach">13</property>
                     <property name="x_options"/>
                     <property name="y_options"/>
                   </packing>
                 </child>
+                <child>
+                  <object class="GtkComboBox" id="pref/general/date_format">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="has_tooltip">True</property>
+                    <property name="tooltip_markup">Use the date format specified by the system locale.</property>
+                    <property name="tooltip_text" translatable="yes">Use the date format specified by the system locale.</property>
+                    <property name="model">date_formats</property>
+                    <property name="active">3</property>
+                    <child>
+                      <object class="GtkCellRendererText" id="format_renderer"/>
+                      <attributes>
+                        <attribute name="text">0</attribute>
+                      </attributes>
+                    </child>
+                    <child>
+                      <object class="GtkCellRendererText" id="example_renderer"/>
+                      <attributes>
+                        <attribute name="text">1</attribute>
+                      </attributes>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="top_attach">4</property>
+                    <property name="bottom_attach">5</property>
+                    <property name="y_options">GTK_FILL</property>
+                  </packing>
+                </child>
               </object>
               <packing>
                 <property name="position">2</property>
@@ -2097,7 +1962,7 @@
                 <property name="visible">True</property>
                 <property name="can_focus">False</property>
                 <property name="border_width">6</property>
-                <property name="n_rows">10</property>
+                <property name="n_rows">5</property>
                 <property name="n_columns">4</property>
                 <property name="column_spacing">12</property>
                 <child>
@@ -2236,27 +2101,6 @@
                   <placeholder/>
                 </child>
                 <child>
-                  <placeholder/>
-                </child>
-                <child>
-                  <placeholder/>
-                </child>
-                <child>
-                  <placeholder/>
-                </child>
-                <child>
-                  <placeholder/>
-                </child>
-                <child>
-                  <placeholder/>
-                </child>
-                <child>
-                  <placeholder/>
-                </child>
-                <child>
-                  <placeholder/>
-                </child>
-                <child>
                   <object class="GtkLabel" id="label115">
                     <property name="visible">True</property>
                     <property name="can_focus">False</property>
@@ -2265,7 +2109,6 @@
                     <property name="use_markup">True</property>
                   </object>
                   <packing>
-                    <property name="right_attach">4</property>
                     <property name="x_options">GTK_FILL</property>
                     <property name="y_options"/>
                   </packing>
@@ -2365,6 +2208,36 @@
                     <property name="y_options">GTK_FILL</property>
                   </packing>
                 </child>
+                <child>
+                  <placeholder/>
+                </child>
+                <child>
+                  <placeholder/>
+                </child>
+                <child>
+                  <placeholder/>
+                </child>
+                <child>
+                  <placeholder/>
+                </child>
+                <child>
+                  <placeholder/>
+                </child>
+                <child>
+                  <placeholder/>
+                </child>
+                <child>
+                  <placeholder/>
+                </child>
+                <child>
+                  <placeholder/>
+                </child>
+                <child>
+                  <placeholder/>
+                </child>
+                <child>
+                  <placeholder/>
+                </child>
               </object>
               <packing>
                 <property name="position">4</property>

Modified: gnucash/trunk/src/libqof/qof/gnc-date.h
===================================================================
--- gnucash/trunk/src/libqof/qof/gnc-date.h	2013-10-07 14:15:43 UTC (rev 23244)
+++ gnucash/trunk/src/libqof/qof/gnc-date.h	2013-10-07 14:15:55 UTC (rev 23245)
@@ -120,13 +120,13 @@
     QOF_DATE_FORMAT_UK,       /**< Britain: dd/mm/yyyy */
     QOF_DATE_FORMAT_CE,       /**< Continental Europe: dd.mm.yyyy */
     QOF_DATE_FORMAT_ISO,      /**< ISO: yyyy-mm-dd */
+    QOF_DATE_FORMAT_LOCALE,   /**< Take from locale information */
     QOF_DATE_FORMAT_UTC,      /**< UTC: 2004-12-12T23:39:11Z */
-    QOF_DATE_FORMAT_LOCALE,   /**< Take from locale information */
     QOF_DATE_FORMAT_CUSTOM    /**< Used by the check printing code */
 } QofDateFormat;
 
 #define DATE_FORMAT_FIRST QOF_DATE_FORMAT_US
-#define DATE_FORMAT_LAST  QOF_DATE_FORMAT_LOCALE
+#define DATE_FORMAT_LAST  QOF_DATE_FORMAT_UTC
 
 /** Enum for date completion modes (for dates entered without year) */
 typedef enum



More information about the gnucash-changes mailing list