Path: utzoo!attcan!uunet!lll-winken!csd4.milw.wisc.edu!mailrus!tut.cis.ohio-state.edu!bloom-beacon!EXPO.LCS.MIT.EDU!kit From: kit@EXPO.LCS.MIT.EDU (Chris D. Peterson) Newsgroups: comp.windows.x Subject: Re: using XtIsManaged or XtIsRealized Message-ID: <8904142042.AA00296@expo.lcs.mit.edu> Date: 14 Apr 89 20:42:55 GMT References: <8904141416.AA21116@expo.lcs.mit.edu> Sender: daemon@bloom-beacon.MIT.EDU Organization: The Internet Lines: 26 > Your original question: > > The > >images will change depending on what the user wants to look at, so I > >need to be able to "wipe out" the image in a Core widget and then redo > >it with the new image. > Set the window background pixel to the white pixel of the screen, > then clear the window: > XSetWindowBackground(dpy, win, WhitePixel(dpy, screen_number)); > XClearWindow(dpy, win); From Carol's message it is not clear what is necessary to redraw the window. If you are drawing the image from an exposure handler then you will need to make a call to XClearArea() with exposures set to TRUE. If you are using a background pixmap you can get by with making a call to XClearWindow() after you have set the background pixmap. This will cause the server to refresh your window from the background pixmap. In any case I don't believe that it is necessary to call XSetWindowBackground(). Chris D. Peterson MIT X Consortium