diff --git a/teachpack/htdc/Docs/draw.thtml b/teachpack/htdc/Docs/draw.thtml new file mode 100644 index 0000000000..f4e0803f65 --- /dev/null +++ b/teachpack/htdc/Docs/draw.thtml @@ -0,0 +1,49 @@ +{ (define LIBNAME "A Functional Drawing Library (HtDC)") + (include "head.tinc") } + +This `draw' package provides classes and methods for modeling in a visual +world. Here is its class diagram of public fields and methods: +
+
+ +-----------------------------------+
+ | abstract World |
+ +-----------------------------------+ +---------------------------------------+
+ | Canvas theCanvas |------>| Canvas |
+ +-----------------------------------+ +---------------------------------------+
+ | boolean bigBang(int,int,double) | +---------------------------------------+
+ | boolean endOfTime() | | boolean start(int,int) |
+ | boolean endOfWorld() | | boolean stop() |
+ | World lastWorld() | | boolean drawCircle(Posn,int,Color) |
+ | | | boolean drawDisk(Posn,int,Color) |
+ | abstract World onTick() | | boolean drawRect(Posn,int,int,Color) |
+ | abstract World onKeyEvent(String) | | boolean drawLine(Posn,Posn,Color) |
+ | abstract boolean draw() | | boolean drawString(Posn,String) |
+ | abstract boolean erase( | | boolean clearCircle(Posn,int,Color) |
+ +-----------------------------------+ | boolean clearDisk(Posn,int,Color) |
+ | boolean clearRect(Posn,int,int,Color) |
+ | boolean clearLine(Posn,Posn,Color) |
+ +---------------------------------------+
+
+ +----------+
+ | Posn |
+ +----------+
+ | int x |
+ | int y |
+ +----------+
+
+ +-------+
+ | Color |
+ +-------+
+ |
+ / \
+ ---
+ |
+ ------------------------------------------
+ | | | | |
+ +-------+ +-------+ +-------+ +-------+ +-------+
+ | Blue | | Green | | Red | | White | | Yellow|
+ +-------+ +-------+ +-------+ +-------+ +-------+
+
+
+
+{(include "foot.tinc")}
diff --git a/teachpack/htdc/Docs/foot.tinc b/teachpack/htdc/Docs/foot.tinc
new file mode 100644
index 0000000000..454bc56343
--- /dev/null
+++ b/teachpack/htdc/Docs/foot.tinc
@@ -0,0 +1,4 @@
+