mode for Gnuplot

Bill Hatch bill at alembic.acs.com
Tue Aug 22 11:53:27 AEST 1989


I have recently installed Gnuplot under uport V386/3.0e and Xenix. This
installation included the patches for the Laserjet and Hercules plus
others as posted in this news group.  For both Xenix and uport, Gnuplot
needs a utility named "mode" to switch the console to the graphics mode.
Can anyone provide me some pointers to an available code for mode
or some info on how to develop a mode utility that will work with 
Gnuplot.

With my installed Gnuplot I noted that the "set output" option failed
to redirect the plot output to the designated file; all plot outpot
(unix, laserjet, tek ...) came to the console.  The workaround is
to do the redirection in the initial Gnuplot command as:

	gnuplot >out_file

The fix is to modify command.c to close stdout, then dup() the 
"outfile" that has been opened as per the "set output" command.
This will cause the duped file to have a file descriptor of 1.
and the plot output will now be correctly redirected.  This trick is
necessary because most of the functions in term.c do not pass the
"outfile" descriptor to the lower level functions that handle the
physical plot output.  All of these lower level functions seem to
assume that outout is to stdout.

bill hatch
uunet!bts!bill or uunet!inco!alembic!bill
(301)441-1675 (home)
(301)470-3839 (work)



More information about the Comp.unix.microport mailing list