How to tell whether a font is monospace using GTK and Pango?
Posted
by ptomato
on Stack Overflow
See other posts from Stack Overflow
or by ptomato
Published on 2010-04-25T12:16:50Z
Indexed on
2010/04/25
12:23 UTC
Read the original article
Hit count: 322
I have a PangoFontDescription
and I want to know whether it describes a monospace font.
I have seen the function pango_font_family_is_monospace()
in the Pango API documentation but after several hours of puzzling it is still not clear to me what the relationships are between PangoFontFamily
, PangoFontMap
, PangoFont
, PangoFontset
, PangoContext
, and PangoFontDescription
and whether I need any or all of these to achieve what I want. So far, PangoFontDescription
is the only part of Pango I've needed to use, as GTK manages to abstract everything else away.
Can anyone who has done this before help me out?
© Stack Overflow or respective owner