Morphic redraws completely hidden objects.

Ned Konz ned at bike-nomad.com
Tue Aug 5 19:50:04 UTC 2003


On Tuesday 05 August 2003 11:29 am, John M McIntosh wrote:
> Thus someone might want to look at why completely hidden objects
> get   redrawn.

What were you covering it with?

There is a Morph method called #areasRemainingToFill: that should be 
overridden by subclasses that have known-opaque regions.

The default version of the method assumes that the Morph is totally 
transparent and so redraws everything underneath.

areasRemainingToFill: aRectangle
	^ Array with: aRectangle

BorderedMorph has probably the smartest version of this, taking into 
account translucency, transparency, and borders.

For a completely opaque Morph, you could do this:

areasRemainingToFill: aRectangle
	^ aRectangle areasOutside: self bounds

-- 
Ned Konz
http://bike-nomad.com
GPG key ID: BEEA7EFE



More information about the Squeak-dev mailing list