[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: problem with windows
- To: info-mcl@cambridge.apple.com, lementec@asuka.aerospace-lab.go.jp
- Subject: Re: problem with windows
- From: jbk@world.std.com (Jeffrey B Kane)
- Date: Mon, 15 Nov 1993 16:28:10 -0500
Jean-Christophe,
Do ALL your drawing within a view-draw-contents for this window. Let
the system call the method when it determines something needs to be
drawn (even when you first create it, let the system decide that it
needs to be drawn). What you are seeing is the system clearing the window
and trying to draw the contents according to it's view-draw-contents.
(defclass special-window (window)
nil)
(defmethod view-draw-contents ((self special-window))
(with-fore-color *red-color*
(move-to self 0 0)
(line-to self (view-size self))
(move-to self (point-h (view-size self)))
(line-to self 0 (point-v (view-size self))))
(with-fore-color *blue-color*
(move-to self #@(50 50))
(format self "Hi there")))
(make-instance 'special-window :color-p t :window-title "Test")
Jeffrey
======================================
Jeffrey Kane, MD
Kane Biomedical Systems
Boston, MA
Internet jbk@world.std.com
Compuserve 74206,640
AppleLink D0738
[Don't take life too seriously... it's not like anyone gets out of it alive.]