Merge tag 'v1.45' into debian

This commit is contained in:
Dima Kogan 2017-10-29 14:06:04 -07:00
commit ebc818791c
4 changed files with 32 additions and 15 deletions

11
Changes
View File

@ -1,3 +1,14 @@
feedgnuplot (1.45)
* zsh completion: --hardcopy, --image suggest filenames
* --image now produces a nicer legend: just the filename
* --curvestyle now overrides --curvestyleall
- This is a bug fix
* The version is now treated as a string not as a number
- So "1.40" is distinct from "1.4"
-- Dima Kogan <dima@secretsauce.net> Sun, 29 Oct 2017 13:56:28 -0700
feedgnuplot (1.44) feedgnuplot (1.44)
* --image draws its output beneath everything else * --image draws its output beneath everything else

View File

@ -20,9 +20,9 @@ sub parseversion
while(<PL>) while(<PL>)
{ {
if( /VERSION = ([0-9\.]+)/ ) if( /VERSION = '([0-9\.]+)'/ )
{ {
if ( $1 != $version ) if ( $1 ne $version )
{ {
die "Version mismatch. Changes says version is '$version', but 'bin/feedgnuplot' says it is '$1'"; die "Version mismatch. Changes says version is '$version', but 'bin/feedgnuplot' says it is '$1'";
} }

View File

@ -15,7 +15,8 @@ use Text::ParseWords; # for shellwords
use Pod::Usage; use Pod::Usage;
use Time::Piece; use Time::Piece;
my $VERSION = 1.44; # Makefile.PL assumes this is in ''
my $VERSION = '1.45';
my %options; my %options;
interpretCommandline(); interpretCommandline();
@ -438,7 +439,7 @@ sub interpretCommandline
die "Couldn't read image '$options{image}'"; die "Couldn't read image '$options{image}'";
} }
unshift @{$options{equation}}, qq{"$options{image}" binary filetype=auto flipy with rgbimage}; unshift @{$options{equation}}, qq{"$options{image}" binary filetype=auto flipy with rgbimage title "$options{image}"};
delete $options{image}; delete $options{image};
} }
} }
@ -719,11 +720,6 @@ sub mainThread
print(PIPE "set xdata time\n"); print(PIPE "set xdata time\n");
} }
# add the extra global options
print(PIPE "$_\n") foreach (@{$options{extracmds}});
print(PIPE "set $_\n") foreach (@{$options{set}});
print(PIPE "unset $_\n") foreach (@{$options{unset}});
# set up histograms # set up histograms
$options{binwidth} ||= 1; # if no binwidth given, set it to 1 $options{binwidth} ||= 1; # if no binwidth given, set it to 1
print PIPE print PIPE
@ -746,6 +742,11 @@ sub mainThread
sendRangeCommand( "zrange", $options{zmin}, $options{zmax} ); sendRangeCommand( "zrange", $options{zmin}, $options{zmax} );
sendRangeCommand( "cbrange", $options{zmin}, $options{zmax} ) if($options{colormap}); sendRangeCommand( "cbrange", $options{zmin}, $options{zmax} ) if($options{colormap});
# add the extra global options
print(PIPE "$_\n") foreach (@{$options{extracmds}});
print(PIPE "set $_\n") foreach (@{$options{set}});
print(PIPE "unset $_\n") foreach (@{$options{unset}});
@ -978,7 +979,8 @@ sub updateCurveOptions
$usingoptions = "using 1:" . join(':', @rest); $usingoptions = "using 1:" . join(':', @rest);
} }
$curve->{options} = "$histoptions $usingoptions $titleoption $curve->{extraoptions} $options{curvestyleall}";
$curve->{options} = "$histoptions $usingoptions $titleoption $curve->{extraoptions}";
} }
sub getCurve sub getCurve
@ -997,7 +999,11 @@ sub getCurve
if( !exists $curveIndices{$id} ) if( !exists $curveIndices{$id} )
{ {
push @curves, {extraoptions => ' ', push @curves, {# if we have a catch-all style and no specific style, use
# the catch-all style
extraoptions => (!exists $options{curvestyle_hash}{$id} &&
exists $options{curvestyleall}) ?
"$options{curvestyleall} " : ' ',
datastring => '', datastring => '',
datastring_meta => [], datastring_meta => [],
datastring_offset => 0}; # push a curve with no data and no options datastring_offset => 0}; # push a curve with no data and no options

View File

@ -33,10 +33,10 @@ _arguments -S
'*--set[Additional 'set' gnuplot commands]:set-option' \ '*--set[Additional 'set' gnuplot commands]:set-option' \
'*--unset[Additional 'unset' gnuplot commands]:unset-option' \ '*--unset[Additional 'unset' gnuplot commands]:unset-option' \
'*--equation[Raw symbolic equation]:equation' \ '*--equation[Raw symbolic equation]:equation' \
'--image[Image file to render beneath the data]:image' \ '--image[Image file to render beneath the data]:image:_files -g "(#i)*.(jpg|jpeg|png|gif)"' \
'--square[Plot data with square aspect ratio]' \ '--square[Plot data with square aspect ratio]' \
'--square_xy[For 3D plots, set square aspect ratio for ONLY the x,y axes]' \ '--square_xy[For 3D plots, set square aspect ratio for ONLY the x,y axes]' \
'--hardcopy[Plot to a file]:filename' \ '--hardcopy[Plot to a file]:new image filename:_files -g "(#i)*.(jpg|jpeg|png|gif)"' \
'--maxcurves[The maximum allowed number of curves]:number of curves' \ '--maxcurves[The maximum allowed number of curves]:number of curves' \
'(--3d)--monotonic[Resets plot if an X in the past is seen]' \ '(--3d)--monotonic[Resets plot if an X in the past is seen]' \
'(--rangesizeall)--extraValuesPerPoint[How many extra values are given for each data range]:N'\ '(--rangesizeall)--extraValuesPerPoint[How many extra values are given for each data range]:N'\