Sign in to follow this  
ajm113

I need help with tabs! -Python-

Recommended Posts

ajm113    355
Ok, I am working on tabs for my program and I have been looking on the wxPython example programs and I looked at the create a tab. So I got rid of the textarea in my program and added it but I get errors! Code to create the tab:
         def OnNew(self,  event):
                    frame = wx.GetApp().CreateDocumentFrame(self, doc)
                    sizer = wx.BoxSizer()
                    font, color = self._GetFontAndColorFromConfig()
                    self.control = self._BuildTextCtrl(frame, font, color = color)
                    self._textCtrl.Bind(wx.EVT_TEXT, self.OnModify)
                    sizer.Add(self._textCtrl, 1, wx.EXPAND, 0)
                    frame.SetSizer(sizer)
                    frame.Layout()
                    frame.Show(True)
                    self.Activate()
                    return True

[Edit: use [source] to format Python code - Oluseyi] Any help on creating or helping me with making tabs?

Share this post


Link to post
Share on other sites
Oluseyi    2116
Quote:
Original post by ajm113
Any help on creating or helping me with making tabs?

First and foremost, when seeking help online, always try to provide as much information as possible It makes it easier for people to figure out your problem, and thus suggest fixes. For example:

Quote:
I ... added it but I get errors!

What errors, specifically?

Quote:
So I got rid of the textarea in my program and added it...

Can we see the code?

Share this post


Link to post
Share on other sites
ajm113    355
Sorry for double posting, but doesn't anyone know wxPython here or am I asking on the wrong site?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this