summaryrefslogtreecommitdiff
path: root/pango/pangocoretext-fontmap.c
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2019-08-13 23:15:00 -0400
committerMatthias Clasen <mclasen@redhat.com>2019-10-31 19:52:36 -0400
commita582dbbb60da8aff7574d576cc636799e89c72d8 (patch)
tree9091d5652eafbf00bd15a8cd62d3027a9880740f /pango/pangocoretext-fontmap.c
parent40a805478dfa8988315fd8b7f8515af65c3f90c7 (diff)
downloadpango-a582dbbb60da8aff7574d576cc636799e89c72d8.tar.gz
Add pango_font_get_face
Since we've run out of slots in PangoFontClass, this is implemented with a vfunc in PangoFontMapClass.
Diffstat (limited to 'pango/pangocoretext-fontmap.c')
-rw-r--r--pango/pangocoretext-fontmap.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/pango/pangocoretext-fontmap.c b/pango/pangocoretext-fontmap.c
index b3d9d71c..5a81e388 100644
--- a/pango/pangocoretext-fontmap.c
+++ b/pango/pangocoretext-fontmap.c
@@ -1511,6 +1511,15 @@ pango_core_text_font_map_init (PangoCoreTextFontMap *ctfontmap)
}
}
+static PangoFontFace *
+pango_core_text_font_map_get_face (PangoFontMap *fontmap,
+ PangoFont *font)
+{
+ PangoCoreTextFont *cfont = PANGO_CORE_TEXT_FONT (font);
+
+ return PANGO_FONT_FACE (_pango_core_text_font_get_face (cfont));
+}
+
static void
pango_core_text_font_map_class_init (PangoCoreTextFontMapClass *class)
{
@@ -1525,6 +1534,7 @@ pango_core_text_font_map_class_init (PangoCoreTextFontMapClass *class)
fontmap_class->shape_engine_type = PANGO_RENDER_TYPE_CORE_TEXT;
fontmap_class->get_serial = pango_core_text_font_map_get_serial;
fontmap_class->changed = pango_core_text_font_map_changed;
+ fontmap_class->get_face = pango_core_text_font_map_get_face;
}
/*