[pygtk] Need help with spawn_async and callback
Robert Schroll
rschroll at gmail.com
Tue Jul 27 08:02:29 WST 2010
On 07/25/2010 08:46 PM, Tony Freeman wrote:
> In short: What do I need to do in order to get the text being generated
> by my child process to show up in the textview?
This doesn't answer your question, but have you considered running the
child inside a vte.Terminal? Faced with a similar problem, I created a
window containing a vte.Terminal and then used
vte.Terminal.fork_command() [1] to launch the child process. The
terminal will emit the 'child-exited' signal when the child exits (how
convenient!), at which point I hide the window. Hooking up the progress
bar might be more difficult in this case, though.
Good luck,
Robert
[1] As near as I can figure, fork_command() takes two arguments - the
first is the name of the command to run and the second is a list of
arguments. But the first element of this list must be the name of the
command to run. I'm sure a UNIX guru could explain why this is the only
obvious way to do things.
More information about the pygtk
mailing list