[wxpython-users] Re: Font for the demo sources
Robin Dunn
robin at alldunn.com
Thu May 1 17:34:44 PDT 2008
Mike Driscoll wrote:
> Mikhail wrote:
>> Mike Driscoll <mdriscoll <at> co.marshall.ia.us> writes:
>>
>>
>>>>
>>> If you don't want to do it programmatically, I'd recommend just
>>> holding CTRL and using your scroll wheel.
>>>
>>>
>>
>> Thanks, I always forget about this way, but I actually meant the
>> programmatic
>> way. The reason I'm asking is that when I change the default font size
>> in my
>> environment (KDE) then this change is propagated to the wxPython demo
>> application (as one would expect) except the font size in the "Demo
>> Code" panel.
>> I think it would be a good idea to make demo more 'well behaved app' :0)
>>
>>
>>
> Well, looking at the code (in Main.py of the Demo folder), it looks like
> the "Demo Code" panel uses the StyledTextCtrl_2 unless there's an import
> error at which it switches to using a standard TextCtrl. If you look at
> the demo for StyledTextCtrl_2, you'll notice that they set the size
> using the following (I think) on line 134:
>
> self.StyleSetSpec(stc.STC_STYLE_DEFAULT,
> "face:%(helv)s,size:%(size)d" % faces)
>
> I would think you could do the same. They continue using this command
> for quite a few lines after that too.
Also look at the faces dict further up the file.
--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!
More information about the wxpython-users
mailing list