dwrite: Fix font stretch name conversion table.
Sebastian Lackner
sebastian at fds-team.de
Fri Aug 12 22:35:59 CDT 2016
Signed-off-by: Sebastian Lackner <sebastian at fds-team.de>
---
For https://bugs.winehq.org/show_bug.cgi?id=41132.
dlls/dwrite/font.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/dlls/dwrite/font.c b/dlls/dwrite/font.c
index d354eaf..c5fc11e 100644
--- a/dlls/dwrite/font.c
+++ b/dlls/dwrite/font.c
@@ -3097,7 +3097,8 @@ static BOOL font_apply_differentiation_rules(struct dwrite_font_data *font, WCHA
if (stretch_name.ptr)
font_name_token_to_str(&stretch_name, stretchW);
/* ignore normal stretch */
- else if (font->stretch == DWRITE_FONT_STRETCH_NORMAL)
+ else if (font->stretch == DWRITE_FONT_STRETCH_UNDEFINED ||
+ font->stretch == DWRITE_FONT_STRETCH_NORMAL)
stretchW[0] = 0;
/* use predefined stretch names */
else {
@@ -3109,6 +3110,7 @@ static BOOL font_apply_differentiation_rules(struct dwrite_font_data *font, WCHA
static const WCHAR ultraexpandedW[] = {'U','l','t','r','a',' ','E','x','p','a','n','d','e','d',0};
static const WCHAR *stretchnamesW[] = {
+ NULL, /* DWRITE_FONT_STRETCH_UNDEFINED */
ultracondensedW,
extracondensedW,
condensedW,
--
2.9.0
More information about the wine-patches
mailing list