[comp.windows.x.motif] XmNmenuPost

jmr1g@birch.cs.Virginia.EDU (Jeremiah M. Ratner) (06/13/91)

Motif gurus,

Pretty simple question:

I am popping up a popup menu in a widget, but i want to pop it up with the left,
not the right mouse button.  The documentation says to change the resource
XmNmenuPost to do this, but it is unclear how, or what type XmNmenuPost expects.
Has anyone done this? How?

Thanks,

jerry ratner  (jerry@trident.datasys.swri.edu)

achan@sparkle.tdd.sj.nec.com (Amy Chan) (06/13/91)

In article <1991Jun13.133350.11247@murdoch.acc.Virginia.EDU> jmr1g@birch.cs.Virginia.EDU (Jeremiah M. Ratner) writes:
>
>Motif gurus,
>
>Pretty simple question:
>
>I am popping up a popup menu in a widget, but i want to pop it up with the left,
>not the right mouse button.  The documentation says to change the resource
>XmNmenuPost to do this, but it is unclear how, or what type XmNmenuPost expects.

From Motif 1.1 Programmer's Reference:
    XmNmenuPost expects type String.

    XmNmenuPost
        Specifies an X event description indicating an event that posts a menu 
        system ....

You will specify this resource to pop up a menu with the left mouse button in   
UIL as:

    object
        someMenu : XmPopupMenu {
            arguments {
                XmNmenuPost = "<Btn1Down>";
            };
            ........


Hope this helps.

--
Amy Chan                 | E-Mail:
NEC America              |  INET: achan@tdd.sj.nec.com
110 Rio Robles           |  UUCP: ...{decwrl,oliveb}!necsun!achan
San Jose, CA 95134       |