In the example below, show_values is on, tick_number is the default (5),
there is one bar of value 99, which extends close to the top tickmark
(100) for that tick_number. Instead of extending the range so that the
value can fit nicely in the graph area, the value for the bar partially
goes off the top edge of the graph. In fact, if you change the 99 to
100, the bar simply goes all the way to the top, and you can't even see
any piece of its value. I want it take the value label into account when
calculating a range.
#!/usr/bin/perl
use strict;
use warnings;
use GD::Graph::bars;
my $my_graph = GD::Graph::bars->new;
$my_graph->set(
show_values => 1,
) or warn $my_graph->error;
$my_graph->plot( [['foo'],[99]] ) or die $my_graph->error;
my $ext = $my_graph->export_format;
open OUT, '>', "test2.$ext" or die "Cannot open for write: $!";
binmode OUT;
print OUT $my_graph->gd->$ext;
close OUT;