Bug#614982: gdm3 greeter should display the time in the current locales
On 2011-02-24 18:32:30 +0100, Vincent Lefevre wrote: gdm3 displays the time as 6:28 while we use the 24hr format in France, so that it should be: 18:28. So, gdm3 should use the time format specified in the locales (set via /etc/default/locale). It could also be configurable (as suggested in bug 656161), but the default should be specified by the locales (LC_TIME...), e.g. by using %X. The update_time_format code in gdm-clock-widget.c has different formats, but only one seems to be used in practice. Anyway, there are locales where %p doesn't make sense at all and appears as blank. I've attached a patch that solves the problem on my side (I don't know about the other formats). With it, the seconds are also displayed. That's why the 1-minute timeout is removed, but this timeout was incorrect even when the seconds are not displayed (bug 680020). -- Vincent Lefèvre vinc...@vinc17.net - Web: http://www.vinc17.net/ 100% accessible validated (X)HTML - Blog: http://www.vinc17.net/blog/ Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon) --- a/gui/simple-greeter/gdm-clock-widget.c 2011-09-04 20:44:17.0 +0200 +++ b/gui/simple-greeter/gdm-clock-widget.c 2012-07-03 01:21:40.0 +0200 @@ -86,11 +86,7 @@ */ tooltip_format = %x; } else { -/* translators: This is the time format to use when there is - * no date, just weekday and time without seconds. - */ -clock_format = _(%a %l:%M %p); - +clock_format = %a %X; tooltip_format = %x; } @@ -161,11 +157,6 @@ g_get_current_time (tv); timeouttime = (G_USEC_PER_SEC - tv.tv_usec) / 1000 + 1; -/* timeout of one minute if we don't care about the seconds */ -if (! clock-priv-should_show_seconds) { -timeouttime += 1000 * (59 - now % 60); -} - clock-priv-update_clock_id = g_timeout_add (timeouttime, (GSourceFunc)update_timeout_cb, clock);
Bug#614982: gdm3 greeter should display the time in the current locales
Package: gdm3 Version: 3.0.4-4 Followup-For: Bug #614982 Dear Maintainer, Looking at the source-code, the hardcoded strftime strings are passed to gettext, to allow localization. But this is incorrect; time formatting should be subject to LC_TIME, not LC_MESSAGES. Anyway, a way to override the actual format string using GSettings or whatever would also be appreciated. // Marcus -- System Information: Debian Release: wheezy/sid APT prefers testing APT policy: (500, 'testing') Architecture: amd64 (x86_64) Kernel: Linux 3.0.0-1-amd64 (SMP w/2 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=sv_SE.ISO-8859-1 (charmap=ISO-8859-1) Shell: /bin/sh linked to /bin/bash Versions of packages gdm3 depends on: ii accountsservice 0.6.15-1 ii adduser 3.113 ii dconf-gsettings-backend 0.7.5-3 ii debconf [debconf-2.0] 1.5.41 ii gconf2 2.32.4-1 ii gnome-session [x-session-manager] 3.0.2-3 ii gnome-session-bin 3.0.2-3 ii gnome-session-fallback [x-session-manager] 3.0.2-3 ii gnome-terminal [x-terminal-emulator]3.0.1-1 ii gsettings-desktop-schemas 3.2.0-2 ii kterm [x-terminal-emulator] 6.2.0-46 ii libaccountsservice0 0.6.15-1 ii libatk1.0-0 2.2.0-2 ii libattr11:2.4.46-3 ii libaudit0 1.7.18-1 ii libc6 2.13-21 ii libcairo-gobject2 1.10.2-6.1 ii libcairo2 1.10.2-6.1 ii libcanberra-gtk3-0 0.28-3 ii libcanberra00.28-3 ii libdbus-1-3 1.4.16-1 ii libdbus-glib-1-20.98-1 ii libfontconfig1 2.8.0-3 ii libfreetype62.4.8-1 ii libgconf2-4 2.32.4-1 ii libgdk-pixbuf2.0-0 2.24.0-1 ii libglib2.0-02.30.2-4 ii libglib2.0-bin 2.30.2-4 ii libgtk-3-0 3.0.12-2 ii libpam-modules 1.1.3-6 ii libpam-runtime 1.1.3-6 ii libpam0g1.1.3-6 ii libpango1.0-0 1.29.4-2 ii librsvg2-common 2.34.2-1 ii libselinux1 2.1.0-4 ii libupower-glib1 0.9.14-3 ii libwrap07.6.q-21 ii libx11-62:1.4.4-4 ii libxau6 1:1.0.6-4 ii libxdmcp6 1:1.1.0-4 ii libxklavier16 5.1-2 ii libxrandr2 2:1.3.2-2 ii lsb-base3.2-28 ii metacity [x-window-manager] 1:2.34.1-2 ii policykit-1-gnome 0.105-1 ii sawfish [x-window-manager] 1:1.3.5.2-2 ii twm [x-window-manager] 1:1.0.6-1 ii upower 0.9.14-3 ii xterm [x-terminal-emulator] 276-1 Versions of packages gdm3 recommends: ii at-spi 1.32.0-1 ii desktop-base 6.0.7 ii gnome-icon-theme 3.2.1.2-1 ii gnome-power-manager3.0.2-3 ii gnome-settings-daemon 3.0.3-3 ii x11-xkb-utils 7.6+4 ii xserver-xephyr 2:1.11.1.902-1 ii xserver-xorg 1:7.6+9 ii zenity 3.2.0-1 Versions of packages gdm3 suggests: ii gnome-mag none ii gnome-orcanone ii gok none ii libpam-gnome-keyring 3.0.3-2 ii metacity 1:2.34.1-2 -- Configuration Files: /etc/gdm3/greeter.gconf-defaults changed [not included] /etc/gdm3/greeter.gsettings changed [not included] -- debconf information excluded -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#614982: gdm3 greeter should display the time in the current locales
Package: gdm3 Version: 2.30.5-7 Severity: normal gdm3 displays the time as 6:28 while we use the 24hr format in France, so that it should be: 18:28. So, gdm3 should use the time format specified in the locales (set via /etc/default/locale). -- System Information: Debian Release: wheezy/sid APT prefers unstable APT policy: (500, 'unstable'), (500, 'stable'), (1, 'experimental') Architecture: amd64 (x86_64) Kernel: Linux 2.6.37-1-amd64 (SMP w/8 CPU cores) Locale: LANG=POSIX, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages gdm3 depends on: ii adduser 3.112+nmu2 add and remove users and groups ii debconf [debconf-2. 1.5.38 Debian configuration management sy ii fvwm [x-window-mana 1:2.5.30.ds-1+local1 F(?) Virtual Window Manager ii gconf2 2.28.1-6 GNOME configuration database syste ii gnome-session [x-se 2.30.2-3 The GNOME Session Manager - GNOME ii gnome-session-bin 2.30.2-3 The GNOME Session Manager - Minima ii gnome-terminal [x-t 2.30.2-1 The GNOME terminal emulator applic ii icewm [x-window-man 1.3.7~pre2-1+b1 wonderful Win95-OS/2-Motif-like wi ii libart-2.0-22.3.21-1 Library of functions for 2D graphi ii libatk1.0-0 1.30.0-1 The ATK accessibility toolkit ii libattr11:2.4.44-2 Extended attribute shared library ii libaudit0 1.7.13-1+b2 Dynamic library for security audit ii libbonobo2-02.24.3-1 Bonobo CORBA interfaces library ii libbonoboui2-0 2.24.3-1 The Bonobo UI library ii libc6 2.11.2-11Embedded GNU C Library: Shared lib ii libcairo2 1.10.2-2 The Cairo 2D vector graphics libra ii libcanberra-gtk00.24-1 Gtk+ helper for playing widget eve ii libcanberra00.24-1 a simple abstract interface for pl ii libdbus-1-3 1.4.6-1 simple interprocess messaging syst ii libdbus-glib-1-20.88-2.1 simple interprocess messaging syst ii libfontconfig1 2.8.0-2.1generic font configuration library ii libfreetype62.4.4-1 FreeType 2 font engine, shared lib ii libgconf2-4 2.28.1-6 GNOME configuration database syste ii libglib2.0-02.28.1-1+b1 The GLib library of C routines ii libgnome2-0 2.30.0-1 The GNOME library - runtime files ii libgnomecanvas2-0 2.30.1-1 A powerful object-oriented display ii libgtk2.0-0 2.20.1-2 The GTK+ graphical user interface ii liborbit2 1:2.14.18-0.1libraries for ORBit2 - a CORBA ORB ii libpam-modules 1.1.2-2 Pluggable Authentication Modules f ii libpam-runtime 1.1.2-2 Runtime support for the PAM librar ii libpam0g1.1.2-2 Pluggable Authentication Modules l ii libpanel-applet2-0 2.30.2-4 library for GNOME Panel applets ii libpango1.0-0 1.28.3-1+squeeze1Layout and rendering of internatio ii libpolkit-gobject-1 0.99-3 PolicyKit Authorization API ii libpolkit-gtk-1-0 0.99-2 PolicyKit GTK+ API ii libpopt01.16-1 lib for parsing cmdline parameters ii librsvg2-common 2.26.3-1 SAX-based renderer library for SVG ii libselinux1 2.0.96-1 SELinux runtime shared libraries ii libupower-glib1 0.9.8-2 abstraction for power management - ii libwrap07.6.q-19 Wietse Venema's TCP wrappers libra ii libx11-62:1.4.1-5X11 client-side library ii libxau6 1:1.0.6-1X11 authorisation library ii libxdmcp6 1:1.1.0-1X11 Display Manager Control Protoc ii libxklavier16 5.0-2X Keyboard Extension high-level AP ii libxml2 2.7.8.dfsg-2 GNOME XML library ii lsb-base3.2-27 Linux Standard Base 3.2 init scrip ii metacity [x-window- 1:2.30.1-3 lightweight GTK+ window manager ii policykit-1-gnome 0.99-2 GNOME authentication agent for Pol ii twm [x-window-manag 1:1.0.6-1Tab window manager ii upower 0.9.8-2 abstraction for power management ii xterm [x-terminal-e 268-1X terminal emulator ii zlib1g 1:1.2.3.4.dfsg-3 compression library - runtime Versions of packages gdm3 recommends: ii at-spi1.30.1-3 Assistive Technology Service Provi ii desktop-base 6.0.6 common files for the Debian Deskto ii gnome-icon-theme 2.30.3-2 GNOME Desktop icon theme ii gnome-power-manager 2.32.0-2 power management tool for the GNOM ii gnome-settings-daemon