Commit 57a34227 authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

dwrite: Enable DWRITE_INFORMATIONAL_STRING_WEIGHT_STRETCH_STYLE_FAMILY_NAME for…

dwrite: Enable DWRITE_INFORMATIONAL_STRING_WEIGHT_STRETCH_STYLE_FAMILY_NAME for GetInformationalStrings(). Signed-off-by: 's avatarNikolay Sivov <nsivov@codeweavers.com> Signed-off-by: 's avatarAlexandre Julliard <julliard@winehq.org>
parent 6b0e68f2
...@@ -231,7 +231,7 @@ struct dwrite_fontface ...@@ -231,7 +231,7 @@ struct dwrite_fontface
FONTSIGNATURE fontsig; FONTSIGNATURE fontsig;
UINT32 glyph_image_formats; UINT32 glyph_image_formats;
IDWriteLocalizedStrings *info_strings[DWRITE_INFORMATIONAL_STRING_POSTSCRIPT_CID_NAME+1]; IDWriteLocalizedStrings *info_strings[DWRITE_INFORMATIONAL_STRING_WEIGHT_STRETCH_STYLE_FAMILY_NAME + 1];
IDWriteLocalizedStrings *family_names; IDWriteLocalizedStrings *family_names;
IDWriteLocalizedStrings *names; IDWriteLocalizedStrings *names;
......
...@@ -82,7 +82,7 @@ struct dwrite_font_data ...@@ -82,7 +82,7 @@ struct dwrite_font_data
struct dwrite_font_propvec propvec; struct dwrite_font_propvec propvec;
DWRITE_FONT_METRICS1 metrics; DWRITE_FONT_METRICS1 metrics;
IDWriteLocalizedStrings *info_strings[DWRITE_INFORMATIONAL_STRING_POSTSCRIPT_CID_NAME+1]; IDWriteLocalizedStrings *info_strings[DWRITE_INFORMATIONAL_STRING_WEIGHT_STRETCH_STYLE_FAMILY_NAME + 1];
IDWriteLocalizedStrings *family_names; IDWriteLocalizedStrings *family_names;
IDWriteLocalizedStrings *names; IDWriteLocalizedStrings *names;
...@@ -1291,8 +1291,11 @@ static HRESULT get_font_info_strings(const struct file_stream_desc *stream_desc, ...@@ -1291,8 +1291,11 @@ static HRESULT get_font_info_strings(const struct file_stream_desc *stream_desc,
*exists = FALSE; *exists = FALSE;
*ret = NULL; *ret = NULL;
if (stringid > DWRITE_INFORMATIONAL_STRING_POSTSCRIPT_CID_NAME || stringid == DWRITE_INFORMATIONAL_STRING_NONE) if (stringid > DWRITE_INFORMATIONAL_STRING_WEIGHT_STRETCH_STYLE_FAMILY_NAME
|| stringid == DWRITE_INFORMATIONAL_STRING_NONE)
{
return S_OK; return S_OK;
}
if (!strings_cache[stringid]) if (!strings_cache[stringid])
{ {
...@@ -1301,7 +1304,7 @@ static HRESULT get_font_info_strings(const struct file_stream_desc *stream_desc, ...@@ -1301,7 +1304,7 @@ static HRESULT get_font_info_strings(const struct file_stream_desc *stream_desc,
if (!desc.stream) if (!desc.stream)
hr = get_filestream_from_file(file, &desc.stream); hr = get_filestream_from_file(file, &desc.stream);
if (SUCCEEDED(hr)) if (SUCCEEDED(hr))
hr = opentype_get_font_info_strings(&desc, stringid, &strings_cache[stringid]); opentype_get_font_info_strings(&desc, stringid, &strings_cache[stringid]);
if (!stream_desc->stream && desc.stream) if (!stream_desc->stream && desc.stream)
IDWriteFontFileStream_Release(desc.stream); IDWriteFontFileStream_Release(desc.stream);
......
...@@ -1098,7 +1098,7 @@ enum OPENTYPE_STRING_ID ...@@ -1098,7 +1098,7 @@ enum OPENTYPE_STRING_ID
OPENTYPE_STRING_WWS_SUBFAMILY_NAME OPENTYPE_STRING_WWS_SUBFAMILY_NAME
}; };
static const UINT16 dwriteid_to_opentypeid[DWRITE_INFORMATIONAL_STRING_POSTSCRIPT_CID_NAME+1] = static const UINT16 dwriteid_to_opentypeid[DWRITE_INFORMATIONAL_STRING_WEIGHT_STRETCH_STYLE_FAMILY_NAME + 1] =
{ {
(UINT16)-1, /* DWRITE_INFORMATIONAL_STRING_NONE is not used */ (UINT16)-1, /* DWRITE_INFORMATIONAL_STRING_NONE is not used */
OPENTYPE_STRING_COPYRIGHT_NOTICE, OPENTYPE_STRING_COPYRIGHT_NOTICE,
...@@ -1118,7 +1118,8 @@ static const UINT16 dwriteid_to_opentypeid[DWRITE_INFORMATIONAL_STRING_POSTSCRIP ...@@ -1118,7 +1118,8 @@ static const UINT16 dwriteid_to_opentypeid[DWRITE_INFORMATIONAL_STRING_POSTSCRIP
OPENTYPE_STRING_SAMPLE_TEXT, OPENTYPE_STRING_SAMPLE_TEXT,
OPENTYPE_STRING_FULL_FONTNAME, OPENTYPE_STRING_FULL_FONTNAME,
OPENTYPE_STRING_POSTSCRIPT_FONTNAME, OPENTYPE_STRING_POSTSCRIPT_FONTNAME,
OPENTYPE_STRING_POSTSCRIPT_CID_NAME OPENTYPE_STRING_POSTSCRIPT_CID_NAME,
OPENTYPE_STRING_WWS_FAMILY_NAME,
}; };
/* CPAL table */ /* CPAL table */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment