gdi32/path.c -- Allow PATH_ExtTextOut() handle non printablecharacters
Massimo Del Fedele
max at veneto.com
Mon Mar 16 04:49:03 CDT 2009
Dmitry Timoshkov ha scritto:
> "Massimo Del Fedele" <max at veneto.com> wrote:
>
>> PATH_ExtTextOut() uses GetGlyphOutlineW() which can return a NULL
>> buffer size not just on errors but also on non-printable glyphs.
>> Instead of aborting the function should check for such cases, get the
>> metrics and continue.
>
> This patch doesn't match the normal logic of ExtTextOut implemented
> in dlls/winex11.drv/xrender.c, also this requires a test case for
> both code paths.
>
Why ? As is it now PATH_ExtTextOut() simply returns FALSE on first space
or non-printable glyph, you can see easily printing something like
"THIS IS A TEST" on an open path.
BTW, this behaviour (GetGlyphOutlineW returning NULL on spaces) is quite
well known, and is NOT an error value, simply there's no glyph outline
for non-printable characters, so the requested buffer size is NULL; the
function just outputs the metrics.
Also, I don't know how to make a testcase with no graphic output.... If
you have some suggestion about, I can make one.
Ciao
Max
More information about the wine-devel
mailing list