Problem with giant font sizes in tkinter
cjns1989 at gmail.com
Fri Feb 11 07:29:02 CET 2011
On Thu, Feb 10, 2011 at 09:08:01PM EST, Steven D'Aprano wrote:
> On Thu, 10 Feb 2011 15:48:47 +0000, Cousin Stanley wrote:
> > Steven D'Aprano wrote:
> >> I have a tkinter application under Python 2.6 which is shows text in a
> >> giant font, about twenty(?) times larger than expected.
> >> The fonts are set using:
> >> titlefont = '-Adobe-Helvetica-Bold-R-Normal-*-180-*'
> >> buttonfont = '-Adobe-Helvetica-Bold-R-Normal-*-140-*'
> >> labelfont = '-Adobe-Helvetica-Bold-R-Normal-*-140-*'
> >> ....
> > Although I've been a linux user for several years, that type of font
> > spec hurts my head .... :-)
> > Will the more simplistic type of tuple spec not work in your tkinter
> > application ?
> I don't know, but I'll give it a try.
> Nevertheless, I'd like to learn how to diagnose these sorts of font
> issues. Can anyone suggest where I should start?
First of all, you need to know precisely what the above font name coding
Chapter 6 of O'Reilly's ‘The X Window System's User Guide’, provides
a brief but fairly thorough introduction.
In relation to your problem, see in particular the discussion of the use
of wild cards and such aspects as pixel size and vertical/horizontal
You can download a scanned pdf of this book free of charge here:
More information about the Python-list