[gsettings-desktop-schemas/mcatanzaro/clock-format] Fix default clock format, and allow localization




commit 2e7d0cd3c7b5320fd21165728147cda48783a0e6
Author: Michael Catanzaro <mcatanzaro redhat com>
Date:   Fri Jan 7 19:06:13 2022 -0600

    Fix default clock format, and allow localization
    
    Currently the default clock format is unconditionally set to a 24-hour
    clock. This is incorrect because the default locale is US English, which
    uses a 12-hour clock. But we really do want to default to 24-hour clocks
    in other locales. What to do?
    
    Sebastian Keller proposed making the default value translatable, which
    is apparently a thing that's actually possible. Well, sort of possible.
    The functionality is currently broken, but it's *intended* to work, so
    let's make use of it here. A fix for GLib to make this actually work
    will be proposed separately, see glib#2575.
    
    Translators: you will want to translate this from '12h' to '24h' if your
    locale uses a 24-hour clock. Yes, it's a shame that we have to do this
    when in theory the locale already knows how to format time, but this is
    a pragmatic solution.
    
    Fixes #30

 schemas/org.gnome.desktop.interface.gschema.xml.in | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/schemas/org.gnome.desktop.interface.gschema.xml.in 
b/schemas/org.gnome.desktop.interface.gschema.xml.in
index a998708..7782323 100644
--- a/schemas/org.gnome.desktop.interface.gschema.xml.in
+++ b/schemas/org.gnome.desktop.interface.gschema.xml.in
@@ -208,7 +208,8 @@
       <description>A “\n” separated list of “name:color” as defined by the “gtk-color-scheme” 
setting</description>
     </key>
     <key name="clock-format" enum="org.gnome.desktop.GDesktopClockFormat">
-      <default>'24h'</default>
+      <!-- TRANSLATORS: select your locale's default clock format, this should be '12h' or '24h' (with the 
quotes!) -->
+      <default l10n="time">'12h'</default>
       <summary>Whether the clock displays in 24h or 12h format</summary>
       <description>
         Whether the clock displays in 24h or 12h format


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]