Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!auspex!guy From: guy@auspex.auspex.com (Guy Harris) Newsgroups: comp.windows.x Subject: Re: Clock widget for different timezones Message-ID: <8634@auspex.auspex.com> Date: 30 Jun 91 02:14:35 GMT References: <9129@gollum.twg.com> <8488@auspex.auspex.com> <6149@lupine.NCD.COM> Organization: Auspex Systems, Santa Clara Lines: 45 >I much prefer a straight offset from current local time, although I opted >for specifying minutes instead of hours, so I can make up for skewed system >times and also set my desk xclock ten minutes fast on meeting days. That's solving a different problem - the time zone problem isn't necessarily a straight offset from current local time (e.g., in the US and Canada, not all areas observe DST). In fact, you might want a clock that solves *both* problems, e.g. if your system time is skewed *and* you need to know what time it is halfway around the globe. >TZ is useful, but try to figure out that it even exists, The way to tell new or infrequent users that TZ exists is to document it - preferably in, say, the "how you use your whizzo new clock program" manual page or whatever. (It'd *still* probably be less complicated than the documentation for my watch - and mine's a fairly simple-minded one. :-)) (No, don't just mention it in the documentation for the widget; it's a pain in the neck having to check the Athena Widgets documentation, which is rather programmer-oriented, if all you want to do is customize the Text widget so that you can cut or copy to the Clipboard.) > let alone how to specify it, if you're a new or infrequent user... If I want to know what time it is in Japan, I generally just set TZ to "Japan" and run "date". I *did* say "systems with the Arthur Olson code", after all. :-) I.e., in systems with AO time zone code, the strings you set TZ to are (unless you're a pervert who actually *likes* the S3/S5/POSIX/etc. standard syntax :-)) character strings reasonable, at least, to English speakers (although the European time zones have names like "MET" and "WET" and "EET"). You might still need a table that says what the names for various time zones are, but your average user probably doesn't even know how many different sets of time zone rules there are (if you have a system with the AO code, and the vendor supplied the source to the rules files, take a look at them - it's an educational experience; they're in "/usr/share/lib/zoneinfo" in SunOS 4.x, in "africa", "antarctica", "asia", "australasia", "europe", "northamerica", "pacificnew", and "southamerica"), so they'd probably need to have all the time zones enumerated *anyway* - you might as well give the TZ setting names while you're at it.