[Tutor] How to interact with the result of subprocess.call()

Alan Gauld alan.gauld at yahoo.co.uk
Sun Dec 25 04:08:39 EST 2016


On 25/12/16 01:58, boB Stepp wrote:

> the stdin option of call()might be used to direct the desired
> keystrokes to LO?  After looking at

The problem is that keystrokes in a GUI are not read from
stdin, they are read as events from the GUI event loop.
So, if LO was a CLI tool (like vim or top, say) then you
are right, you could pipe the keystrokes through stdin,
but in a GUI those keystrokes would never be seen (or
if seen do something very different to what is expected)

-- 
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.amazon.com/author/alan_gauld
Follow my photo-blog on Flickr at:
http://www.flickr.com/photos/alangauldphotos




More information about the Tutor mailing list