LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Access to Cursor Right-click Menu

I am working with cursors on a project for a collaborator.  My possibly impossible goal is when a mouse is hovering over an existing cursor in the graph itself, a right-click would bring up cursor right-click menu there instead of having to use the cursor legend to modify the cursor (more to allow user to change attrributes).

 

rpursley8_0-1763567875275.png

 

I already have code that will not bring up a modified Runtime Shortcut Menu for a waveform graph when hovering over a cursor in the graph (identifying cursor locations and discarding the mouse click), but I don't know how to get the above menu to save off and/or edit.  Is it located anywhere that I can access it (as a .rtm file maybe)?  There is no option for editing this Runtime Shortcut Menu for that menu.  it is such a nicely designed menu that I want to use it if possible.

 

 

Thanks,

 

Randy

 

 

Randall Pursley
0 Kudos
Message 1 of 2
(111 Views)

Here are a couple of options. I haven't really tested them:

  1. Easy but potentially cursed option: Use scripting to create a property node to the legend (it's not accessible in the UI, but it is a tree control and it is possible). Then on a Mouse Down? event move it so that it's below the cursor (inside the event case), so that it gets the click. You will need to manage the position, hiding, etc., but you get the menu for free. See attached.
  2. Use the Shortcut Menu Activation? event, check the coordinates to see how close you are to a cursor and build the menu yourself, including implementing the functionality using the property nodes. I assume all the relevant properties exist, but I haven't checked.

___________________
Try to take over the world!
0 Kudos
Message 2 of 2
(57 Views)