2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-01-31 18:59:33 +00:00

98_SVG.pm: display lines with same x coord (Forum #86800)

git-svn-id: https://svn.fhem.de/fhem/trunk@16631 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
rudolfkoenig 2018-04-17 18:50:09 +00:00
parent 3078208b9f
commit 26e7d23427

View File

@ -2043,10 +2043,9 @@ SVG_render($$$$$$$$$$)
foreach my $i (0..int(@{$dxp})-2) {
my ($x1, $y1) = ($x+$dxp->[$i], $y+$h-($dyp->[$i] -$min)*$hmul);
my ($x2, $y2) = ($x+$dxp->[$i+1], $y+$h-($dyp->[$i+1]-$min)*$hmul);
next if(int($x2) == $lx);
$x2 += 0.2 if($x1 == $x2);
my $Y = ($lType eq "horizontalLineFrom" ? $y1 : $y2);
SVG_pO "<line $attributes $lStyle x1='$x1' y1='$Y' x2='$x2' y2='$Y'/>";
$lx = int($x2);
}
} else { # lines and everything else