MATLAB: Control of arrow keys

arrow keys

I have a gui with next and back buttons that display successive graphs. Is there a way to enable the left/right arrow keys to control this as with the back/next buttons?

Best Answer

WindowKeyPressFcn at the figure level.
Caution: if zoom or pan are active then they take over control of key presses. A workaround for this exists though.
Related Question