From 2d34d9a26c9625ea44dfff1fa5900be58f825fec Mon Sep 17 00:00:00 2001
From: Matthias Felleisen (on-tick-event tock)
means that DrScheme must call tock
on the current world every time the clock ticks; it uses the result as the next world
-on-key-event : (KeyEvent World -> World) -> true
+on-key-event : (World KeyEvent -> World) -> true
(on-key-event change)
means that DrScheme must call
- change
on the current world for every keystroke event; it uses
+ change
on the current world and a (representation of the)
+ keyevent for every keystroke the programmer (user of the computer) makes; it uses
the result as the next world
@@ -37,11 +38,10 @@ students to simulate a small world of animated drawings and games:
calls
world->image
whenever the canvas must be redrawn; the
result is displayed in the teachpack's canvas
-end-of-time : -> World
- When DrScheme evaluates (end-of-time)
, it stops the clock; no
- further tick events, key events, or redraw events take place until the world
- is created again.
-
end-of-time String u Symbol : -> World
(end-of-time)
, it stops the clock and displays the
+ given string or symbol; no further tick events, key events, or redraw events
+ take place until the world is created again.
The rest are functions for creating scenes: