Module: wine Branch: master Commit: 6fec9b1325e47a279554be54fbd964c5667f9816 URL: http://source.winehq.org/git/wine.git/?a=commit;h=6fec9b1325e47a279554be54fb...
Author: Henri Verbeet hverbeet@codeweavers.com Date: Sun Feb 19 19:02:33 2017 +0100
usp10: Return the logical offset in GPOS_apply_lookup().
Signed-off-by: Henri Verbeet hverbeet@codeweavers.com Signed-off-by: Aric Stewart aric@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/usp10/opentype.c | 8 ++++---- dlls/usp10/shape.c | 3 ++- 2 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/dlls/usp10/opentype.c b/dlls/usp10/opentype.c index 0cf474d..e3aaf16 100644 --- a/dlls/usp10/opentype.c +++ b/dlls/usp10/opentype.c @@ -2349,7 +2349,7 @@ static INT GPOS_apply_lookup(ScriptCache *psc, LPOUTLINETEXTMETRICW lpotm, LPLOG GPOS_convert_design_units_to_device(lpotm, lplogfont, advance[1].x, advance[1].y, &devX, &devY); piAdvance[glyph_index + write_dir] += round(devX); } - return glyph_index + index_offset; + return index_offset; }
case GPOS_LOOKUP_ATTACH_CURSIVE: @@ -2417,17 +2417,17 @@ static INT GPOS_apply_lookup(ScriptCache *psc, LPOUTLINETEXTMETRICW lpotm, LPLOG }
case GPOS_LOOKUP_POSITION_CONTEXT: - return glyph_index + GPOS_apply_ContextPos(psc, lpotm, lplogfont, analysis, piAdvance, + return GPOS_apply_ContextPos(psc, lpotm, lplogfont, analysis, piAdvance, lookup, look, glyphs, glyph_index, glyph_count, ppem, pGoffset);
case GPOS_LOOKUP_POSITION_CONTEXT_CHAINED: - return glyph_index + GPOS_apply_ChainContextPos(psc, lpotm, lplogfont, analysis, piAdvance, + return GPOS_apply_ChainContextPos(psc, lpotm, lplogfont, analysis, piAdvance, lookup, look, glyphs, glyph_index, glyph_count, ppem, pGoffset);
default: FIXME("Unhandled GPOS lookup type %#x.\n", type); } - return glyph_index+1; + return 1; }
INT OpenType_apply_GPOS_lookup(ScriptCache *psc, LPOUTLINETEXTMETRICW lpotm, LPLOGFONTW lplogfont, const SCRIPT_ANALYSIS *analysis, INT* piAdvance, INT lookup_index, const WORD *glyphs, INT glyph_index, INT glyph_count, GOFFSET *pGoffset) diff --git a/dlls/usp10/shape.c b/dlls/usp10/shape.c index bf333b2..9549d9f 100644 --- a/dlls/usp10/shape.c +++ b/dlls/usp10/shape.c @@ -889,7 +889,8 @@ static VOID GPOS_apply_feature(ScriptCache *psc, LPOUTLINETEXTMETRICW lpotm, LPL { int j; for (j = 0; j < glyph_count; ) - j = OpenType_apply_GPOS_lookup(psc, lpotm, lplogfont, analysis, piAdvance, feature->lookups[i], glyphs, j, glyph_count, pGoffset); + j += OpenType_apply_GPOS_lookup(psc, lpotm, lplogfont, analysis, piAdvance, + feature->lookups[i], glyphs, j, glyph_count, pGoffset); } }