help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Latin1 encoding in EPS print


From: Schirmacher, Rolf
Subject: RE: Latin1 encoding in EPS print
Date: Thu, 8 Nov 2007 12:30:21 +0100


> -----Original Message-----
> From: Gard Spreemann [mailto:address@hidden
> Sent: Thursday, November 08, 2007 11:30 AM
> To: Schirmacher, Rolf; address@hidden
> Subject: Re: Latin1 encoding in EPS print
> 
> 
> On Nov 8, 2007 10:55 AM, Schirmacher, Rolf
> <address@hidden> wrote:
> > One, but perhaps not the intended, idea would be to use the 
> "latexeps"-type
> > printer devices / terminals of gnuplot and let latex 
> typeset the legends
> > (which then might include any other kind of special 
> characters and symbols,
> > ...).
> 
> The problem is, I can't seem to set the latexeps type terminal for
> Gnuplot from Octave. If I try to do so using for example
> __gnuplot_raw__("set terminal pslatex; set out \"foo\";"), I get just
> an empty file with the name foo. Am I misunderstanding something when
> it comes to setting Gnuplot options from Octave?
> 
> -- 
> Gard Spreemann
>  http://folk.ntnu.no/spreeman/
> 

Is there any special reason why you use the "old style" plotting commands
with gnuplot? I am using the "new" matlab-style commands and they work well.

For example, I use the following function (not nice, but works properly for
me) to generate a pdf print:



function pdfprint(fname)

% pdfprint('filename')
%
% Produces a pdf file filename.pdf from the current figure
%
% Format: default-size, explicit size currently not supported by
octave/gnuplot
%
% Lettering: 8 pt Helvetica, can be changed ...
%
% Might be used in  pdfLaTeX like:
%
% \begin{figure}
%       \begin{center}
%               \includegraphics[width=1.0\textwidth]{filename.pdf}
%       \end{center}
%       \caption{octave-figure}
%       \label{fig:filename}
% \end{figure}
%

%%%%% ToDo: 
%%%%% - Use some temp directory for temporary files
%%%%% - support papersize / figure size
%%%%% - support latin1 encoding by default for labels
%%%%%

print('-depslatexstandalone', '-Fphv:8', '-color', '-solid',\
      [fname '.tex']);  
%%% convert eps to pdf
system(['epstopdf ' fname '-inc.eps']);
%%% generate 1 pdf through LaTeX
system(['pdflatex ' fname '.tex']);
%%% clean up
system(['rm ' fname '-inc.eps']);
system(['rm ' fname '-inc.pdf']);
system(['rm ' fname '.tex']);
system(['rm ' fname '.aux']);
system(['rm ' fname '.log']);

endfunction


HTH

Rolf


reply via email to

[Prev in Thread] Current Thread [Next in Thread]