comparison scripts/plot/drawnow.m @ 6286:c6a7b0453f9a

[project @ 2007-02-08 19:04:38 by jwe]
author jwe
date Thu, 08 Feb 2007 19:04:38 +0000
parents 44c91c5dfe1d
children e8c4edcfe43d
comparison
equal deleted inserted replaced
6285:3991a9f0fead 6286:c6a7b0453f9a
35 f = get (h); 35 f = get (h);
36 36
37 plot_stream = f.__plot_stream__; 37 plot_stream = f.__plot_stream__;
38 38
39 if (isempty (plot_stream)) 39 if (isempty (plot_stream))
40 plot_stream = popen (sprintf ("gnuplot -title \"Figure %d\"", h), "w"); 40 cmd = gnuplot_binary ();
41 if (gnuplot_use_title_option ())
42 cmd = sprintf ("%s -title \"Figure\" %s", cmd, h);
43 endif
44 plot_stream = popen (cmd, "w");
41 if (plot_stream < 0) 45 if (plot_stream < 0)
42 error ("drawnow: failed to open connection to gnuplot"); 46 error ("drawnow: failed to open connection to gnuplot");
43 else 47 else
44 set (h, "__plot_stream__", plot_stream); 48 set (h, "__plot_stream__", plot_stream);
45 if (isempty (getenv ("DISPLAY"))) 49 if (isempty (getenv ("DISPLAY")))