Browse Source

gnuplot.c, add 'noretraceplot' to prevent retracing of the graph if plotting against a vector which is not the original scale vector ('plot vec1 vs vec2')

pre-master-46
h_vogt 10 years ago
committed by Holger Vogt
parent
commit
c8cd763314
  1. 3
      src/frontend/plotting/gnuplot.c

3
src/frontend/plotting/gnuplot.c

@ -252,6 +252,7 @@ ft_gnuplot(double *xlims, double *ylims, char *filename, char *title, char *xlab
(void) fclose(file); (void) fclose(file);
/* Write out the data and setup arrays */ /* Write out the data and setup arrays */
bool mono = (plottype == PLOT_MONOLIN);
dir = 0; dir = 0;
prev_xval = NAN; prev_xval = NAN;
for (i = 0; i < scale->v_length; i++) { for (i = 0; i < scale->v_length; i++) {
@ -264,7 +265,7 @@ ft_gnuplot(double *xlims, double *ylims, char *filename, char *title, char *xlab
yval = isreal(v) ? yval = isreal(v) ?
v->v_realdata[i] : realpart(v->v_compdata[i]); v->v_realdata[i] : realpart(v->v_compdata[i]);
if (i > 0 && scale->v_plot && scale->v_plot->pl_scale == scale) {
if (i > 0 && (mono || (scale->v_plot && scale->v_plot->pl_scale == scale))) {
if (dir * (xval - prev_xval) < 0) { if (dir * (xval - prev_xval) < 0) {
/* direction reversal, start a new graph */ /* direction reversal, start a new graph */
fprintf(file_data, "\n"); fprintf(file_data, "\n");

Loading…
Cancel
Save