embedding python in wxpython

Joe Strout joe at strout.net
Tue Dec 30 22:55:24 CET 2008


Steve Holden wrote:

>> I'd like the console to be a bidirectional representation of what's
>> going on in the gui, plus a general purpose evaluation environment
>> where you can manipulate application data via some api which is
>> automatically exposed to the console when the application opens up.
>>
>> I'm looking for high-level hints/strategies/directions.
>>
> I seem to remember you can create your wxApp with an argument of True or
> False. One of those settings creates a window containing any output to
> sys.stderr, if I remember rightly.

You do -- True (the default) redirects standard output to a window, 
while False does not redirect it.

However, neither setting will create a bidirectional console or 
evaluation environment as the OP was asking for.  (But other wx widgets 
do provide that, as other replies have pointed out.)

Best,
- Joe





More information about the Python-list mailing list