Bug fix attached...
Søren Hauberg wrote:
Hi,
Running a recent checkout from cvs I got a weird behaviour when I
plot to curves. This code
figure
hold on
f = sin(0:0.1:2*pi);
plot(f)
plot(1+f)
hold off
produces to sine curves but the second one (the upper one) is missing
the first data point.
Søren
------------------------------------------------------------------------
--- /usr/local/share/octave/2.9.9+/m/plot/__uiobject_draw_axes__.m
2007-03-04 16:14:47.000000000 -0600
+++ ./__uiobject_draw_axes__.m 2007-03-07 11:37:15.060501272 -0600
@@ -670,6 +670,8 @@
filespec{i}, usingclause{i}, titlespec{i}, withclause{i});
endfor
fputs (plot_stream, ";\n");
+ fflush (plot_stream);
+
for i = 1:data_idx
if (strcmp (filespec{i}, "-"))
if (nd == 2)
@@ -688,15 +690,12 @@
endfor
endif
endif
- fputs (plot_stream, "e");
+ fputs (plot_stream, "e\n");
fflush (plot_stream);
endif
endfor
endif
- fputs (plot_stream, "\n");
- fflush (plot_stream);
-
else
print_usage ();
endif