Disabling Cntrl+Left Click = Right Click
Mostrar comentarios más antiguos
Apparently Matlab evaluates the following events as identical (within a callback function designed to handle mouse buttondown events):
Control + Left click => 'alt'
Right click => 'alt'
They are indistinguishable. Is there any way to have the following operation instead:
Control + Left click = 'normal', just with a control modifier on the figure
Right click = 'alt'?
Thank you!
Respuestas (1)
Robert Cumming
el 28 de Jul. de 2014
0 votos
You can use the keypressfcn to register if ctrl is pressed and modify your call back in. I'd mouse button
2 comentarios
Stephen
el 28 de Jul. de 2014
Robert Cumming
el 28 de Jul. de 2014
I'm not near a copy of Matlab just now, but you should be able to use the keypressfcn to register if a key is pressed. Link that with your mouse call back to distinguish the difference between the two modes.
Categorías
Más información sobre Interactive Control and Callbacks en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!