diff options
author | terry%netscape.com <> | 1999-02-02 23:03:52 +0000 |
---|---|---|
committer | terry%netscape.com <> | 1999-02-02 23:03:52 +0000 |
commit | f5b3090ec9f02f5b8eaaa22c99f105266d0f2441 (patch) | |
tree | f6767854289f57f48ae65d395409eac6e24f1d2f | |
parent | 91e9353ac2728e9246cac843fc9ee0f2b2d16f21 (diff) | |
download | bugs-f5b3090ec9f02f5b8eaaa22c99f105266d0f2441.tar bugs-f5b3090ec9f02f5b8eaaa22c99f105266d0f2441.tar.gz bugs-f5b3090ec9f02f5b8eaaa22c99f105266d0f2441.tar.bz2 bugs-f5b3090ec9f02f5b8eaaa22c99f105266d0f2441.tar.xz bugs-f5b3090ec9f02f5b8eaaa22c99f105266d0f2441.zip |
Don't draw any more than 20 date ticks.
-rwxr-xr-x | reports.cgi | 7 |
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); |