Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!uunet!munnari.oz.au!brolga!uqcspe!cs.uq.oz.au!warwick From: warwick@cs.uq.oz.au (Warwick Allison) Newsgroups: comp.sys.atari.st.tech Subject: Re: saving screen in a GEM app. Message-ID: <981@uqcspe.cs.uq.oz.au> Date: 25 Apr 91 08:33:49 GMT References: <2991@shodha.enet.dec.com> Sender: news@cs.uq.oz.au Reply-To: warwick@cs.uq.oz.au Lines: 38 [ re multiple dialog boxes ] >There are a couple of other ways to handle this. One that I use is to save the >screen area under the dialog box when you put it up and restore it when you >put it back, using the blit routines. Specifically, you can use the >vro_copyfm() routines. Or you can save each dialog box using the same technique >and restore all of it when you get a redraw message. Or you can save the whole >screen, although this uses 32K of memory. The trouble with this is, you only get 1 level of nesting (or another 32K every time you open another dialog on top of an old one!). A far better, and easier method is to just redraw the form AFTER the nested form is complete. Just use objc_draw for this purpose. I do recommend you read Tim Oren's ProGEM series - they are at atari.archive. You asked about setting your own desktop object, here's how: First, to set an object as the new desktop: (note, this is hacked from Modula-2, so beware) NewDesk=14 rsrc_gaddr(tree,FormNumber,&Form); wind_set(0,NewDesk,Form,0); To go back to the original desktop: wind_set(0,NewDesk,0,0); Warwick. -- _-_|\ warwick@cs.uq.oz.au / * <-- Computer Science Department, \_.-._/ University of Queensland, v Brisbane, AUSTRALIA.