diff options
author | Matthias Clasen <mclasen@redhat.com> | 2021-08-30 16:28:43 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2021-08-31 07:50:18 -0400 |
commit | 4f13d4f4b5bc15d84b55464c69d2b62b4d749a65 (patch) | |
tree | e867a73006eb965c0cdaf84dabffad96de9cfdb0 /pango/pangocoretext.c | |
parent | 75bb4625c400979981f16377b9ae7dfaad540bd3 (diff) | |
download | pango-4f13d4f4b5bc15d84b55464c69d2b62b4d749a65.tar.gz |
coretext: Set size on font descriptions
Set a size on the font description returned by
pango_font_describe(). Otherwise, scaling it
doesn't work.
Fixes: #610
Diffstat (limited to 'pango/pangocoretext.c')
-rw-r--r-- | pango/pangocoretext.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/pango/pangocoretext.c b/pango/pangocoretext.c index ccb3f674..25358cac 100644 --- a/pango/pangocoretext.c +++ b/pango/pangocoretext.c @@ -64,10 +64,13 @@ pango_core_text_font_describe (PangoFont *font) PangoCoreTextFont *ctfont = (PangoCoreTextFont *)font; PangoCoreTextFontPrivate *priv = ctfont->priv; CTFontDescriptorRef ctfontdesc; + PangoFontDescription *desc; - ctfontdesc = pango_core_text_font_key_get_ctfontdescriptor (priv->key); + ctfontdesc = CTFontCopyFontDescriptor (priv->font_ref); + desc = _pango_core_text_font_description_from_ct_font_descriptor (ctfontdesc); + CFRelease (ctfontdesc); - return _pango_core_text_font_description_from_ct_font_descriptor (ctfontdesc); + return desc; } static PangoCoverage * |