c7934b0d6604172ea1df78106594fe4cf30093e8
[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"><info><pubdate>$LastChangedDate$</pubdate></info><refnamediv><refname>xs2ps</refname><refpurpose>send graphics to a file in PS
14   syntax</refpurpose></refnamediv>
15   
16
17   
18
19   
20
21   
22
23   
24
25   <refsynopsisdiv><title>Calling Sequence</title><synopsis>xs2ps(win_num,filen,[color])</synopsis></refsynopsisdiv>
26
27   <refsection><title>Parameters</title>
28     <variablelist>
29       <varlistentry>
30         <term>win_num</term>
31
32         <listitem>
33           <para>integer scalar or vector .</para>
34         </listitem>
35       </varlistentry>
36
37       <varlistentry>
38         <term>filen</term>
39
40         <listitem>
41           <para>string, file name.</para>
42         </listitem>
43       </varlistentry>
44
45       <varlistentry>
46         <term>color</term>
47
48         <listitem>
49           <para>optional integer. 0 means black and white and 1 means color.
50           The default value is to use a value compatible with the screen
51           status.</para>
52         </listitem>
53       </varlistentry>
54     </variablelist>
55   </refsection>
56
57   <refsection><title>Description</title>
58         <para>The function xs2ps will not be available in version alpha</para>
59     <para><literal>xs2ps</literal> saves the recorded graphics of the window
60     <literal>win_num</literal> to file <literal>filen</literal> in Postscript syntax. The
61     <literal>filen</literal> must not have suffix extension.</para>
62
63     <para>Note that the generated Postscript file cannot be direcly printed since
64     it requires a header file. The Scilab command <literal>BEpsf</literal> or others
65     can be used to add a header file. The function <literal>xs2eps</literal> can be
66     used to directly produce an encapsulated Postscript file with an
67     header.</para>
68
69     <para>This function works only if the selected driver is <literal>"Rec"</literal>
70     in the window <literal>win_num</literal> or if the window is in "new style". The
71     generated postscript file does not contrains the header part</para>
72   </refsection>
73
74 <refsection><title>Examples</title><programlisting role="example"><![CDATA[
75 scf(0);
76 plot2d();
77 // Postcript export
78 filename='foo.ps';
79 xs2ps(0,filename)
80 // Gif export
81 xs2gif(0,'foo.gif');
82 // ppm export
83 xs2ppm(0,'foo.ppm');
84 ]]></programlisting></refsection>
85
86   <refsection><title>See Also</title><simplelist type="inline">
87     <member>
88       <link linkend="set_posfig_dim">set_posfig_dim</link>
89     </member>
90     <member>
91       <link linkend="printing">printing</link>
92     </member>
93         
94         <member>
95       <link linkend="xbasimp">xbasimp</link>
96     </member>
97         
98         <member>
99       <link linkend="xs2bmp">xs2bmp</link>
100         </member>
101         
102         <member>
103       <link linkend="xs2gif">xs2gif</link>
104         </member>
105         
106         <member>
107       <link linkend="xs2jpg">xs2jpg</link>
108     </member>
109         
110         <member>
111       <link linkend="xs2png">xs2png</link>
112         </member>
113         
114         <member>
115       <link linkend="xs2ppm">xs2ppm</link>
116     </member>
117         
118         <member>
119       <link linkend="xs2eps">xs2eps</link>
120     </member>
121         
122         <member>
123       <link linkend="xs2pdf">xs2pdf</link>
124     </member>
125         
126         <member>
127       <link linkend="xs2svg">xs2svg</link>
128     </member>
129   
130     <member>
131       <link linkend="xs2fig">xs2fig</link>
132     </member>    
133
134     <member>
135       <link linkend="xs2emf">xs2emf</link>
136     </member>
137   </simplelist></refsection>
138 </refentry>