> But then I need to put my new text over the top in such a way that I can
> revert to the previous text without having to redraw it in the gadget.
When
> I say without redrawing it, I mean not using WinDrawChars etc, I can
handle
> an update gadget event though.
>
> Therefore what I think i need is some sort of rectangle with text that can
> be placed on top of the gadget, but when removed the previous gadget text
> (and graphics) is still there.
Create a compatible off-screen window the size of the gadget using
WinCreateOffscreenWindow. Before drawing your new text, copy the gadget's
rect into the off-screen window using WinCopyRectangle. When you want to
reset it, copy the off-screen window back onto the gadget.
Its really easy -- I use a variation of this technique to cache a bitmap and
then copy parts of it back onto the main window.
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/