[Tutor] Need Help Modifying a wxPython GUI (scrolling display and logging)

Matt D md123 at nycap.rr.com
Mon Jun 3 16:01:14 CEST 2013


Hello,

I am using an open source wxPython GUI that I like very very much. I
have ideas about some modifications I need but I cannot be bothering the
author too much so I must learn some very specific things about Python
in order to make the modification myself.  First, I need some help
understanding the code behind this GUI.  From reading the comments I
understand that the part of the program written in C++ sends a Python
pickled dictionary to a msg_queue and when Python decodes the pickle the
TextCtrl fields (in the wxPython GUI I am using) receive/display the
appropriate values. And as new messages are received by Python the GUI
fields are cleared to display the new values.

For starters I would like the values to be displayed on the GUI in some
sort of a scrolling panel as they are cleared from the TextCtrl fields
so the user can watch recent activity.  I dont know what the best way to
do this would be; the wxpython.scrolledPanel widget?  I am unclear if
this can be put on the same GUI pane as the TextCtrl fields are and I am
unclear about if I can take the values from the TextCtrl fields or have
to use the pickle or what? I dont see any variables declared (like in
Visual Basic) so its not like I can just make a list and a textbox and
print it.

More importantly I need to save the values from the TextCtrl fields,
preferable in a CSV file, for later inspection.  From looking at the
Logging HOWTO and the Logging Cookbook I see there are alot of loggers
available, or ways to log, but they all look like they are orientated
towards exception handling and debugging so I am unsure what is the best
way to go about this; maybe wxLogTextCtrl ?  Utimately I need to log the
values from the TextCtrl fields in a row of comma separated values
adding a time/date stamp as one of the values.  I need this log so the
data can easily be worked on in excel or SAS.  I need the time/date
stamp for time series analysis.

I attached the code behind the wxPythoin GUI I am using.
Any help will be much appreciated.

Thanks in advance
-- 
Matt D
------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: op25_traffic_pane.py
Type: text/x-python
Size: 4967 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/tutor/attachments/20130603/fc1ed47e/attachment.py>


More information about the Tutor mailing list