I am using the Windows native version of the Octplot distributed together with MSVC version of Octave 2.9.9+ under Win XP SP2. In this version, the following commands
produce a plot with a huge empty rectangular instead of the legend box. Perhaps the reason is that the Y-scale for this plot is quite narrow (-3e-14.. 3e-14).
Next, hardcopy of a plot can be saved in (E)PS format only. For other formats Octplot uses Ghostscript. In print.m, 'which' system command is used to find the Ghostscript executable. Of course, this method does not work under Windows shell.
I am not sure what method should be used to be portable. Is it possible to use the Ghostscript's environmental variables instead? Or ask user to include Ghostscript executable in the PATH? Or simply make Windows-native version of print.m (well, it is quite messy and stupid solution)?
With best wishes,
Igor
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
1) legend: This is a bug. Can you please file it under bugs?
2) ghostscript: this is indeed a problem. Can we even assume that window users have ghostscript installed anywhere? This might mean we have to supply ghostscript with octplot for windows. From what I remember, matlab (well at least the version I used to work with 6 years ago) comes wiht ghostscript excatly form this purpose.
Another solution could be for octpot to output these file formats natively. However, currently I use gl2ps to produce (e)ps. It can also produce pdf, latex and SVG, but no png or any other bitmap format. I think we really do need a bitmap format.
Any thoughts?
Shai
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
On the topic of ghostscript in windows, I would suggest the following (interim) solution:
The tools (ps2pdf, ps2ps, etc...) in the native win32 executable of ghostscript (at least in version 8.54) use an environment variable GSC defining the location of the gostscript console executable.
So you could check in print.m for the existance of the environment variable GSC and use its content as path to ghostscript.
One would require to change the path to cygwin-style (just in case), this could also be checked and done.
This would allow a user to specify a win32 binary of ghostscript even when running under cygwin.
Otherwise the user has to have ghostscript in his PATH.
Oh, BTW, the win32 ghostscript executable is named "gswin32.exe", not "gs", so a search would fail anyway, despite a working "which" command...
ben
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
2) Personally, as a LaTeX user I am quite happy with EPS and PDF formats. Using GSView+GS all these files can be converted to bitmaps manually.
I know two examples of using Ghostscript together with successful multi-user project. The first is MikTeX (the most popular Windows TeX distribution). They have so many problems with external GS that in the current version 2.5 sort of 'semi-internal' GS is used (means the executable is external, however there are a lot of staff in the internal \ghostscript directory of MiKTeX and the PS fonts are internal too). Another example is CutePDF - freeware PDF printer application for Windows. It includes an obscure version of GS and works quite well.
So, I am afraid, the only safe way is the MATLAB one, means to include minimal GS distribution in Windows (at least) version of Octplot. However, I think that, at the moment, it is not _that_ important bug. Overall Octplot development is more important.
Thank you!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I am using the Windows native version of the Octplot distributed together with MSVC version of Octave 2.9.9+ under Win XP SP2. In this version, the following commands
x=0.988:0.0001:1.012;
z=(x-1).^7;
plot(x,z,'-;test;')
produce a plot with a huge empty rectangular instead of the legend box. Perhaps the reason is that the Y-scale for this plot is quite narrow (-3e-14.. 3e-14).
Next, hardcopy of a plot can be saved in (E)PS format only. For other formats Octplot uses Ghostscript. In print.m, 'which' system command is used to find the Ghostscript executable. Of course, this method does not work under Windows shell.
I am not sure what method should be used to be portable. Is it possible to use the Ghostscript's environmental variables instead? Or ask user to include Ghostscript executable in the PATH? Or simply make Windows-native version of print.m (well, it is quite messy and stupid solution)?
With best wishes,
Igor
1) legend: This is a bug. Can you please file it under bugs?
2) ghostscript: this is indeed a problem. Can we even assume that window users have ghostscript installed anywhere? This might mean we have to supply ghostscript with octplot for windows. From what I remember, matlab (well at least the version I used to work with 6 years ago) comes wiht ghostscript excatly form this purpose.
Another solution could be for octpot to output these file formats natively. However, currently I use gl2ps to produce (e)ps. It can also produce pdf, latex and SVG, but no png or any other bitmap format. I think we really do need a bitmap format.
Any thoughts?
Shai
On the topic of ghostscript in windows, I would suggest the following (interim) solution:
The tools (ps2pdf, ps2ps, etc...) in the native win32 executable of ghostscript (at least in version 8.54) use an environment variable GSC defining the location of the gostscript console executable.
So you could check in print.m for the existance of the environment variable GSC and use its content as path to ghostscript.
One would require to change the path to cygwin-style (just in case), this could also be checked and done.
This would allow a user to specify a win32 binary of ghostscript even when running under cygwin.
Otherwise the user has to have ghostscript in his PATH.
Oh, BTW, the win32 ghostscript executable is named "gswin32.exe", not "gs", so a search would fail anyway, despite a working "which" command...
ben
1) Problem with the legend is in the bug tracker.
2) Personally, as a LaTeX user I am quite happy with EPS and PDF formats. Using GSView+GS all these files can be converted to bitmaps manually.
I know two examples of using Ghostscript together with successful multi-user project. The first is MikTeX (the most popular Windows TeX distribution). They have so many problems with external GS that in the current version 2.5 sort of 'semi-internal' GS is used (means the executable is external, however there are a lot of staff in the internal \ghostscript directory of MiKTeX and the PS fonts are internal too). Another example is CutePDF - freeware PDF printer application for Windows. It includes an obscure version of GS and works quite well.
So, I am afraid, the only safe way is the MATLAB one, means to include minimal GS distribution in Windows (at least) version of Octplot. However, I think that, at the moment, it is not _that_ important bug. Overall Octplot development is more important.
Thank you!