wxpython - wxtoolbar font size

G

Ghido

Hi all i want to set wx.toolbar font size and i use this code:

self.tb1 = wx.ToolBar(self, -1, style=wx.TB_HORIZONTAL|
wx.TB_TEXT)
self.tb1.SetFont(wx.Font(9, wx.DEFAULT, wx.NORMAL,0))
self.SetToolBar(self.tb1)

but i obtain nothing. Is possibile? where i wrong?
I use wxpython 2.6.3 on ubuntu edgy
thanks

Ghido
 
F

Frank Niessink

Ghido:
Hi all i want to set wx.toolbar font size and i use this code:

self.tb1 = wx.ToolBar(self, -1, style=wx.TB_HORIZONTAL|
wx.TB_TEXT)
self.tb1.SetFont(wx.Font(9, wx.DEFAULT, wx.NORMAL,0))
self.SetToolBar(self.tb1)

but i obtain nothing. Is possibile? where i wrong?
I use wxpython 2.6.3 on ubuntu edgy

You need to call self.tb1.Realize(). BTW, you probably want to add some
tools to the toolbar too. See attachment.

Cheers, Frank
 
G

Ghido

Thanks for your reply but i can't change the font of 'New' label. but
it is a linux problem or is a wxpython problem?

Ghido
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,431
Messages
2,571,678
Members
48,796
Latest member
Greg L.

Latest Threads

Top