From: Kevin A. <al...@se...> - 2004-08-12 17:28:58
|
On Aug 12, 2004, at 9:45 AM, Bartosz Wilczy=A8=BDski wrote: > Thanks for your quick response, > > If I understand You correctly, I should, in a way, wrap my whole=20 > wxPython > Application in a non visible PythonCard App, > but it brings me to another question : > > How do I start my wxPython App as a child window of PythonCardApp ? > > Thanks again for your help (and for PythonCard in general :) > --=20 > Bartek Wilczynski > You won't be able to start another wx.App instance. Instead you'll just=20= move whatever app initialization you need and make your own wx.Frames=20 child windows of the main PythonCard background which can be created=20 during the openBackground event handler. For example, here's a simple=20 addition to the minimal sample using PythonCard 0.7.3.1 syntax. import wx class Minimal(model.Background): def on_openBackground(self, event): self.rawWx =3D wx.Frame(self, -1, 'plain wxPython window',=20 pos=3D(100, 30), size=3D(200, 100)) self.rawWx.Show() =00 You could subclass model.PythonCardApp, call its __init__ as part of=20 your __init__ and then do the rest of your initialization there. ka |