usp10: Display the blank glyph for some control characters (truetype/opentype).

This commit is contained in:
Akihiro Sagawa 2015-08-12 00:54:39 +09:00 committed by Alexandre Julliard
parent 311fce671d
commit 22e8046fcb
2 changed files with 5 additions and 2 deletions

View File

@ -950,7 +950,10 @@ static void ContextualShape_Control(HDC hdc, ScriptCache *psc, SCRIPT_ANALYSIS *
{ {
switch (pwcChars[i]) switch (pwcChars[i])
{ {
case 0x000D: pwOutGlyphs[i] = psc->sfp.wgBlank; break; case 0x000A:
case 0x000D:
pwOutGlyphs[i] = psc->sfp.wgBlank;
break;
default: default:
if (pwcChars[i] < 0x1C) if (pwcChars[i] < 0x1C)
pwOutGlyphs[i] = psc->sfp.wgDefault; pwOutGlyphs[i] = psc->sfp.wgDefault;

View File

@ -1486,7 +1486,7 @@ static void test_ScriptShape(HDC hdc)
hr = ScriptShape(hdc, &sc, &blanks[j], 1, 1, &items[0].a, glyphs2, logclust, attrs, &nb); hr = ScriptShape(hdc, &sc, &blanks[j], 1, 1, &items[0].a, glyphs2, logclust, attrs, &nb);
ok(hr == S_OK, "%s: [%02x] expected S_OK, got %08x\n", lf.lfFaceName, blanks[j], hr); ok(hr == S_OK, "%s: [%02x] expected S_OK, got %08x\n", lf.lfFaceName, blanks[j], hr);
ok(nb == 1, "%s: [%02x] expected 1, got %d\n", lf.lfFaceName, blanks[j], nb); ok(nb == 1, "%s: [%02x] expected 1, got %d\n", lf.lfFaceName, blanks[j], nb);
if (i == 0 && blanks[j] != '\n') if (i == 0)
ok(glyphs[0] == glyphs2[0] || ok(glyphs[0] == glyphs2[0] ||
broken(glyphs2[0] == blanks[j] && (blanks[j] < 0x10)), broken(glyphs2[0] == blanks[j] && (blanks[j] < 0x10)),
"%s: [%02x] expected %04x, got %04x\n", lf.lfFaceName, blanks[j], glyphs[0], glyphs2[0]); "%s: [%02x] expected %04x, got %04x\n", lf.lfFaceName, blanks[j], glyphs[0], glyphs2[0]);