Set the size of window : Frame : WxPython PYTHON TUTORIALS


PYTHON TUTORIALS » WxPython » Frame »

 

Set the size of window


Set the size of window
from wxPython.wx import *

def hello(event): print 'Hello, world!'
class MyApp(wxApp):
    def OnInit(self):
        win_id = wxNewId()
        win = wxFrame(NULL, win_id, 'Hello, wxPython!',
                      size=wxSize(200100))
        btn_id = wxNewId()
        btn = wxButton(win, btn_id, 'Hello')
        EVT_BUTTON(btn, btn_id, hello)
        win.Show(true)
        return true

app = MyApp()
app.MainLoop()



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


PYTHON TUTORIALS

 Navioo WxPython
» Frame