diff --git a/fhem/FHEM/98_DOIF.pm b/fhem/FHEM/98_DOIF.pm
index 26889ed4f..e022feb75 100644
--- a/fhem/FHEM/98_DOIF.pm
+++ b/fhem/FHEM/98_DOIF.pm
@@ -4403,7 +4403,7 @@ sub color {
$l=$lightness;
} else {
if ($hue>180 and $hue<290) {
- $l=65;
+ $l=70;
} else {
$l=50;
}
@@ -4731,6 +4731,19 @@ sub y_h
}
+sub hsl_color
+{
+ my ($color,$corr_light)=@_;
+ my ($hue,$sat,$light)=split(/\./,$color);
+ $sat=100 if (!defined $sat);
+ $light=50 if (!defined $light);
+ $light+=$corr_light if (defined $corr_light);
+ $light=0 if ($light < 0);
+ $light=100 if ($light > 100);
+ return("hsl($hue,$sat%,$light%)");
+}
+
+
sub cylinder
{
my ($header,$min,$max,$unit,$bwidth,$height,$size,$dec,@values) = @_;
@@ -4770,8 +4783,7 @@ sub cylinder
$out.= '';
for (my $i=0;$i<@values;$i+=3){
my $color=$values[$i+1];
- $out.= sprintf('',$color,$color,$color);
- $out.= sprintf('',$color,$color,$color);
+ $out.= sprintf('',$color,hsl_color($color),hsl_color($color));
}
$out.= '';
$out.= '';
@@ -4806,14 +4818,15 @@ sub cylinder
my $text=$values[$i+2];
($y,$val1,$null)=y_h($value,$min,$max,$height);
- $out.= sprintf('',$y,$width,$val1,$color);
- # $out.= sprintf('',$y,$width,$color);
- $out.= sprintf('',$y,$width);
+ $out.= sprintf('',$y,$width,$val1,$color);
+ #$out.= sprintf('',$y,$width);
+ $out.= sprintf('',$y,$width,hsl_color($color,15));
+
if (defined $text and $text ne "") {
- $out.= sprintf('%s',$yBegin+$i*12,color($color),$text.":");
+ $out.= sprintf('%s',$yBegin+$i*12,hsl_color($color),$text.":");
$yValue+=7;
}
- $out.= sprintf('%s%s',$bwidth+5, $yValue+$i*12,color ($color),sprintf($format,$value),$unit);
+ $out.= sprintf('%s%s',$bwidth+5, $yValue+$i*12,hsl_color ($color),sprintf($format,$value),$unit);
}
$out.= sprintf('',$width);