Linking events in skimage.viewer
Steven Silvester
steven.silvester at gmail.com
Sun Dec 22 18:10:32 EST 2013
Nadav,
The canvas itself is a matplotlib.backends.backend_qt4agg.FigureCanvasQTAgg.
If you wanted, you could subclass that class and provide your own
mousePressEvent and friends. Something like:
from matplotlib.backends.backend_qt4agg import FigureCanvasQTAggimport matplotlib.pyplot as pltfrom skimage import data
class MyCanvas(FigureCanvasQtAgg):
def mousePressEvent(self, event):
pass
def main():
image = data.camera()
f, ax = plt.subplots()
f.canvas = MyCanvas()
ax.imshow(image, interpolation='nearest')
h, w = image.shape
plt.show()
On Wednesday, December 18, 2013 2:13:02 AM UTC-6, Nadav Horesh wrote:
I
> I started to build an interactive image exploration utility based on
> matplotlib. Recently, following a link on this list, I encountered
> skimage.viewer, and found that the plugins architecture matches my needs.
> I could not find how to link keyboard and mouse events (and maybe buttons)
> to plugins. Any suggestions?
>
> I am using version 0.93 on linux (I can install the pre 0.10, if needed)
>
> Thanks,
>
> Nadav
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/scikit-image/attachments/20131222/24bf9873/attachment.html>
More information about the scikit-image
mailing list