[PATCH v2] gdiplus: Scale widened dashes to the pen width.

Zebediah Figura z.figura12 at gmail.com
Wed Jun 28 13:47:53 CDT 2017


On 06/28/2017 01:43 PM, Vincent Povirk wrote:
> I don't understand this part.
> 
> On Tue, Jun 27, 2017 at 5:27 PM, Zebediah Figura <z.figura12 at gmail.com> wrote:
>> @@ -2175,8 +2182,7 @@ static void widen_dashed_figure(GpPath *path, GpPen *pen, int start, int end,
>>       if (dash_index % 2 == 0 && num_tmp_points != 0)
>>       {
>>           /* last dash overflows last segment */
>> -        tmp_points[num_tmp_points] = path->pathdata.Points[end];
>> -        widen_open_figure(tmp_points, pen, 0, num_tmp_points,
>> +        widen_open_figure(tmp_points, pen, 0, num_tmp_points-1,
>>               draw_start_cap ? pen->startcap : LineCapFlat, pen->customstart,
>>               closed ? LineCapFlat : pen->endcap, pen->customend, last_point);
>>       }
> 
> 

The code is redundant and ends up creating an extra point at the end of 
the path. The loop already ensures that the last point will be on the 
end of a segment.



More information about the wine-devel mailing list