Clock activity: Difference between revisions
Jump to navigation
Jump to search
(Added source code and more screenshots) |
m (Lok to package) |
||
Line 69: | Line 69: | ||
===Source=== |
===Source=== |
||
[[Image:Clock-1.xo|Clock-1.xo package]] |
[[:Image:Clock-1.xo|Clock-1.xo package]] |
||
Revision as of 23:48, 3 February 2008
see more templates or propose new |
For the general public
Description & Goals
Summary
The Clock activity aims at two simple goals:
- As a teaching tool to help children learn how to read time.
- To give the children a way to know the time it is, with their XO, even they don't earn a watch.
The presentation on screen has been kept simple enough to reach these two objectives.
Current Use & Goals
Click on right button to change display mode.
- Simpler display
- With hours numbers
- Date and day
- Nice clock face
Other uses
Learn how to find geographical North (or South, depending in which hemisphere you are located) using the clock hands: Findind True North Without a Compass. And from there, build a solar clock!
Screenshots
For Developers
Development
This code is released in Public Domain, so you can do whatever you want with it. This is simple enough that Python learners can try to add or change features. The whole clock code, with many detailed comments, is a 300 lines Python source.
Point of interests:
- PyGTK events programming, when one clicks on right button.
- Cairo drawing.
- Localization. Though a clock face should look quite similar in all cultures, you can adapt the way it displays hours numbers and date.
- SVG rendering. The nice clock background is the SVG file clock.svg (drawn with Inkscape). You can change it to your liking.
Source
Clock-1.xo package
Functional Test
- Open the clock activity.
- Check that it display the current time of the XO.
- Click on right button to change clock face display. Display mode loops (simple + hours + day and date + nice clock).
- Close the activity; ensure that it closes properly.