[PATCH 5/6] usp10: Return the logical offset in GPOS_apply_lookup().
Aric Stewart
aric at codeweavers.com
Tue Feb 21 07:07:04 CST 2017
Signed-off-by: Aric Stewart <aric at codeweavers.com>
On 2/19/17 12:02 PM, Henri Verbeet wrote:
> Signed-off-by: Henri Verbeet <hverbeet at codeweavers.com>
> ---
> 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);
> }
> }
>
>
More information about the wine-patches
mailing list