Run PyOs_InputHook in pager to keep plot windows interactive. #741

Closed
wants to merge 3 commits into from

1 participant

@efiring

This is implemented here only for posix platforms, but probably
could be generalized.

It has only one minor ill effect that I am aware of: upon exiting the pager, one must hit CR to get a prompt back. I have been unable to figure out why that is, or how to fix it, but it is a consequence of running the PyOs_InputHook, not of the change from popen to subprocess.Popen.

efiring added some commits Aug 27, 2011
@efiring efiring Run PyOs_InputHook in pager to keep plot windows interactive.
This is implemented here only for posix platforms, but probably
could be generalized.
1932aff
@efiring efiring page.page: use io.flush() to get the prompt back after running the pager 05fddd8
@efiring efiring page.page: code cleaned up, commented regarding remaining problem.
There are still major problems and puzzles regarding getting back
to the prompt, and a hangup with Tk.
6d483c8
@efiring

My second commit turned out to be no help at all; I was not testing it under the right circumstances, which is with an InputHook in place.
I'm closing the request now because although the need to hit CR to get back to the prompt is perhaps tolerable, the method is failing completely with Tk. I'm stumped.

@efiring efiring closed this Sep 5, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment