wxPython frame refresh

Discussion in 'Software' started by wolfbrigade, Sep 7, 2006.

  1. wolfbrigade

    wolfbrigade

    Joined:
    Sep 7, 2006
    Messages:
    1
    I know this might not be the correct thread to post in my apologies.
    I'm using python2.3 and the wxPython released version for the python2.3. I'm attempting to make an interface in which a user can manipulate multiple files with different windows. I'm having problems in which when the program is exicuted the main fram is never refreshed or not often enough. any ideas to the correct incantations to the machine god will work?

    following is my code in slimed down. thanks for any help you can send my way

    import wx
    from wxPython.wx import *

    ID_NEW_CHILD = 1

    textarea1 = wxTextCtrl
    multifileddisplay = wxListBox

    class BaseFrame(wxMDIParentFrame):
    def __init__(self, parent, ID, title):
    wxMDIParentFrame.__init__(self, parent, ID, title, wxPoint(500,300), wxSize(500, 500))#wxDefaultPosition replaced by wxPoint
    self.CreateStatusBar()
    self.SetStatusText("Status Bar")
    menu0 = wxMenu()
    menu0.Append(ID_NEW_CHILD,"New window","New editable window hopefully")
    menuBar = wxMenuBar()
    menuBar.Append(menu0, "File");

    multifileddisplay = wxListBox(self, -1, wxPoint(0,0), wxSize(100,200), ["1", "2","3", "4","5", "6","7", "8"], wxLB_SINGLE | wxLB_HSCROLL | wxLB_NEEDED_SB)

    self.SetMenuBar(menuBar)

    EVT_MENU(self,ID_NEW_CHILD, self.openNew)

    def openNew ( self, event ):
    # Create a child window
    child = wxMDIChildFrame ( self, -1, 'MDI Child' )
    # Give the child a panel
    child.panel = wxPanel ( child, -1 )
    child.panel.SetSize ( child.GetClientSize() )
    #Add a label
    #child.label = wxStaticText ( child, -1, filevalue)
    child.textarea = wxTextCtrl(child, -1, "",wxPoint(0, 0),wxSize(380,425),wxTE_MULTILINE)
    child.Show ( True )

    class MyApp(wxApp):
    def OnInit(self):
    frame = BaseFrame(NULL, -1, "Test Script of GUI funcutions")
    frame.Show(true)
    self.SetTopWindow(frame)
    return true

    app = MyApp(0)
    app.MainLoop()
     
    wolfbrigade, Sep 7, 2006
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?R2F6VUs=?=

    Remote Desktop Window Does Not Refresh When Roaming

    =?Utf-8?B?R2F6VUs=?=, Jul 7, 2005, in forum: Wireless Networking
    Replies:
    2
    Views:
    3,637
    =?Utf-8?B?R2F6VUs=?=
    Jul 11, 2005
  2. Mattyh

    Refresh

    Mattyh, Dec 4, 2003, in forum: Firefox
    Replies:
    3
    Views:
    605
    A Hess
    Dec 5, 2003
  3. wylbur37
    Replies:
    1
    Views:
    1,110
    Jukka Aho
    Nov 6, 2006
  4. Don and Liz Campbell

    1 Frame per second frame capture rate

    Don and Liz Campbell, Mar 24, 2005, in forum: Digital Photography
    Replies:
    4
    Views:
    368
  5. asprigoftrig

    view loaded clip frame-by-frame on PC?

    asprigoftrig, Dec 14, 2005, in forum: Digital Photography
    Replies:
    3
    Views:
    697
    asprigoftrig
    Dec 14, 2005
Loading...

Share This Page