From 2b8ef2b7d6206515bd4679beee6bfdb8697acd54 Mon Sep 17 00:00:00 2001 From: Joshua Sled Date: Thu, 5 Apr 2007 01:33:13 +0000 Subject: [PATCH] Base the value of the "week_starts_monday" dense-cal parameter on an implementation detail of GTK. :( git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@15814 57a11ea4-9604-0410-9ed3-97b8803252fd --- src/gnome-utils/gnc-dense-cal.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/gnome-utils/gnc-dense-cal.c b/src/gnome-utils/gnc-dense-cal.c index 6c8ccaaf21..1d3ab4e971 100644 --- a/src/gnome-utils/gnc-dense-cal.c +++ b/src/gnome-utils/gnc-dense-cal.c @@ -430,7 +430,21 @@ gnc_dense_cal_init(GncDenseCal *dcal) dcal->initialized = TRUE; - dcal->week_starts_monday = 1; + + dcal->week_starts_monday = 0; + { + gchar **parts; + parts = g_strsplit(dgettext("gtk20", "calendar:week_start:0"), + ":", 3); + if (parts[0] != NULL + && parts[1] != NULL + && parts[2] != NULL) + { + if (strcmp("1", parts[2]) == 0) + dcal->week_starts_monday = 1; + } + g_strfreev(parts); + } gtk_widget_pop_composite_child();