Determining whether a glyph is available in Tkinter
wmcbrine at gmail.com
wmcbrine at gmail.com
Thu Dec 19 18:10:58 EST 2013
On Monday, December 16, 2013 10:58:06 PM UTC-5, Terry Reedy wrote:
> I would not assume that the default covers more than ascii.
In this case, I already know that the glyphs I chose work with the default fonts for OS X 10.4+ and Windows 7+, but not for (for example) Win XP.
> But to answer your question, this might work: fonts have a measure()
> method that returns what the pixel length of a string would be if it
> were to be displayed.
Thanks. Unfortunately, measure() doesn't seem to do the trick -- it's giving me answers that look like normal single-width characters, for glyphs that actually render as \uNNNN. Oh well. :/
More information about the Python-list
mailing list