|
From: | Paul Kienzle |
Subject: | Re: Octave.app for MacOSX released |
Date: | Sat, 14 Jul 2007 14:54:26 -0400 |
On Jul 14, 2007, at 2:02 PM, Henry F. Mollet wrote:
Below are lines 87-123 from drawnow.m where lines 109-114 are thecorrections that you had suggested that I use. I cannot paste the line #'sinto this post, therefore I'm also attaching the complete m-file. Henry
Okay that's what I expected to see, so I'm surprised it doesn't work.I make a suggest below to not check the DISPLAY environment variable. This might be an issue if, for example, you are running octave from X11 and have aqua set in ~/.gnuplot or GNUTERM.
- Paul
function plot_stream = open_gnuplot_stream (h, term, file) ## If drawnow is cleared, it is possible to register __go_close_all__ ## more than once, but that is not fatal. persistent __go_close_all_registered__; cmd = gnuplot_binary (); if (! isempty (h) && gnuplot_use_title_option ()) cmd = sprintf ("%s -title \"Figure %d\"", cmd, h); endif plot_stream = popen (cmd, "w"); if (plot_stream < 0) error ("drawnow: failed to open connection to gnuplot"); else if (! isempty (h)) set (h, "__plot_stream__", plot_stream); endif if (nargin == 3) fprintf (plot_stream, "set terminal %s\n;", term); fprintf (plot_stream, "set output \"%s\"\n;", file);
Try replacing:
elseif isempty(getenv("DISPLAY"))
with: else
fprintf (plot_stream, "set terminal aqua %d\n",h); endif if (isempty (__go_close_all_registered__)) atexit ("__go_close_all__"); __go_close_all_registered__ = true; endif endif endfunction
[Prev in Thread] | Current Thread | [Next in Thread] |