aboutsummaryrefslogtreecommitdiff
path: root/font.h
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2019-08-10 18:34:22 +0000
committerDaniel Eklöf <daniel@ekloef.se>2019-08-10 18:34:22 +0000
commit92319d1570e712e3df23f9f623f17dc6e19b0c2a (patch)
tree2cb4bf3d3941f9ed0949adcd331e9a0eab091ad0 /font.h
parentselection: regression: last cell wasn't included in copied text (diff)
font: initial support for fontconfig font fallback
When we've exhausted our own fallback list, try the font list provided by fontconfig. This means, the user's fallback fonts have priority, but in case all of them fail, we hopefully get lucky with fontconfig...
Diffstat (limited to 'font.h')
-rw-r--r--font.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/font.h b/font.h
index 90a4b1dd..1450f5f9 100644
--- a/font.h
+++ b/font.h
@@ -6,6 +6,7 @@
#include <ft2build.h>
#include FT_FREETYPE_H
#include FT_LCD_FILTER_H
+#include <fontconfig/fontconfig.h>
#include <cairo.h>
#include "tllist.h"
@@ -28,6 +29,10 @@ struct glyph {
typedef tll(struct glyph) hash_entry_t;
struct font {
+ FcPattern *fc_pattern;
+ FcFontSet *fc_fonts;
+ int fc_idx;
+
FT_Face face;
int load_flags;
int render_flags;