13
0

another pixel width fix, to accomodate for the unliekly

If the line width is odd, not just 1.0, the 0.5 pixel shift is required
This commit is contained in:
Paul Davis 2023-09-15 16:46:40 -06:00
parent 0a597bea66
commit 2242b3706c

View File

@ -197,8 +197,8 @@ Ruler::render (Rect const & area, Cairo::RefPtr<Cairo::Context> cr) const
prev = pos.x;
}
if (_outline_width == 1.0) {
/* Cairo single pixel line correction */
if (fmod (_outline_width, 2.)) {
/* Cairo odd pixel width line correction */
cr->move_to (pos.x + 0.5, pos.y);
} else {
cr->move_to (pos.x, pos.y);