wxPython on Debian Linux unstable (sid). fonts issue.

I am trying to fix up the fonts which are quite ugly by default right now on my Debian-unstable (sid) box, which has wxgtk, and wxgtk-python installed on it, from 'unstable'. my gnome/gtk stuff is all 2.x, but the fonts in wxPython still look like somebody beat them with the ugly stick, and it doesn't seem to pick up the configuration of fonts that I specified in gnome-control-center, also, interestingly, I get this output, when I run the simple.py (or anything else) using wxPython, these errors appear on the console...

The font "-cronyx-helvetica-medium-r-normal-*-17-*-*-*-p-*-koi8-r" does not support all the required character sets for the current locale "C"
  (Missing character set "ISO8859-1")

(It repeats this error 3 times, then the wx gui appears.)

Where is it picking the fonts configuration from, and how can I get them to look nicer? Interestingly gtk-config --version reports 1.2.10, whereas gnome-control-center is 2.2.2. Methinks, I might be mistook here, but is wxPython on Linux essentially stuck with gnome 1.x era capabilities? Can I get nice fonts? How?

Regards,

Warren Postma

Hi
How do I reference the instance of the main frame that is created when
the app starts?
Regards,
Greg

Try this (untested):

myapp = wx.GetApp()
mf = myapp.GetTopWindow() # this may be the method call you need

···

--- Greg Binns <gregbin@bigpond.net.au> wrote:

Hi
How do I reference the instance of the main frame that is created
when the app starts?
Regards,
Greg

=====
Donnal Walter
Arkansas Children's Hospital

Ok, now tested. Watch the frame title as you click the button:

···

--- Donnal Walter <donnalcwalter@yahoo.com> wrote:

--- Greg Binns <gregbin@bigpond.net.au> wrote:
>
> Hi
> How do I reference the instance of the main frame that is
> created when the app starts?
> Regards,
> Greg
>

Try this (untested):

myapp = wx.GetApp()
mf = myapp.GetTopWindow()

==================================================================
#!/usr/bin/env python
from wxPython.wx import *

class MyFrame(wxFrame):
    def __init__(self):
        wxFrame.__init__(self, None, -1,
                         'Frame title BEFORE button click',
                         size=(300, 200))
        abutton = wxButton(parent=self, id=-1,
                           label= 'Click to change title')
        EVT_BUTTON(self, abutton.GetId(), self.OnClick)

    def OnClick(self, event):
        myapp = wxGetApp() # get application
        tf = myapp.GetTopWindow() # get top frame
        tf.SetTitle('Top frame title changed') # change its title

class MyApp(wxApp):
    def OnInit(self):
        frame = MyFrame()
        frame.Show(1)
        return 1

app = MyApp(0)
app.MainLoop()

=====
Donnal Walter
Arkansas Children's Hospital

Hi
Is it possible and if so how do I set the width of the leftmost fixed
column of a grid?
Regards
Greg

Greg Binns wrote:

Hi
Is it possible and if so how do I set the width of the leftmost fixed
column of a grid?

Do you mean the row labels? If so then it's SetRowLabelSize.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!