GNOME Bugzilla – Bug 88754
clock applet should support changing timezones
Last modified: 2015-03-24 13:01:06 UTC
It's sometimes useful to be able to adjust the hours in the clock applet, eg if you want to know what time it is in another time zone.
Created attachment 9998 [details] [review] v1: first take
Created attachment 9999 [details] [review] v2: set the value in display_properties_dialog
I think it would make more sense to have a timezone selector ... A spin button labelled 'Offset' isn't exactly telling the user much ...
Any thoughts on this UI, usability-maint? I tend to agree with Mark that it just isn't quite right...
I agree with Mark too. It would be better with a timezone selector. I tried to fixed it a few days ago but i couldn't find any decent data. Similiar to that one find in the timezone selector in Windows.
I think a time zone selector is much better personally, but isn´t this a system thing, more of a setup tools issue. i remember a while ago requesting functionality in the clock to set the system time, theres an open bug as well.
Yeah, I'm not sure whether it makes sense for the clock to have a different timezone than the system time.
Well, if you're often travelling or just need to keep track of the time of another time zone. But it guess it's not a feature that will be used so commonly.
Glynn: This is basically the timezone selector applet thing you were working on when you went to aussieland right ?
yeah, I was working on something..but I've had zero time to follow it up since then and the code I had isn't very useful right now ;)
Has anything be decided on this ? gworldclock may be a useful app here.
This is a very useful functionality for people who work with colleagues who are in different timezones, or have family and friends in a far way timezone. With CDE and GNOME 1.x I had 3 clocks in my "panel", one for the Europe/London, one for Australia/Adelaide and one for US/Pacific. This was done by running xclock (yes the MIT xclock) and setting $TZ in the xclock environment. Note that an offset doesn't work since it doesn't take into account daylight savings and it assumes you acutally remember the offset to the alternate zone. As for a User interface I would like to see the following: * The ability to enter into a text box a POSIX timezone. * At some later time a GUI selector similar to what is in evolution could be added. * Removal of the gimicy UNIX time and Internet time to an advanced config area (or removed totally). * Display of the timezone name (configurable, just like seconds/date).
Ghee Teo [Sun] has been working on an applet, but hasn't had time to finish it. From what I saw last time it looked really sweet. Hopefully he'll be able to get it in for GNOME 2.4.
cc'ing Matt, as he's taking over on the world clock work Ghee was doing, and the suggested feature list might be of interest (although it already does most of them IIRC)
*** Bug 119304 has been marked as a duplicate of this bug. ***
The clock applet has an "Adjust Time & Date" thing that launches a user specified thing or time-admin (from g-s-t). In time-admin, we can set the timezone. Is this enough or do we want to support changing the timezone while not being root ?
Yeah, I think we do want this - it can be quite useful to have a second clock showing a different timezone ... In our (Sun's) Java Desktop System release we have a patch to do this but it requires a *lot* of cleanup before it can go back into head. I'll attach it here for anyone who's interested in re-writing it ...
Created attachment 20678 [details] [review] patch
Note incidentally that this patch implements nothing like the UI we actually designed for it :) I'll be happy to describe that here later on when I've got a minute, if it's going to be useful...
Erwann has completely rewritten this patch for JDS recently... could/should we attach it here...?
Calum: yes, please attach the patch if possible.
I was really asking the Sun guys, I don't know if it's a patch we want to keep to ourselves for a while or not :)
Created attachment 24812 [details] [review] timezone patch with graphical timezone selection
Created attachment 24813 [details] image for the graphical selection
I've attached what will be in the next release of Sun's gnome version. This patch allow the user to graphically select the timezone the applet will display. It also allow to display the main city in the selected timezone alongside the time and date in the applet. Let me know what you think of the patch.
I forgot. you need to add the attached image in the applets/clock directory to properly compile the clock applet.
With or without the graphical selection, it would be nice if there was a checkbox that would allow the timezone to be shown beside the time too. I'd like to *see* that the 18:51 on my screen really is UTC (or whichever)...
*** Bug 152096 has been marked as a duplicate of this bug. ***
Shouldn't be an issue now that we have GNOME System Tools/time-admin integration for the clock applet. regs, Chris
From comment #17: Yeah, I think we do want this - it can be quite useful to have a second clock showing a different timezone ... Reopening the bug.
Created attachment 46854 [details] [review] timezone patch Here's an updated patch that builds against 2.10.1. It still uses the same timezone image that Erwann attached previously. It probably needs a bit of work to clean up the interface, but I find it quite useful.
Basically the interface to this looks like - [clock image] Wednesday May 25, 3:20PM clicking on the clock image brings up a menu [List of different time zones] ============================== Edit time zones... The list of time zones looks like - Auckland Wed May 25, 3:21PM Dublin Wed May 25, 4:21AM Los Angeles Tue May 24, 8:21PM Sydney Wed May 25, 1:21PM Paris Wed May 25, 5:22AM [none are selectable - perhaps that's something we could do, selecting them changes the display on the main applet] Clicking on Edit Time Zones... gives a dialog with a map and various locations. You can click on different locations and add to the list, or remove existing ones.
*** Bug 166886 has been marked as a duplicate of this bug. ***
*** Bug 336443 has been marked as a duplicate of this bug. ***
I agree that you should be able to select an alternate timezone without needing the admin password and have the full time tool. Just a menu of timezones listed (with numerical offsets mentioned), plus an option to use the system's default, would be good. The clock should display the timezone next to the time IF you are using an alternate timezone (rather than selecting the system default) OR specifically request it with a checkbox in the preferences.
One major caveat: it might be better if this "user's custom timezone" was available for other Gnome apps too, like the calendar. I.e. if you set the timezone in the clock applet, but assume that the rest of Gnome also uses that time displayed in the applet (perhaps you even forget that you customized the clock applet in this way), you might get in trouble. Sometimes the simplest things have kind of large impacts on user assumptions etc... :)
Created attachment 67227 [details] [review] Latest generation patch to apply to 2.14.x sources Again as Mark commented earlier, this patch may need some cleanup before it gets committed to head, but I'd personally like to see this type of functionality in GNOME 2.16
[Thanks are due to Erwann who actually sat down and ported the patch to the latest sources - he gets credit, though may not have the time with his commitments to work on the patch further]
Created attachment 77614 [details] [review] another update
Here is another update of the patch. This one applies to 2.16.x. It has some additional fixes and cleanups over the earlier versions. - the two calendar popups are now mutually exclusive - I've decided to use an arrow instead of an icon. This uses less panel space, and avoids icon sizing complications. - popup positioning glitches have been fixed - a bug in the initial visibility of the timezone button has been fixed - the timezone button has a tooltip
*** Bug 358515 has been marked as a duplicate of this bug. ***
Vincent, any word on this ? I think this would add real value to the panel clock for many people.
(In reply to comment #42) > Vincent, any word on this ? I think this would add real value to the panel > clock for many people. I definitely want this to go in. I didn't look at the latest versions of the patch, but I'm wondering if having the timezones in a menu instead of a popup would be better. We might also want to kill the "Use UTC" pref.
This is something I would have found incredibly useful while on a study abroad program last semester. I was disappointed when I figured out that I couldn't have one clock with my local time and one with my "native" time zone (so I'd know not to try calling home when it was 3am).
*** Bug 399690 has been marked as a duplicate of this bug. ***
Created attachment 88135 [details] [review] Updated to trunk (but crashes) I quickly tried updating the patch to trunk, but it crashes in lots of interesting ways. It might be better to start again from the previous patch...
Created attachment 90561 [details] [review] gnome-panel-2.18.1-intl.patch Ported to 2.18.1
Created attachment 90579 [details] [review] gnome-panel-trunk.patch I tried to port the patch to the trunk, it seems it works, but it probably need a bit more testing.
Thanks for the update, Nicolas! I didn't have time to look at the whole code, but it can be improved in some ways. In change_clock_orientation(), we use a HBox and a VBox. I'd prefer to use obox.c from the notification area which is handling this situation in a better way. I'm not fan of having to make ClockData "public". It'd be better if it's possible to keep the structure private, but I didn't check how it was used in new files. Having a script to synchronize the e-map code from evolution would be useful too. For libegg, we used to have a update-from-egg.sh which was doing this.
It's really not possible to commit the patch in this state: the code is far from being clean. I'll work on improving it.
Created attachment 91069 [details] [review] Non-complete patch Here's a nearly totally rewritten patch. It's useless right now, since there are some missing parts (adding/removing/editing a timezone) and some TODO. I'm attaching it now because it'd be a shame to lose the work that has been done so far.
Created attachment 91146 [details] [review] Feature-complete patch With this patch, everything is working. It's a bit crashy in some known cases (documented by some TODO in the code). Also, it probably needs some UI love. Oh, also the gconf schema needs an update.
I've nearly finished my patch and committed it. There are still some TODO items, but it's working now. At least for me :-) I really don't know if this will work on Solaris/BSD/etc. since the part to detect timezones has not been tested on those. Tests welcome for this. (I've opened bug 453827 to track the remaining things to do)