next up previous contents
Next: Changes in Specific Up: Changes to System Previous: Version Information

Content Backgrounds

The protocol used by the standard :redraw-content  methods has been augmented to support maintaining a background for plot contents. Instead of erasing the content area before drawing the content, these methods now send the :clear-content  message. The default method for this method clears the content area. By overriding this method, you can draw any background you want to maintain.

Unless you want to handle clearing the background yourself, you should begin your method with a call to call-next-method 

A simple example: The code

(setf p (plot-points (normal-rand '(10 10))))

(defmeth p :clear-content ()
  (call-next-method)
  (send self :frame-rect 50 50 100 100))
sets up a plot that contains a rectangle in its background.

This new protocol is still experimental and may change if a better design is found.



Luke Tierney
Wed Feb 26 05:25:18 CST 1997