From 79774bf740970cf61340c7c574b3e1fee18d643c Mon Sep 17 00:00:00 2001 From: Lucas Woltmann Date: Mon, 4 Aug 2014 16:46:48 +0200 Subject: [PATCH] better colors on the analysis page --- analysis.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/analysis.php b/analysis.php index b891f29..7bcbb05 100755 --- a/analysis.php +++ b/analysis.php @@ -78,7 +78,8 @@ for ($i = 1; $i < 7; $i++) { echo "

" . $question[$i] . "

\n"; - $color = ImageColorAllocate($img, 0, 150*($question[$i]/$maxX) + 50, 0); + $green = 150*($question[$i]/$maxX) + 40; + $color = ImageColorAllocate($img, 0.57 * $green, $green, 0.45 * $green); DrawBar($img, $question[$i], $maxX, $i+1, $maxY, $question[$i], $color); } @@ -138,7 +139,8 @@ for ($i = 0; $i < 6; $i++) { echo "

" . $tutor[$i] . "

\n"; - $color = ImageColorAllocate($img, 0, 150*($tutor[$i]/$maxX) + 50, 0); + $green = 150*($tutor[$i]/$maxX) + 40; + $color = ImageColorAllocate($img, 0.54 * $green, $green, 0.45 * $green); DrawBar($img, $tutor[$i], $maxX, $i+2, $maxY, $tutor[$i], $color); }