From c8be1e28e0dab3c7707242336d76350c2f2f19eb Mon Sep 17 00:00:00 2001 From: David Kastrup Date: Mon, 27 Feb 2012 23:29:24 +0100 Subject: [PATCH] Issue 2328: Ledger lines in PNG output have white interior Don't stroke rectangles with height or width 0 in draw_round_box --- ps/music-drawing-routines.ps | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/ps/music-drawing-routines.ps b/ps/music-drawing-routines.ps index d7450e452b..3e62f0366e 100644 --- a/ps/music-drawing-routines.ps +++ b/ps/music-drawing-routines.ps @@ -98,15 +98,20 @@ bind def dup 0.0 gt { setlinewidth % w h x y - 0 setlinecap - 1 setlinejoin - rmoveto % w h - currentpoint % w h x1 y1 - 4 2 roll % x1 y1 w h - 4 copy - rectfill - rectstroke + 2 copy 0 ne exch 0 ne and + { + 0 setlinecap + 1 setlinejoin + currentpoint % w h x1 y1 + 4 2 roll % x1 y1 w h + 4 copy + rectfill + rectstroke + } { + 1 setlinecap + rlineto stroke + } ifelse } { pop % w h x y rmoveto % w h -- 2.39.2