Path: utzoo!attcan!uunet!lll-winken!ncis.llnl.gov!helios.ee.lbl.gov!pasteur!ucbvax!decwrl!hplabs!hp-pcd!hpcvlx!ben From: ben@hpcvlx.HP.COM (Benjamin Ellsworth) Newsgroups: comp.windows.x Subject: Re: Widgets and Xlib Message-ID: <100920039@hpcvlx.HP.COM> Date: 20 Jan 89 01:51:15 GMT References: <33500005@iuvax> Organization: Hewlett-Packard Co., Corvallis, OR, USA Lines: 22 I'm in a hurry, so this is going to be terse. XtGetGC is entirely wrong. Get the window, display, etc. of the widget and create your own GC with regular Xlib calls. Then draw using that GC, and the widget's window, display, etc. You should have no trouble getting stuff on the screen. You will have trouble if you generate an exposure event in the widget's window. The widget may overwrite your pretty drawings. Good Luck! ----------------------------------------------------------------------- Benjamin Ellsworth | ben%hpcvlx@hplabs.hp.com | INTERNET Hewlett-Packard Company | {backbone}!hplabs!hpcvlx!ben | UUCP 1000 N.E. Circle | (USA) (503) 750-4980 | FAX Corvallis, OR 97330 | (USA) (503) 757-2000 | VOICE ----------------------------------------------------------------------- All relevant disclaimers apply. -----------------------------------------------------------------------