Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!usc!apple!motcsd!xdos!doug From: doug@xdos.UUCP (Doug Merritt) Newsgroups: comp.sys.amiga.tech Subject: Re: Gadget help wanted Message-ID: <668@xdos.UUCP> Date: 14 Feb 90 20:26:52 GMT References: <1039LK-KARI@FINTUVM> <23@tmiuv0.uucp> <25d085dd:842.4comp.sys.amiga.tech;1@tronsbox.UUCP> <5200@amiga.UUCP> Reply-To: doug@xdos.UUCP (Doug Merritt) Organization: Hunter Systems, Mountain View CA (Silicon Valley) Lines: 29 In article <5200@amiga.UUCP> jimm@superman.UUCP (Jim Mackraz) writes: >Intuition V1.3 and earlier has no support for erasing gadgets, so you >just have to do it yourself. For most situations, I think something >like this will work: > >SetAPen( window->RPort, 0 ); >RectFill( window->RPort, g->LeftEdge, g->TopEdge, > g->LeftEdge + g->Width - 1, g->TopEdge + g->Height - 1 ); > >If the gadget is GRELBOTTOM or something like that, you have to >do more work. Likewise if it's in a requester or gimmezerozero border. I did this recently, for temporarily dumping all the system gadgets from a window. It's a pain to get it right, at least when you want to turn them on/off at will. When you put them back again, for instance, the first vertical line of pixels at the start of the title is not redrawn by anything I could find to try, so I had to put it back myself. You would think that when the title gets refreshed, that it would include that. The net effect is nice, though...when this tiny window is deactivated, it uses the entire interior for displaying a graph (it's a perfmeter). When it's activated, the system gadgets come back for friendly control. This makes the perfmeter usable even in very small dimensions. Doug -- Doug Merritt {pyramid,apple}!xdos!doug Member, Crusaders for a Better Tomorrow Professional Wildeyed Visionary