Commit 91fafce0 authored by Committed by Carlos Garcia Campos
cairo: align strokes when Stroke Adjust is true and line width <= 1
If the stroke coordinates are not aligned, lines in cairo may be up to 1 pixel wider than the requested width. This is most obvious when the line width is 1 and the rendered line is 2 pixels. When Stroke Adjust is true, the PDF standard requires that stroke coordinates be adjusted to ensure the stroke width is within half a pixel of the requested width. If Stroke Adjust is enabled and the width is <= 1 pixel (the previous commit adjusts the width to be at least 1 pixel), use the method documented at http://www.cairographics.org/FAQ/#sharp_lines to align the coordinates to ensure the rendered width is 1 pixel. Fixes bug #4536.
Showing with 38 additions and 5 deletions