After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 689252 - Use nice Unicode for date formatting for sunrise/sunset times
Use nice Unicode for date formatting for sunrise/sunset times
Status: RESOLVED FIXED
Product: libgweather
Classification: Core
Component: general
3.7.x
Other Linux
: Normal normal
: future
Assigned To: libgweather-maint
libgweather-maint
Depends on: 689184
Blocks:
 
 
Reported: 2012-11-29 04:28 UTC by Matthias Clasen
Modified: 2013-03-02 14:28 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch (2.46 KB, patch)
2012-11-29 04:28 UTC, Matthias Clasen
none Details | Review

Description Matthias Clasen 2012-11-29 04:28:51 UTC
Created attachment 230153 [details] [review]
patch

The ratio character is nicer aligned for this use than the
stock colon, and a thin space is all that is needed before am/pm.

I've just got the ratio character added to Cantarell - you can see a
before/after comparison of the lock screen clock in the cantarell bug 689184 

Note that the patch probably has some python2 assumptions in it - I'm not a native Python speaker, and just googled for how to work around ascii assumptions in strftime
Comment 1 Paolo Borelli 2012-11-29 08:23:53 UTC
Thanks!

I think we can simply use the utf-8 string without encoding the characters: source files show be marked to be in utf-8 and pygobject should be smart enough to allow this, I just quickly tested the following

>>> from gi.repository import Gtk
>>> l = Gtk.Label("€€€€")
>>> w = Gtk.Window()
>>> w.add(l)
>>> w.show()
>>> w.show_all()
>>> Gtk.main()


I also think we use the column in a few more places (e.g. the stopwatch laps)
Comment 2 Matthias Clasen 2012-11-29 11:10:18 UTC
(In reply to comment #1)
> Thanks!
> 
> I think we can simply use the utf-8 string without encoding the characters:
> source files show be marked to be in utf-8 and pygobject should be smart enough
> to allow this, I just quickly tested the following

sure, if that works, that's much better.

> I also think we use the column in a few more places (e.g. the stopwatch laps)

Yeah, I only did the clock and alarm part - I don't know if the ratio will make any difference in the split string situations in the other tabs.

In any case, may want to hold off on applying this until we have a cantarell release which includes the ratio glyph.
Comment 3 Paolo Borelli 2013-01-05 16:30:19 UTC
I am waiting for the py3 port before tackling this so that we do not need to rework twice how utf8 strings are handled
Comment 4 Paolo Borelli 2013-03-02 14:17:52 UTC
clocks is now fixed, except from the sunrise/sunset labels that come directly from libgweather. I am reassigning this bug accordingly.
Comment 5 Giovanni Campagna 2013-03-02 14:28:49 UTC
And now libgweather is fixed too.