Make distance fields rendering work with Opentype CFF fonts
authorEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
Fri, 21 Dec 2012 14:23:28 +0000 (19:53 +0530)
committerAshish Kulkarni <kulkarni.ashish@gmail.com>
Sat, 13 Dec 2014 17:28:39 +0000 (18:28 +0100)
commit19f8b8ebc144555f53f69d8a0230d24a91384454
tree4573db7e66b5b99d991337ccd4b7f2ccaa1ff681
parent3985dfb6e6c7fd89ebbccc9a238fe02169e0cbc0
Make distance fields rendering work with Opentype CFF fonts

If the font has a CFF table, GDI will not label it as
TMPF_TRUETYPE, however, we can still use GetFontData to get
the SFNT tables. This is required to get the maxp table which
contains the glyph count, which is required to use the font
with the distance-field renderer.

Task-number: QTBUG-28746
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Change-Id: I1e084f7e9dbd0bccb9b1ff4de2eaf65d6a5f9f1e
(cherry picked from qtbase/dde09c429ae8b7ad0df4e4b36b8459d2b85a1219)
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
src/gui/text/qfontengine_win.cpp
src/gui/text/qfontengine_win_p.h