[LON-CAPA-cvs] cvs: loncom /interface loncommon.pm
matthew
lon-capa-cvs@mail.lon-capa.org
Fri, 15 Oct 2004 16:51:29 -0000
matthew Fri Oct 15 12:51:29 2004 EDT
Modified files:
/loncom/interface loncommon.pm
Log:
&DrawBarGraph: Made bars wider when there are fewer than 5 of them.
Index: loncom/interface/loncommon.pm
diff -u loncom/interface/loncommon.pm:1.219 loncom/interface/loncommon.pm:1.220
--- loncom/interface/loncommon.pm:1.219 Tue Oct 12 19:26:48 2004
+++ loncom/interface/loncommon.pm Fri Oct 15 12:51:29 2004
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# a pile of common routines
#
-# $Id: loncommon.pm,v 1.219 2004/10/12 23:26:48 albertel Exp $
+# $Id: loncommon.pm,v 1.220 2004/10/15 16:51:29 matthew Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -3293,7 +3293,11 @@
}
#
my ($height,$width,$xskip,$bar_width) = (200,120,1,15);
- if ($NumBars < 10) {
+ if ($NumBars < 5) {
+ $width = 120+$NumBars*25;
+ $xskip = 1;
+ $bar_width = 25;
+ } elsif ($NumBars < 10) {
$width = 120+$NumBars*15;
$xskip = 1;
$bar_width = 15;