Bug 80940 - Gnome-panel shows incorrectly formated calender
Summary: Gnome-panel shows incorrectly formated calender
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: gtk2
Version: 1
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Owen Taylor
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: 79579 CambridgeTarget
TreeView+ depends on / blocked
 
Reported: 2003-01-02 17:10 UTC by Petri T. Koistinen
Modified: 2007-11-30 22:10 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2004-04-05 14:57:46 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Picture of badly formated calender (21.68 KB, image/png)
2003-01-28 16:05 UTC, Petri T. Koistinen
no flags Details
a patch, at least for the Finnish translation (414 bytes, patch)
2003-12-15 05:33 UTC, Seth Spitzer
no flags Details | Diff

Description Petri T. Koistinen 2003-01-02 17:10:32 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0.1) Gecko/20021003

Description of problem:
In Finnish calender monday is first day of week, not the sunday like in US calender.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. Run cal with Finnish language enviroment.

    

Actual Results:  $ cal
    tammikuu 2003
su ma ti ke to pe la 
          1  2  3  4
 5  6  7  8  9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31


Expected Results:  $ cal
    tammikuu 2003
ma ti ke to pe la su
       1  2  3  4  5
 6  7  8  9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30 31


Additional info:

Typing cal -m helps, but calender output format should depend on enviroment
variable.

Same applies by the way to the calender available GNOME panel when clicking clock.

Comment 1 Elliot Lee 2003-01-13 18:51:30 UTC
Due to the complexities of locale settings, it was decided when this issue came up before 
that people who want Monday-first behaviour would always have to pass the -m option.

Comment 2 Petri T. Koistinen 2003-01-28 16:02:53 UTC
Same applies by the way to the calender available onGNOME panel when clicking
the clock.

This should be fixed. The calender has finnish month names and weekday
abreviations and Finland monday is realy first day of week.


Comment 3 Petri T. Koistinen 2003-01-28 16:05:02 UTC
Created attachment 89648 [details]
Picture of badly formated calender

Monday should be first day of week which Finnish locale.

Comment 4 Seth Spitzer 2003-12-15 05:17:06 UTC
I don't think this is a gnome-panel bug.

I was going to suggest that the fix would involve fixing
create_calendar() in
gnome-panel/applets/clock/clock.c and use the
GTK_CALENDAR_WEEK_START_MONDAY
option.  

But, looking at http://bugzilla.gnome.org/show_bug.cgi?id=87977, that 
wouldn't work as that option is now ignored.

I think the right fix is to fix the translation file.

Specifically, line #1272 of fi.po

http://cvs.gnome.org/lxr/source/gtk+/po/fi.po#1271

1265 #. Translate to calendar:week_start:1 if you want Monday to be the
1266 #. * first day of the week; otherwise translate to
calendar:week_start:0.
1267 #. * Do *not* translate it to anything else, if it isn't
calendar:week_start:1
1268 #. * or calendar:week_start:0 it will not work.
1269 #.
1270 #: gtk/gtkcalendar.c:720
1271 msgid "calendar:week_start:0"
1272 msgstr ""

I think we just have to change line 1272 to:

msgstr "calendar:week_start:1"

Note, from http://bugzilla.gnome.org/show_bug.cgi?id=87977 there are
other translations that might need fixing.

Comment 5 Seth Spitzer 2003-12-15 05:33:36 UTC
Created attachment 96534 [details]
a patch, at least for the Finnish translation

Comment 6 Bart Martens 2004-02-06 11:22:36 UTC
Monday is the first day of the week also in Belgium. Most Belgians
speak Dutch, many speak French, and some speak German.

The po-files are per language, not per language-country. I don't think
this is a problem for Belgium, because I assume that in the
Netherlands and in France monday is also the first day of the week.

Are already good:
http://cvs.gnome.org/lxr/source/gtk+/po/nl.po#1263
http://cvs.gnome.org/lxr/source/gtk+/po/de.po#1287

Needs a fix:
http://cvs.gnome.org/lxr/source/gtk+/po/fr.po#1289


Comment 7 Noa Resare 2004-02-12 23:48:58 UTC
This is fixed for swedish locale in Fedora Core 2 Test 1 (gtk2-2.3.2-2)

Comment 8 Bart Martens 2004-02-17 18:51:07 UTC
Known upstream, see:
http://bugzilla.gnome.org/show_bug.cgi?id=123447

I think it would be nice to have an option for the first day of week,
regardless of the locale. The locale can be used to set the default
value for that option.


Comment 9 Mark McLoughlin 2004-02-20 12:26:31 UTC
Okay, this should be fixed with the gtk2 in Raw Hide. Moving to gtk2
for confirmation.

Comment 10 Owen Taylor 2004-04-05 14:57:46 UTC
We do this with a magic-translated string in GTK+-2.4, so if you are
running with a localized user interface, it should work fine.
(Assuming that the string is translated correctly for your language.)

It would be nicer to base off the date locale settings, but that's
hard to do portably.


Note You need to log in before you can comment on or make changes to this bug.