summaryrefslogtreecommitdiff
path: root/vcl/unx/generic/glyphs/freetype_glyphcache.cxx
diff options
context:
space:
mode:
authorKhaled Hosny <khaledhosny@eglug.org>2019-08-27 15:19:15 +0200
committerKhaled Hosny <khaledhosny@eglug.org>2019-09-03 23:48:17 +0200
commitdcf7792da2aa2a1ef774a124f7b21f68fff0fd15 (patch)
tree1ef613fdde043fe142a2a4e3bdcbbc03c0577bd2 /vcl/unx/generic/glyphs/freetype_glyphcache.cxx
parente44db461ca135fcbef7854c7304c894b65fcd497 (diff)
Make Noto Color Emoji font work on Linux
Noto Color Emoji is a bitmap color font, Cairo knows how to scale such fonts and FontConfig will identify them as scalable but not outline fonts, so change the FontConfig checks to checks for scalability. Make sft.cxx:doOpenTTFont() accept non-outline fonts, the text will not show in PDF but that is not worse than the status quo. Change-Id: I756c718296d2c43e3165cd2f07b11bbb981318d3 Reviewed-on: https://gerrit.libreoffice.org/78218 Tested-by: Jenkins Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
Diffstat (limited to 'vcl/unx/generic/glyphs/freetype_glyphcache.cxx')
-rw-r--r--vcl/unx/generic/glyphs/freetype_glyphcache.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/vcl/unx/generic/glyphs/freetype_glyphcache.cxx b/vcl/unx/generic/glyphs/freetype_glyphcache.cxx
index 9c0773e6a340..1b3532ceee1b 100644
--- a/vcl/unx/generic/glyphs/freetype_glyphcache.cxx
+++ b/vcl/unx/generic/glyphs/freetype_glyphcache.cxx
@@ -436,9 +436,9 @@ FreetypeFont::FreetypeFont(LogicalFontInstance* pFontInstance, FreetypeFontInfo*
FT_New_Size( maFaceFT, &maSizeFT );
FT_Activate_Size( maSizeFT );
- FT_Error rc = FT_Set_Pixel_Sizes( maFaceFT, mnWidth, rFSD.mnHeight );
- if( rc != FT_Err_Ok )
- return;
+ /* This might fail for color bitmap fonts, but that is fine since we will
+ * not need any glyph data from FreeType in this case */
+ /*FT_Error rc = */ FT_Set_Pixel_Sizes( maFaceFT, mnWidth, rFSD.mnHeight );
FT_Select_Charmap(maFaceFT, FT_ENCODING_UNICODE);