Chart-EPS_graph
view release on metacpan or search on metacpan
lib/Chart/EPS_graph.pm view on Meta::CPAN
$str .= '/fake_col_zero_flag ';
$str .= $self->{x_is_zeroth} ? 'false' : 'true';
$str .= " def \n";
$str .= "/fake_col_zero_scale $self->{x_scale} def \n";
$str .= "/data_sets 1 def \n";
# This is an ugly, ex-post-facto hack.
# When chans skipped, patch up the bottom string to cover up remove gap in
# channel ID's. In short, make legend ID match the gap-free curve ID.
if ($self->{close_gap}) {
$self->{shown} = [ @{ $self->{y1} }, @{ $self->{y2} } ];
my @gap_free = gap_free_skip( $self->{shown}, $self->{not_shown} );
for my $i ( 0 .. $#gap_free ) {
$self->{label_x_proc} =~ s/ $self->{shown}->[$i] / $gap_free[$i] /m;
$self->{label_x_proc} =~ s/ $self->{shown}->[$i] show_color_id/ $gap_free[$i] show_color_id/m;
}
}
$str .= $self->{label_x_proc}; # List of chans shown
lib/Chart/EPS_graph.pm view on Meta::CPAN
label_x_2
label_y1
label_y1_2
label_y2
label_y2_2
);
for (@ps_string_list) { $self->{$_} = $self->ps_str_esc($self->{$_}) }
# Collect list of shown-channel names
# Prettify them into a graph legend good for B&W, not just color.
for (@{ $self->{y1} }, @{ $self->{y2} }) {
my $arrow = $self->y_arrow($_);
$self->{label_x_proc} .= " ($arrow$_) $_ show_color_id ($self->{names}->[$_] ) show ";
}
# Determine list of channels not to show.
for ( 1 .. $#{$self->{names}} ) {
# Mitigate an RE between Perl & PostScript by swaping all
# escaped-for-PostScript string delimiters with Perl RE dots.
( run in 0.570 second using v1.01-cache-2.11-cpan-49f99fa48dc )