Programmatically modifying user-drawn-shape?
Fri, 12/14/2018 - 12:00 pm
Working with Igor 220.127.116.11, I'm using DrawUserShape( ) to place 4 shapes in a Control Panel. I'm setting b1 of the options field (bitwise OR with 0x02) of each shape and then using the mouseUp action to detect when and where the user clicks on each shape. All works well until the user enlarges the control panel.
I can dynamically repaint the shapes to fit the enlarged control panel, but I can't seem to adjust the rectangular region over which each shape raises its mouseUp actions. I suspect I need to adjust that rectangular region each time I redraw at a new size, but so far I can't find any guidelines for doing this. Can anyone offer a suggestion?
Do I need to call DrawUserShape( ) again? If so, do I need to delete the old shape before re-calling DrawUserShape( )? Do I need to use drawing groups to indivdually address each of the 4 shapes? Can such steps be performed within the user-defined drawing function?
Thanks in advance for any help,