summaryrefslogtreecommitdiff
path: root/pango/pangoft2-fontmap.c
diff options
context:
space:
mode:
authorOwen Taylor <otaylor@redhat.com>2002-01-11 20:09:58 +0000
committerOwen Taylor <otaylor@src.gnome.org>2002-01-11 20:09:58 +0000
commit2ac3d4c416d0d761b3012c6c4eebe3d00ad157a0 (patch)
tree7da962a13a562f61630a799a3f898846a32309ba /pango/pangoft2-fontmap.c
parent49c7df604e7b84310da42c9431ca96818d440b1b (diff)
downloadpango-2ac3d4c416d0d761b3012c6c4eebe3d00ad157a0.tar.gz
Split comma separated family names and add them in pieces, so they are all
Fri Jan 11 15:01:13 2002 Owen Taylor <otaylor@redhat.com> * pango/pangoft2-fontmap.c (pango_ft2_make_pattern) pango/pangoxft-fontmap.c (pango_xft_make_pattern): Split comma separated family names and add them in pieces, so they are all visible to Xft. * pango/pangoxft-fontmap.c: Remove duplicate XFT_FAMILY in call to XftListFonts.
Diffstat (limited to 'pango/pangoft2-fontmap.c')
-rw-r--r--pango/pangoft2-fontmap.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/pango/pangoft2-fontmap.c b/pango/pangoft2-fontmap.c
index 15efae0b..44b383b3 100644
--- a/pango/pangoft2-fontmap.c
+++ b/pango/pangoft2-fontmap.c
@@ -458,6 +458,8 @@ pango_ft2_make_pattern (const PangoFontDescription *description)
PangoStyle pango_style;
int slant;
int weight;
+ char **families;
+ int i;
pango_style = pango_font_description_get_style (description);
@@ -476,6 +478,13 @@ pango_ft2_make_pattern (const PangoFontDescription *description)
XFT_SIZE, MiniXftTypeDouble, (double)pango_font_description_get_size (description)/PANGO_SCALE,
NULL);
+ families = g_strsplit (pango_font_description_get_family (description), ",", -1);
+
+ for (i = 0; families[i]; i++)
+ MiniXftPatternAddString (pattern, XFT_FAMILY, families[i]);
+
+ g_strfreev (families);
+
return pattern;
}