Skip to content
This repository has been archived by the owner on Nov 26, 2022. It is now read-only.

Commit

Permalink
More documentation on canvas.
Browse files Browse the repository at this point in the history
  • Loading branch information
szymonrw committed Jun 29, 2011
1 parent 04e8e93 commit 2f19c5d
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/guiftw/swing/canvas.clj
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
(ns guiftw.swing.canvas)
(ns guiftw.swing.canvas
"Contains gen-canvas macro that can make paintable canvas from any
class. One class (Canvas) is generated for general use.
When compiling, generates CanvasEvent class (with getGraphics method
to get Graphics object) representing painting event and
CanvasListener interface with paint method to implement in order to
do drawing.")

;; Class that represents canvas' drawing event
;;
Expand Down Expand Up @@ -53,6 +60,7 @@
[~'removeCanvasListener [guiftw.swing.CanvasListener] Object]
[~'getCanvasListeners [] clojure.lang.PersistentVector]]))

;; General purpose Canvas class with JPanel as superclass.
(gen-canvas javax.swing.JPanel guiftw.swing.Canvas)

(defn canvas-init [& args]
Expand Down

0 comments on commit 2f19c5d

Please sign in to comment.