|
From: John H. <jdh...@ac...> - 2006-10-30 14:23:24
|
>>>>> "Gael" == Gael Varoquaux <gae...@no...> writes:
Gael> For those who have never used matlab, ginput is a blocking
Gael> call that takes one optional argument n, waits for n click
Gael> on the current figure, and returns the coordinates of those
Gael> n clicks. I have been trying to write such a function in
Gael> pylab and I can't find a solution.
blocking calls in pylab with gtk threading may be possible but it is
beyond my powers. I would write this with a callback, eg create a
class that takes a callback in the constructor and calls the callback
after n clicks with a list of n coords. blocking input calls may be
easier in tkagg. If there is a gtk/threading guru on hand, I'd be
interested if anyone has ideas on how to do this.
JDH
|