[sugar] Sugar Clock

Tomeu Vizoso tomeu
Tue Oct 14 13:51:23 EDT 2008


On Tue, Oct 14, 2008 at 7:40 PM, Benjamin M. Schwartz
<bmschwar at fas.harvard.edu> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Eben Eliason wrote:
> | On Mon, Oct 13, 2008 at 6:53 AM, Carlo Falciola <cfalciola at yahoo.it> wrote:
> |> Carlo : nowhere in the default GUI there is a clock, even if, in the
> control panel there is a panel to configure it. I think that personal
> watches are maybe not so easily owned by kids around the word, so a
> standard clock could be a little, but welcomed feature. (not talking about
> the clock activity that it is more a "learn to read a clock" thing than an
> everyday tool). any feedback and suggestion regarding how and where to
> put/show it are welcomed.
> |
> | I personally would like to see this built.  I've always thought that a
> | "clock device" would fit perfectly into the bottom edge of the Frame.
> | I'd really like to see us rework the devices a bit so that they are
> | more naturally "pluggable" (at most, the user would only have to add
> | one directory at some location in the system to add a new device). In
> | the future perhaps we can extend this to a user-facing management of
> | installed devices.
> |
> | Apart from the trickiness (and potential CPU hit) of dynamically
> | updating the clock icon (I envision an analog clock here, with digital
> | display and date and/or calendar in the palette, so granularity would
> | be on the order of a minute or so).
>
> There are a few issues here:
>
> 1. The current Sugar icon system is problematic in general, and especially
> in this case.  The Frame Device code does not allow arbitrary widgets.
> Instead, each device must specify a discrete group of SVG icons.  The
> device may then select one of these icons to display.  I tried to build a
> frame device clock, but gave up when I realized it would require
> generating hundreds of different icons.  (The same problem affects the
> "signal strength meter" icons representing each network, which are
> naturally continuous, but are drawn by selecting one of about 10 different
> fixed icon shapes.)
>
> Fix: change the frame device system to allow arbitrary widgets, or at
> least arbitrary pixmaps.

I think it does accept arbitrary widgets now, not sure since when.

> 2. The current power management system on XO provides no timed wakeups.
> Timed wakeups require significant work in both the kernel and EC.  As far
> as I am aware, no one is actively working on this.  Without timed wakeups,
> the system could easily suspend with the clock displayed, freezing the
> time and misleading users as to what time it is.  Until we have timed (or
> periodic) wakeups, a clock cannot be part of the default view, because an
> incorrect clock is worse than none at all.
>
> Fix: Relegate the clock to an Activity, which can inhibit suspend when
> visible, to ensure that the clock updates appropriately.  Work on EC-based
> timed wakeups.  A good intermediate target might be to have the EC wake up
> the system every 60 seconds without hooking into the scheduler at all, so
> that any wakeups scheduled in the previous minute (e.g. from the presence
> service) can fire.

Crazy idea: put in the frame a widget that only updates (and displays)
itself 20 seconds after the mouse has been over it. If it was an
analog clock, the arms could dissolve when it stops updating, if a
digital clock, it could display some text instead of the time.
Hopefully, the user would learn to hover it with the pointer when
wanted to see the current time.

> 3. Analog clocks are deprecated.  Outside of the West, clocks vary widely,
> and 12-hour mechanical circular dial clocks are by no means the norm.  In
> Europe, 24-hour digital clocks are the most common type.  Even in the US,
> children often have difficulty reading small analog clocks until late in
> middle school, because virtually all such clocks have been replaced by
> digital displays.  The small XO screen will make an analog clock icon even
> less legible.
>
> Fix: Draw a digital clock to 1-minute precision using a simple GTK text
> display.  Format the time according to strftime's %X or %c.  (See
> http://docs.python.org/library/datetime.html#strftime-behavior)

Sounds good to me.

Thanks,

Tomeu



More information about the Sugar-devel mailing list