Newsgroups: comp.windows.x.motif Path: utzoo!utgpu!watserv1!watdragon!watsol.waterloo.edu!tbray From: tbray@watsol.waterloo.edu (Tim Bray) Subject: Re: Help on Context Message-ID: <1991Jan9.022453.25217@watdragon.waterloo.edu> Sender: daemon@watdragon.waterloo.edu (Owner of Many System Processes) Organization: University of Waterloo References: <1991Jan8.150413.10965@hellgate.utah.edu> Date: Wed, 9 Jan 91 02:24:53 GMT Lines: 19 wtm%gr.utah.edu@cs.utah.edu (Thomas McCollough) writes: >I am interested in implementing Help on Context as >described in section 8.1.1 of the Style Manual. > >What would be the most straight-forward way of programming this >functionality? I am using version 1.0. Not sure this is optimal, but it works: 1. Immediately stop using Motif 1.0, go to 1.1. 2. Grab the pointer via XGrabPointer from the topmost window, also changing and confining the cursor - one call does it all. 3. Wait for the next ButtonPress with XMaskEvent. 4. Figure out which user-perceived application component the ButtonPress happened in. (HIGHLY application-dependent) 5. Ungrab the pointer. 6. Provide help for the appropriate component. Cheers, Tim Bray, tbray@watsol.waterloo.edu