[PATCH 2/5] d3dx9: Handle DT_CALCRECT in ID3DXFont_DrawText.

Sven Baars sbaars at codeweavers.com
Mon Mar 16 05:09:30 CDT 2020


On 13-03-2020 17:21, Matteo Bruni wrote:
> On Tue, Mar 10, 2020 at 11:38 AM Sven Baars <sbaars at codeweavers.com> wrote:
>> @@ -705,11 +706,24 @@ static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
>>              heap_free(results.lpCaretPos);
>>              heap_free(results.lpGlyphs);
>>          }
>> +        else if (size.cx > max_width)
>> +        {
>> +            max_width = size.cx;
>> +        }
> 
> I don't know if this is going to change afterwards but, currently, it
> seems to me that the "else if" condition is always true.
> 

I don't think so. There is a while loop over all lines. If the first
line has width 20 and the second line has width 10, the first one counts.



More information about the wine-devel mailing list