gdi32: Fix ExtTextOutA -> W forwarding when ETO_PDY is set.
This commit is contained in:
parent
6b21d0c663
commit
9bee50f6d9
|
@ -1586,12 +1586,28 @@ BOOL WINAPI ExtTextOutA( HDC hdc, INT x, INT y, UINT flags,
|
||||||
if (lpDx) {
|
if (lpDx) {
|
||||||
unsigned int i = 0, j = 0;
|
unsigned int i = 0, j = 0;
|
||||||
|
|
||||||
lpDxW = HeapAlloc( GetProcessHeap(), 0, wlen*sizeof(INT));
|
/* allocate enough for a ETO_PDY */
|
||||||
|
lpDxW = HeapAlloc( GetProcessHeap(), 0, 2*wlen*sizeof(INT));
|
||||||
while(i < count) {
|
while(i < count) {
|
||||||
if(IsDBCSLeadByteEx(codepage, str[i])) {
|
if(IsDBCSLeadByteEx(codepage, str[i]))
|
||||||
lpDxW[j++] = lpDx[i] + lpDx[i+1];
|
{
|
||||||
|
if(flags & ETO_PDY)
|
||||||
|
{
|
||||||
|
lpDxW[j++] = lpDx[i * 2] + lpDx[(i + 1) * 2];
|
||||||
|
lpDxW[j++] = lpDx[i * 2 + 1] + lpDx[(i + 1) * 2 + 1];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
lpDxW[j++] = lpDx[i] + lpDx[i + 1];
|
||||||
i = i + 2;
|
i = i + 2;
|
||||||
} else {
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if(flags & ETO_PDY)
|
||||||
|
{
|
||||||
|
lpDxW[j++] = lpDx[i * 2];
|
||||||
|
lpDxW[j++] = lpDx[i * 2 + 1];
|
||||||
|
}
|
||||||
|
else
|
||||||
lpDxW[j++] = lpDx[i];
|
lpDxW[j++] = lpDx[i];
|
||||||
i = i + 1;
|
i = i + 1;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue