summaryrefslogtreecommitdiffstats
path: root/reports.cgi
diff options
context:
space:
mode:
authorterry%netscape.com <>1999-02-03 00:03:52 +0100
committerterry%netscape.com <>1999-02-03 00:03:52 +0100
commitf5b3090ec9f02f5b8eaaa22c99f105266d0f2441 (patch)
treef6767854289f57f48ae65d395409eac6e24f1d2f /reports.cgi
parent91e9353ac2728e9246cac843fc9ee0f2b2d16f21 (diff)
downloadbugzilla-f5b3090ec9f02f5b8eaaa22c99f105266d0f2441.tar.gz
bugzilla-f5b3090ec9f02f5b8eaaa22c99f105266d0f2441.tar.xz
Don't draw any more than 20 date ticks.
Diffstat (limited to 'reports.cgi')
-rwxr-xr-xreports.cgi7
1 files changed, 7 insertions, 0 deletions
diff --git a/reports.cgi b/reports.cgi
index 410abc105..f78fd643f 100755
--- a/reports.cgi
+++ b/reports.cgi
@@ -452,12 +452,19 @@ FIN
push @data, \@assigned;
push @data, \@reopened;
+ my $MAXTICKS = 20; # Try not to show any more x ticks than this.
+ my $skip = 1;
+ if (@dates > $MAXTICKS) {
+ $skip = int((@dates + $MAXTICKS - 1) / $MAXTICKS);
+ }
+
my %settings =
(
"title" => "Bug Charts for $::FORM{'product'}",
"x_label" => "Dates",
"y_label" => "Bug Count",
"legend_labels" => \@labels,
+ "skip_x_ticks" => $skip,
);
$img->set (%settings);