home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!haven.umd.edu!umd5!wls
- From: wls@astro.umd.edu (William L. Sebok)
- Newsgroups: comp.windows.x
- Subject: cursor in spring-loaded menu
- Message-ID: <14608@umd5.umd.edu>
- Date: 22 Jul 92 16:42:17 GMT
- Sender: news@umd5.umd.edu
- Organization: U. of Maryland @ College Park, Astronomy
- Lines: 19
-
- I have a menu widget which I have written intended to be used as a
- spring-loaded popup when a button is pressed (by means of an XtMenuPopup() in
- the translations). While the menu is popped up I would like the cursor to have
- some special shape. It seems to be hard to do this. Setting the default
- cursor on the widget does not do anything. Nor does setting the cursor with
- XDefineCursor() in the popup callback. The cursor always seems to be that of
- the widget that issued the grab. The XtMenuPopup action routine puts out a
- passive pointer grab (XGrabButton). XGrabButton specifies a cursor that is
- used during the grab. The code for this in the Intrinsics is hard for me to
- follow but it is not obvious to me how to have cursor have any other value but
- None. Perhaps I have to write my own action routine rather than XtMenuPopup()?
- Is there something I am missing? some way to get the grab to be issued with a
- particular cursor? I have solved it with a call to XChangeActivePointerGrab()
- in the popup callback which seems to be what the doctor ordered except that it
- wants a new event mask to be specified. I would want to use the same event mask
- as used in the original XGrabButton call but I have no easy way of knowing
- that. I have used a mask for all possible pointer events.
- --
- Bill Sebok Univ. of Maryland, Astronomy Internet: wls@astro.umd.edu
-