]> git.lyx.org Git - lyx.git/commitdiff
Fix depth bar optics master
authorDaniel Ramoeller <d.lyx@web.de>
Thu, 13 Aug 2020 14:36:15 +0000 (16:36 +0200)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Fri, 14 Jun 2024 14:28:04 +0000 (16:28 +0200)
src/RowPainter.cpp

index 19d83c13a33b177ebe646dead3d24d3cf8489220..e84343a7aa6ada4193a6317322e4dca9a9544da6 100644 (file)
@@ -352,12 +352,12 @@ void RowPainter::paintDepthBar() const
                int const starty = yo_ - row_.ascent();
                int const h =  row_.height() - 1 - (i - next_depth - 1) * 3;
 
-               pi_.pain.line(x, starty, x, starty + h, Color_depthbar);
+               pi_.pain.line(x, starty + (i > prev_depth ? 1 : 0), x, starty + h, Color_depthbar);
 
                if (i > prev_depth)
                        pi_.pain.fillRectangle(x, starty, w, 2, Color_depthbar);
                if (i > next_depth)
-                       pi_.pain.fillRectangle(x, starty + h, w, 2, Color_depthbar);
+                       pi_.pain.fillRectangle(x, starty + h - 1, w, 2, Color_depthbar);
        }
 }