46f9aa541c001385f685d4b3745757c0c04a0638
[scilab.git] / scilab / modules / graphic_export / help / en_US / xs2ps.xml
1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!--
3  * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
4  * Copyright (C) 2008 - INRIA - Sylvestre Koumar
5  * 
6  * This file must be used under the terms of the CeCILL.
7  * This source file is licensed as described in the file COPYING, which
8  * you should have received as part of this distribution.  The terms
9  * are also available at    
10  * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
11  *
12  -->
13 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" version="5.0-subset Scilab" xml:lang="en" xml:id="xs2ps">
14   <info>
15     <pubdate>$LastChangedDate$</pubdate>
16   </info>
17   <refnamediv>
18     <refname>xs2ps</refname>
19     <refpurpose>send graphics to a file in PS
20   syntax</refpurpose>
21   </refnamediv>
22   <refsynopsisdiv>
23     <title>Calling Sequence</title>
24     <synopsis>xs2ps(win_num,filen,[color])</synopsis>
25   </refsynopsisdiv>
26   <refsection>
27     <title>Parameters</title>
28     <variablelist>
29       <varlistentry>
30         <term>win_num</term>
31         <listitem>
32           <para>integer scalar or vector .</para>
33         </listitem>
34       </varlistentry>
35       <varlistentry>
36         <term>filen</term>
37         <listitem>
38           <para>string, file name.</para>
39         </listitem>
40       </varlistentry>
41       <varlistentry>
42         <term>color</term>
43         <listitem>
44           <para>optional integer. 0 means black and white and 1 means color.
45           The default value is to use a value compatible with the screen
46           status.</para>
47         </listitem>
48       </varlistentry>
49     </variablelist>
50   </refsection>
51   <refsection>
52     <title>Description</title>
53     <para>The function xs2ps will not be available in version alpha</para>
54     <para><literal>xs2ps</literal> saves the recorded graphics of the window
55     <literal>win_num</literal> to file <literal>filen</literal> in Postscript syntax. The
56     <literal>filen</literal> must not have suffix extension.</para>
57     <para>Note that the generated Postscript file cannot be direcly printed since
58     it requires a header file. The Scilab command <literal>BEpsf</literal> or others
59     can be used to add a header file. The function <literal>xs2eps</literal> can be
60     used to directly produce an encapsulated Postscript file with an
61     header.</para>
62     <para>This function works only if the selected driver is <literal>"Rec"</literal>
63     in the window <literal>win_num</literal> or if the window is in "new style". The
64     generated postscript file does not contrains the header part</para>
65   </refsection>
66   <refsection>
67     <title>Examples</title>
68     <programlisting role="example"><![CDATA[
69 scf(0);
70 plot2d();
71 // Postcript export
72 filename='foo.ps';
73 xs2ps(0,filename)
74 // Gif export
75 xs2gif(0,'foo.gif');
76 // ppm export
77 xs2ppm(0,'foo.ppm');
78 ]]></programlisting>
79   </refsection>
80   <refsection>
81     <title>See Also</title>
82     <simplelist type="inline">
83       <member>
84         <link linkend="set_posfig_dim">set_posfig_dim</link>
85       </member>
86       <member>
87         <link linkend="printing">printing</link>
88       </member>
89       <member>
90         <link linkend="xbasimp">xbasimp</link>
91       </member>
92       <member>
93         <link linkend="xs2bmp">xs2bmp</link>
94       </member>
95       <member>
96         <link linkend="xs2gif">xs2gif</link>
97       </member>
98       <member>
99         <link linkend="xs2jpg">xs2jpg</link>
100       </member>
101       <member>
102         <link linkend="xs2png">xs2png</link>
103       </member>
104       <member>
105         <link linkend="xs2ppm">xs2ppm</link>
106       </member>
107       <member>
108         <link linkend="xs2eps">xs2eps</link>
109       </member>
110       <member>
111         <link linkend="xs2pdf">xs2pdf</link>
112       </member>
113       <member>
114         <link linkend="xs2svg">xs2svg</link>
115       </member>
116       <member>
117         <link linkend="xs2fig">xs2fig</link>
118       </member>
119       <member>
120         <link linkend="xs2emf">xs2emf</link>
121       </member>
122     </simplelist>
123   </refsection>
124 </refentry>