Reference 〉Function

ChartPlot.catchKeypress( matplotlib.KeyEvent event )

A method that can be overridden in subclasses to catch keypresses when the mouse is over a particular plot. This is distinct from functions passed to MPLVisualization.addKeypress(), as these will run for keys pressed any time the visualization window is in focus, regardless of the mouse position.

For example, pressing ‘l’ with the mouse over a NetworkPlot will rotate the network layout. The key pressed can be accessed with event.key.

This function should not be called by user code, but it may be defined in subclasses of ChartPlot.


Notes and Examples

  1. Contribute a Note

    Your email address will not be published. Required fields are marked *

    You may use limited HTML for formatting. Please embed blocks of code in <pre><code> </code></pre> tags.