Path: utzoo!attcan!uunet!lll-winken!lll-tis!helios.ee.lbl.gov!pasteur!ames!mailrus!tut.cis.ohio-state.edu!bloom-beacon!ATHENA.MIT.EDU!swick From: swick@ATHENA.MIT.EDU (Ralph R. Swick) Newsgroups: comp.windows.x Subject: Re: background pixmap in a widget Message-ID: <8812092154.AA03487@LYRE.MIT.EDU> Date: 9 Dec 88 21:54:48 GMT References: <8812092122.AA04208@intrepid.riacs.edu> Sender: daemon@bloom-beacon.MIT.EDU Organization: DEC/MIT Project Athena Lines: 17 > Okay, I made my own widget using the Template widget supplied with R3. > The X folks are to be congratulated on this, by the way -- it's well > documented, and I had my widget up and running in about 10 minutes. Thanks. Glad to hear it was useful. > Anyway, I'd like to have my widget come up with a custom background > pixmap made from some bitmap data I have. ... > Should I make my own RealizeProc? Yes, the realize procedure is the appropriate place to put one-time resource creation of this type. The initialize procedure could be used as well and it's almost a toss-up, but delaying until realize allows for the possibility that a client may change some resource data (via XtSetValues, for example) upon which your created resources depend. Section 2.5 of 'X Toolkit Intrinsics - C Language Interface' is the place to read about realize procedures.