help: scilab|scilex page fixed & improved 44/18744/5
Samuel GOUGEON [Sun, 4 Dec 2016 18:38:09 +0000 (19:38 +0100)]
 * "-e" & "-f": special management of the CWD wasn't documented
   (after http://mailinglists.scilab.org/Users-fr-Repertoire-de-demarrage-Scilab-tp4035138p4035149.html)

 * "-args" usage was hardly described. Now properly documented.

 * Improvements:
   - scilex|wscilex syntaxes added
   - options reserved to Linux/Mac OSX => Dedicated section
   - unproper <programlisting>: replaced with <screen> areas
   - "See also" enriched: sciargs, getpid, getenv, getversion, consolebox added
   - Example for "-e" improved: now includes some quotes showing how to manage them.
   - xml registration for scilex and wscilex added
   - Some <para> converted into <warning> / <important> tags
   - other miscellaneous improvements for a better readability.

 * Fixed: -version does not make Scilab exiting

Change-Id: Ic2231c4872a21658c4b16ce403f8aa340dd5bcb4

scilab/CHANGES.md
scilab/modules/core/help/en_US/scilab.xml
scilab/modules/core/help/fr_FR/scilab.xml
scilab/modules/core/help/ja_JP/scilab.xml
scilab/modules/core/help/pt_BR/scilab.xml
scilab/modules/core/help/ru_RU/scilab.xml

index 34f14d0..1ebfc00 100644 (file)
@@ -207,7 +207,7 @@ Help pages:
 -----------
 
 * fixed / improved:  `members`, `part`, `ode`, `ode_optional_output`, `ode_roots`, `roots`,
-  `printf`, `sprintf`, `iconvert`, `stdev`, `xlabel`, `and_op`, `or_op`, `%helps`
+  `printf`, `sprintf`, `iconvert`, `stdev`, `xlabel`, `and_op`, `or_op`, `%helps`, `scilab|scilex`
 * rewritten: `consolebox`, `double`, `isoview`, `householder`, `or`, `and`, `format`, `typeof`,
 `brackets`, `setlanguage`, `sleep`, `isinf`, `bitor`, `bitxor`, `bitand`, `geomean`
 * reorganized:
index 4bf76a5..3046f7f 100644 (file)
@@ -1,33 +1,89 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns4="http://www.w3.org/1999/xhtml" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org" xml:id="scilab" xml:lang="en">
+<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"
+          xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns4="http://www.w3.org/1999/xhtml"
+          xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook"
+          xmlns:scilab="http://www.scilab.org" xml:id="scilab" xml:lang="en">
+    <refnamediv xml:id="wscilex">
+    </refnamediv>
+    <refnamediv xml:id="scilex">
+    </refnamediv>
     <refnamediv>
-        <refname>scilab</refname>
-        <refpurpose>Main script to start Scilab and miscellaneous
-            tools (GNU/Linux, Unix and Mac OS X)
+        <refname>scilex | scilab</refname>
+        <refpurpose>runs Scilab in interactive or batch mode with command line options
         </refpurpose>
     </refnamediv>
     <refsynopsisdiv>
         <title>Syntax</title>
-        <synopsis>scilab &lt;Options&gt;
-            scilab-adv-cli &lt;Options&gt;
-            scilab-cli &lt;Options&gt;
+        <synopsis>
+#      MS Windows          |  # Linux / Unix / Mac OS X
+wscilex     &lt;Options&gt;     |  scilab         &lt;Options&gt;
+wscilex -nw &lt;Options&gt; |  scilab-adv-cli &lt;Options&gt;
+scilex      &lt;Options&gt;      |  scilab-cli     &lt;Options&gt;
         </synopsis>
     </refsynopsisdiv>
     <refsection role="arguments">
-        <title>Arguments</title>
+        <title>Options</title>
         <variablelist>
             <varlistentry>
-                <term>-args Arguments</term>
+                <term>-args arg#1 arg#2 ..</term>
                 <listitem>
-                    <para>If this option is present, arguments are passed to Scilab.
-                        They can then be got by <link linkend="sciargs">sciargs</link>
-                        function. For multi arguments passing use a quoted, blank separated
-                        sequence of words like: <literal>scilab -args 'foo1
-                            foo2'
-                        </literal>
-                        .Without this option, unknown arguments will not
-                        be accepted.
+                    <para>
+                        This option allows to send some data to the Scilab session:
+                        <itemizedlist>
+                            <listitem>Consecutive data are separated by one or several spaces.
+                            </listitem>
+                            <listitem>An expression between double-quotes is a single data.
+                            </listitem>
+                            <listitem>To include a double-quote in a data, write <literal>\"</literal> instead of <literal>"</literal>.
+                            </listitem>
+                            <listitem>The single quote <literal>'</literal> is a regular character. It has no special meaning.
+                            </listitem>
+                        </itemizedlist>
                     </para>
+                    <para>
+                      Inside the opened session, these data can be retrieved as separated strings with <link linkend="sciargs">sciargs()</link>.
+                     </para>
+                     <para>
+                      Example:
+                        <screen><![CDATA[C:\Users\Me> scilex -nb -args "Hello \"%USERNAME%\"" 1.2345 \"%cd%\"]]></screen>
+                        <programlisting><![CDATA[
+// Inside the opened session:
+a = sciargs()
+i = find(a=="-args")
+a(i+1)
+evstr(a(i+2))*2
+"This session has been launched from " + a(i+3)
+                        ]]>
+                        </programlisting>
+                        <screen><![CDATA[
+--> // Inside the opened session:
+--> a = sciargs()
+ a  =
+!c:\SCIdir\bin\scilex  -nw  -nb  -noatomsautoload  -args  Hello "John"  1.2345  "C:\Users\Me" !
+
+--> i = find(a=="-args")
+ i  =
+    5.
+
+--> a(i+1)
+ ans  =
+ Hello "John"
+
+--> evstr(a(i+2))*2
+ ans  =
+    2.469
+
+--> "This session has been launched from " + a(i+3)
+ ans  =
+ This session has been launched from "C:\Users\Me"
+
+-->
+]]></screen>
+                     </para>
+                     <para>
+                     <note>Using <literal>-args</literal> as the <emphasis role="italic">last</emphasis> command line option is safer.
+                     </note>
+                     </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 </listitem>
             </varlistentry>
             <varlistentry>
-                <term>-debug</term>
+                <term>-e Instructions</term>
                 <listitem>
-                    <para>Start Scilab under the debugger gdb (Unix/Linux/Mac OS X only).</para>
                     <para>
-                        Define the variable <literal>SCILAB_GDB_OPT</literal> to add custom options to
-                        gdb.
-                    </para>
-                    <para>Advice: use this option on a Scilab source tree.</para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-debug-kdbg</term>
-                <listitem>
-                    <para>Start Scilab under kdbg (Unix/Linux/Mac OS X only).</para>
-                    <para>Advice: use this option on a Scilab source tree.</para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-profiling</term>
-                <listitem>
-                    <para>Start Scilab under valgrind (Unix/Linux/Mac OS X only).</para>
-                    <para>Define the variable SCILAB_VALGRIND_OPT to add custom options
-                        to valgrind (and override the existing valgrind options).
-                    </para>
-                    <para>Advice: use this option on a Scilab source tree.</para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-profiling-visu</term>
-                <listitem>
-                    <para>Start Scilab under callgrind (Unix/Linux/Mac OS X only).</para>
-                    <para>Define the variable SCILAB_VALGRIND_OPT to add custom options
-                        to callgrind (and override the existing callgrind options).
+                        At the end of the whole session startup, this option
+                        <itemizedlist>
+                            <listitem>
+                                <para>sets the current working directory to the shell directory from which Scilab has been launched. Please see the example given here-below for the <literal>-f</literal> option. Then,
+                                </para>
+                            </listitem>
+                            <listitem>
+                                <para>executes Scilab <literal>Instructions</literal> provided in a string. Example:
+                                    <screen><![CDATA[ scilab-cli -e  "disp(\"Hello\"); a=%pi+%i; disp(exp(a)); exit;" -nb]]></screen>
+                                </para>
+                            </listitem>
+                        </itemizedlist>
                     </para>
-                    <para>Advice: use this option on a Scilab source tree.</para>
+                    <warning>
+                        <literal>-e</literal> and <literal>-f</literal> options can't be used together.
+                    </warning>
                 </listitem>
             </varlistentry>
             <varlistentry>
-                <term>-electric-fence</term>
-                <listitem>
-                    <para>Start Scilab with the Electric Fence (Unix/Linux/Mac OS X only).</para>
-                    <para>Advice: use this option on a Scilab source tree.</para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-e Instruction</term>
+                <term>-f file</term>
                 <listitem>
-                    <para>If this option is present then Scilab instruction
-                        <literal>Instruction</literal> is executed first (just after startup
-                        file execution) into Scilab. <literal>-e</literal> and
-                        <literal>-f</literal> options are mutually exclusive.
-                    </para>
                     <para>
-                        Note that several instructions can be used in with <literal>-e</literal>.
+                        If this option is used, then at the beginning of the Scilab session, after the execution of the scilab and user startup files, and after the setting of user Preferences -- including the working directory ones --,
+                        <itemizedlist>
+                            <listitem>
+                                <para>
+                                    the current Scilab working directory is set to the shell directory from which Scilab has been launched. For instance,
+                                    <screen><![CDATA[ D:\users\me\scilab\dev> C:\scilab-5.5.2\bin\scilex -f ..\test.sce]]></screen>
+                                    will do a <literal>cd("D:\users\me\scilab\dev")</literal>.
+                                </para>
+                            </listitem>
+                            <listitem>
+                                <para>
+                                    the Scilab script <literal>file</literal> is executed. If a relative path is used (default <literal>.\</literal>, or like <literal>..\</literal> in the sample here-above), it refers to the new Scilab working directory.
+                                </para>
+                            </listitem>
+                        </itemizedlist>
                     </para>
-                    <programlisting role="no-scilab-exec">scilab-cli -e  "a=1+%i; aPlusPi=a+%pi; disp(aPlusPi);exit;" -nb</programlisting>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-f file</term>
-                <listitem>
-                    <para>If this option is present then Scilab script
-                        <literal>file</literal> is executed first (just after startup file
-                        execution) into Scilab. <literal>-e</literal> and
-                        <literal>-f</literal> options are mutually exclusive.
+                    <para>
+                        A file with .xcos extension will be opened by Xcos.
                     </para>
-                    <para>A file with .xcos extension will be opened by Xcos.</para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                     <para>If this option is present it fixes the user language.
                         <emphasis>lang</emphasis> can be: <emphasis>ca_ES de_DE en_US es_ES
                             fr_FR ja_JP pt_BR ru_RU zh_CN zh_TW
-                        </emphasis>
-                        (from Scilab
-                        5.2).
+                        </emphasis> (from Scilab 5.2).
                     </para>
                     <para>
                         Other possible <literal>lang</literal> values are
                         <literal>'fr'</literal> for french and <literal>'en'</literal> for
                         English for compatibility reasons. The default language is English.
-                        This default value is fixed the <literal>scilab.start</literal>
-                        file.
+                        This default value is fixed the <literal>scilab.start</literal> file.
                     </para>
                     <para>On some systems, locales must be compiled to render correctly
                         UTF-8 fonts.
                     </para>
                     <para>Scilab can be also called the following way:</para>
-                    <programlisting role="no-scilab-exec">LANG=ja_JP scilab
-                        # equivalent to
-                        scilab -l ja_JP
-                    </programlisting>
+                    <screen><![CDATA[ LANG=ja_JP scilab
+ # equivalent to
+ scilab -l ja_JP
+]]></screen>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-nb</term>
                 <listitem>
-                    <para>If this option is present then the Scilab loading message not displayed.
+                    <para>"no banner": Cancels the display of the Scilab's loading message.
                     </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-ns</term>
                 <listitem>
-                    <para>If this option is present the startup file
-                        <literal>SCI/etc/scilab.start</literal> and the user startup files
+                    <para>"No Startup files": Cancels the execution of the main startup file
+                        <literal>SCI/etc/scilab.start</literal> and of the user startup files
                         <literal>SCIHOME/.scilab</literal>,
-                        <literal>SCIHOME/scilab.ini</literal> are not executed.
+                        <literal>SCIHOME/scilab.ini</literal>.
                     </para>
                     <para>This option will disable many features in Scilab (Only use if
                         you know what you are doing).
             <varlistentry>
                 <term>-nouserstartup</term>
                 <listitem>
-                    <para>If this option is present the user startup files
-                        <literal>SCIHOME/.scilab</literal>,
-                        <literal>SCIHOME/scilab.ini</literal> are not executed.
+                    <para>Cancels the execution of the user startup files
+                        <literal>SCIHOME/.scilab</literal> and
+                        <literal>SCIHOME/scilab.ini</literal>.
                     </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-noatomsautoload</term>
                 <listitem>
-                    <para>If this option is present the ATOMS modules previously installed are not loaded for this session.</para>
+                    <para>Cancels the autoloading of installed ATOMS modules at startup.</para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                     <para>If this option is present, Scilab is started as command line
                         with advanced features still available (graphics, export, xcos, scinotes, help browser, ...).
                     </para>
-                    <para>
-                        This option may be used with <literal>-f</literal> or <literal>-e</literal> options.
-                    </para>
                     <para>From Scilab 5.2:</para>
                     <itemizedlist>
                         <listitem>
-                            <para>Scilab distribution also provides a dedicated binary which
-                                is doing the same as <literal>-nw</literal>: <literal>scilab-adv-cli</literal> (Scilab Advanced
-                                Command Line Interpreter).
+                            <para>pipes are enabled for all operating systems (see the
+                                examples for further details).
                             </para>
                         </listitem>
                         <listitem>
-                            <para>pipes are enabled for all operating systems (see the
-                                examples for further details).
+                            <para>Scilab distribution also provides a dedicated binary which
+                                is doing the same as <literal>-nw</literal>:
+                                <literal>scilab-adv-cli</literal> (Scilab Advanced Command Line Interpreter).
                             </para>
                         </listitem>
                     </itemizedlist>
             <varlistentry>
                 <term>-nwni / -nogui</term>
                 <listitem>
+                    <important>
+                        This mode prevents loading the Java Virtual Machine.
+                        It starts faster and uses less memory.
+                    </important>
                     <para>If this option is present, Scilab is started as command line
-                        without advanced features (graphics, export, xcos, scinotes, help browser, ...).
-                    </para>
-                    <para>
-                        This option may be used with <literal>-f</literal> or <literal>-e</literal> options.
+                        without advanced features (graphics, export, xcos, scinotes,
+                        help browser, Java module,...).
                     </para>
-                    <para>From Scilab 5.2:</para>
+                    <para>Since Scilab 5.2:</para>
                     <itemizedlist>
                         <listitem>
-                            <para>Scilab distribution also provides a dedicated binary which
-                                is doing the same as <literal>-nwni</literal>: <literal>scilab-cli</literal> (Scilab Command Line Interpreter).
+                            <para>pipes are enabled for all operating systems (see the
+                                examples for further details).
                             </para>
                         </listitem>
                     </itemizedlist>
                     <itemizedlist>
                         <listitem>
-                            <para>pipes are enabled for all operating systems (see the
-                                examples for further details).
+                            <para>Scilab distribution also provides a dedicated binary which
+                                is doing the same as <literal>-nwni</literal>:
+                                <literal>scilab-cli</literal> (Scilab Command Line Interpreter).
                             </para>
                         </listitem>
                     </itemizedlist>
-                    <para>This mode does not load the Java Virtual Machine (faster to
-                        start and uses less memory).
-                    </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>--texmacs</term>
                 <listitem>
-                    <para>This option is reserved for TeXMacs.</para>
-                    <para>
-                        Please install ATOMS module: <programlisting role="">atomsInstall('texmacs')</programlisting>
+                    <para>This option is reserved for the external TeXMacs module.
+                        This one can be priorly installed with <code>atomsInstall('texmacs')</code>.
                     </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-version</term>
                 <listitem>
-                    <para>This option prints product version and exits.</para>
+                    <para>displays the Scilab's version (before the main Scilab's startup).</para>
+                </listitem>
+            </varlistentry>
+        </variablelist>
+    </refsection>
+    <refsection role="arguments">
+        <title>Additional options for Unix/Linux and Mac OS X</title>
+        <para>Advice: use theses options on a Scilab source tree.</para>
+        <variablelist>
+            <varlistentry>
+                <term>-debug</term>
+                <listitem>
+                    <para>Start Scilab under the debugger gdb.</para>
+                    <para>
+                        The variable <literal>SCILAB_GDB_OPT</literal> may be set to add custom options to gdb.
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-debug-kdbg</term>
+                <listitem>
+                    <para>Start Scilab under kdbg.</para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-profiling</term>
+                <listitem>
+                    <para>Start Scilab under valgrind.</para>
+                    <para>The variable SCILAB_VALGRIND_OPT may be set to add custom options
+                        to valgrind (and override the existing valgrind options).
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-profiling-visu</term>
+                <listitem>
+                    <para>Start Scilab under callgrind.</para>
+                    <para>The variable SCILAB_VALGRIND_OPT may be set to add custom options
+                        to callgrind (and override the existing callgrind options).
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-electric-fence</term>
+                <listitem>
+                    <para>Start Scilab with the Electric Fence.</para>
                 </listitem>
             </varlistentry>
         </variablelist>
     </refsection>
     <refsection role="description">
-        <title>Description of environment variables</title>
+        <title>Environment variables</title>
         <variablelist>
             <varlistentry>
                 <term>SCIVERBOSE</term>
     </refsection>
     <refsection role="description">
         <title>Java Virtual Machine options</title>
+        <warning>
+            The options described here-below are useless and are cancelled if the option <literal>-nwni</literal> is used.
+        </warning>
         <para>Starting from Scilab 5.0, the graphical user interface (GUI) and the
             build documentation are based on Java features. In some cases, it can be
             important to edit the JVM options (Java Virtual Machine).
     </refsection>
     <refsection role="examples">
         <title>Examples</title>
-        <programlisting role="no-scilab-exec"><![CDATA[
+        <screen><![CDATA[
 # Let's start Scilab in profiling mode without attaching a gdb once a SIGSEGV is met.
 # We are under Bash shell
 export SCILAB_VALGRIND_OPT="--db-attach=no --log-file=myfile.txt"
@@ -367,8 +441,9 @@ echo "handle SIGSEGV nostop" &> debug.txt
 # We are under Bash shell
 export SCILAB_GDB_OPT="--command=debug.txt"
 # Start Scilab in debug mode
-scilab -debug]]></programlisting>
-        <programlisting role="no-scilab-exec"><![CDATA[
+scilab -debug ]]></screen>
+        <para></para>
+        <screen><![CDATA[
 # Under GNU/Linux, Mac OS X or Unix:
 $ echo "disp(%pi)"|scilab-cli
 or
@@ -382,16 +457,31 @@ $ scilab -nw -e "help()"
 
 # Scilab can be used for scripting aspects:
 echo "if 1<>2 then exit(99) end"|scilab-cli
-echo $? ]]></programlisting>
+echo $? ]]></screen>
     </refsection>
     <refsection role="see also">
         <title>See also</title>
         <simplelist type="inline">
             <member>
-                <link linkend="exit">exit</link>
+                <link linkend="startup">startup</link>
             </member>
             <member>
-                <link linkend="startup">startup</link>
+                <link linkend="sciargs">sciargs</link>
+            </member>
+            <member>
+                <link linkend="getpid">getpid</link>
+            </member>
+            <member>
+                <link linkend="getenv">getenv</link>
+            </member>
+            <member>
+                <link linkend="getenv">getversion</link>
+            </member>
+            <member>
+                <link linkend="consolebox">consolebox</link>
+            </member>
+            <member>
+                <link linkend="exit">exit</link>
             </member>
         </simplelist>
     </refsection>
index a87652f..5e1530c 100644 (file)
@@ -1,34 +1,89 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns4="http://www.w3.org/1999/xhtml" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org" xml:id="scilab" xml:lang="fr">
+<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"
+        xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns4="http://www.w3.org/1999/xhtml"
+        xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook"
+        xmlns:scilab="http://www.scilab.org" xml:id="scilab" xml:lang="fr">
+    <refnamediv xml:id="wscilex">
+    </refnamediv>
+    <refnamediv xml:id="scilex">
+    </refnamediv>
     <refnamediv>
-        <refname>scilab</refname>
-        <refpurpose>Script principal d'exécution de Scilab et de divers
-            outils (GNU/Linux, Unix et Mac OS X)
+        <refname>scilex | scilab</refname>
+        <refpurpose>lance Scilab en mode interactif ou batch avec options
         </refpurpose>
     </refnamediv>
     <refsynopsisdiv>
-        <title>Séquence d'appel</title>
-        <synopsis>scilab &lt;Options&gt;
-            scilab-adv-cli &lt;Options&gt;
-            scilab-cli &lt;Options&gt;
+        <title>Syntaxe</title>
+        <synopsis>
+#      MS Windows          |  # Linux / Unix / Mac OS X
+wscilex     &lt;Options&gt;     |  scilab         &lt;Options&gt;
+wscilex -nw &lt;Options&gt; |  scilab-adv-cli &lt;Options&gt;
+scilex      &lt;Options&gt;      |  scilab-cli     &lt;Options&gt;
         </synopsis>
     </refsynopsisdiv>
     <refsection role="arguments">
-        <title>Paramètres</title>
+        <title>Options</title>
         <variablelist>
             <varlistentry>
-                <term>-args arguments</term>
+                <term>-args arg#1 arg#2 ..</term>
                 <listitem>
-                    <para>si cette option est présente des arguments sont passés à
-                        Scilab. Ils peuvent être récupérés par la fonction
-                        <literal>
-                            <link linkend="sciargs">sciargs</link>
-                        </literal>
-                        .Les arguments multiples
-                        doivent être passés dans chaîne de caractères les contenant, séparés
-                        par des espaces <literal>scilab -args 'foo1 foo2';</literal>.
-                        Sans cette option, les arguments inconnus ne seront pas acceptés.
+                    <para>
+                        Cette option permet de transmettre des données à la session Scilab à ouvrir :
+                        <itemizedlist>
+                            <listitem>Des données consécutives sont séparées par un ou plusieurs espaces.
+                            </listitem>
+                            <listitem>Une expression entre guillemets <literal>"</literal> constitue une donnée unique.
+                            </listitem>
+                            <listitem>Pour inclure un guillemet dans une donnée, écrire <literal>\"</literal> au lieu de <literal>"</literal>.
+                            </listitem>
+                            <listitem>L'apostrophe <literal>'</literal> est un caractère normal. Il n'a pas de signification particulière.
+                            </listitem>
+                        </itemizedlist>
                     </para>
+                    <para>
+                      Dans la session ouverte, les données <literal>arg#1, arg#2, ..</literal> peuvent être récupérées comme autant d'expressions texte avec <link linkend="sciargs">sciargs()</link>.
+                     </para>
+                     <para>
+                      Exemple :
+                        <screen><![CDATA[C:\Users\Me> scilex -nb -args "Hello \"%USERNAME%\"" 1.2345 \"%cd%\" ]]></screen>
+                        <programlisting><![CDATA[
+// Dans la session ouverte :
+a = sciargs()
+i = find(a=="-args")
+a(i+1)
+evstr(a(i+2))*2
+"Cette session a été lancée depuis " + a(i+3)
+                        ]]>
+                        </programlisting>
+                        <screen><![CDATA[
+--> // Dans la session ouverte :
+--> a = sciargs()
+ a  =
+!c:\SCIdir\bin\scilex  -nw  -nb  -noatomsautoload  -args  Hello "John"  1.2345  "C:\Users\Me" !
+
+--> i = find(a=="-args")
+ i  =
+    5.
+
+--> a(i+1)
+ ans  =
+ Hello "John"
+
+--> evstr(a(i+2))*2
+ ans  =
+    2.469
+
+--> "Cette session a été lancée depuis " + a(i+3)
+ ans  =
+ Cette session a été lancée depuis "C:\Users\Me"
+
+-->
+]]></screen>
+                     </para>
+                     <para>
+                     <note>Utiliser <literal>-args</literal> comme <emphasis role="italic">dernière</emphasis> option sur la ligne de commande est plus sûr.
+                     </note>
+                     </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 </listitem>
             </varlistentry>
             <varlistentry>
-                <term>-debug</term>
-                <listitem>
-                    <para>Lance Scilab sous gdb (Unix/Linux/Mac OS X seulement).</para>
-                    <para>Définir la variable SCILAB_GDB_OPT pour ajouter des options
-                        supplémentaire à gdb.
-                    </para>
-                    <para>Conseil: Utilisez cette option à partir de l'arborescence
-                        source de Scilab
-                    </para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-debug-kdbg</term>
-                <listitem>
-                    <para>Lance Scilab sous kdbg (Unix/Linux/Mac OS X seulement).</para>
-                    <para>Conseil: Utilisez cette option à partir de l'arborescence
-                        source de Scilab
-                    </para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-profiling</term>
-                <listitem>
-                    <para>Lance Scilab sous valgrind (Unix/Linux/Mac OS X seulement).</para>
-                    <para>Définir la variable SCILAB_VALGRIND_OPT pour ajouter des
-                        options supplémentaire à valgrind (et surcharger les options de
-                        valgrind existantes).
-                    </para>
-                    <para>Conseil: Utilisez cette option à partir de l'arborescence
-                        source de Scilab
-                    </para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-profiling-visu</term>
-                <listitem>
-                    <para>Lance Scilab sous callgrind (Unix/Linux/Mac OS X seulement).</para>
-                    <para>Définir la variable SCILAB_VALGRIND_OPT pour ajouter des
-                        options supplémentaires à callgrind (et surcharger les options de
-                        callgrind existante).
-                    </para>
-                    <para>Conseil: Utilisez cette option à partir de l'arborescence
-                        source de Scilab
-                    </para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-electric-fence</term>
-                <listitem>
-                    <para>Lance Scilab sous Electric Fence (Unix/Linux/Mac OS X seulement).</para>
-                    <para>Conseil: Utilisez cette option à partir de l'arborescence
-                        source de Scilab
-                    </para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-e Instruction</term>
+                <term>-e Instructions</term>
                 <listitem>
-                    <para>si cette option est présente l'instruction
-                        <literal>Instruction</literal> est exécutée dans Scilab
-                        immédiatement après les fichiers startup.
-                    </para>
-                    <para>Plusieurs commandes peuvent être indiquées à la suite avec
-                        l'option -e:
-                    </para>
                     <para>
-                        <programlisting>scilab-cli -e  "a=1+%i; aPlusPi=a+%pi; disp(aPlusPi);exit;" -nb</programlisting>
-                    </para>
+                        À l'issue du démarrage complet de la session, cette option
+                        <itemizedlist>
+                            <listitem>
+                                <para>fixe le dossier de travail de Scilab au dossier système depuis lequel Scilab a été lancé. Voir l'exemple donné plus bas pour l'option <literal>-f</literal>. Puis,
+                                </para>
+                            </listitem>
+                            <listitem>
+                                <para>éxécute les <literal>Instructions</literal> Scilab indiquées. Exemple :
+                                    <screen><![CDATA[ scilab-cli -e  "disp(\"Hello\"); a=%pi+%i; disp(exp(a)); exit;" -nb ]]></screen>
+                                </para>
+                            </listitem>
+                        </itemizedlist>
+                    </para>
+                    <warning>
+                        Les options <literal>-e</literal> et <literal>-f</literal> ne peuvent pas être utilisées ensemble.
+                    </warning>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-f Fichier</term>
                 <listitem>
                     <para>
-                        si cette option est présente le script <literal>Fichier</literal>
-                        est exécuté dans Scilab mmédiatement après les fichiers startup. -f
-                        et -e ne peuvent pas être utilisée en même temps.
+                        Si cette option est indiquée, alors au début de la session Scilab, après l'exécution des fichiers de démarrage de Scilab et de l'utilisateur, et après l'activation des Préférences de l'utilisateur -- dont celles concernant le dossier de travail par défaut --,
+                        <itemizedlist>
+                            <listitem>
+                                <para>
+                                    le dossier de travail de Scilab est fixé au dossier système depuis lequel Scilab a été lancé. Par exemple,
+                                    <screen><![CDATA[D:\users\me\scilab\dev> C:\scilab-5.5.2\bin\scilex -f ..\test.sce]]></screen>
+                                    exécutera <literal>cd("D:\users\me\scilab\dev")</literal>.
+                                </para>
+                            </listitem>
+                            <listitem>
+                                <para>
+                                    le script Scilab <literal>Fichier</literal> est exécuté. S'il est indiqué avec un chemin relatif (<literal>.\</literal> par défaut, ou tel que <literal>..\</literal> dans l'exemple ci-dessus), celui-ci se réfère au nouveau dossier de travail de Scilab.
+                                </para>
+                            </listitem>
+                        </itemizedlist>
+                    </para>
+                    <para>
+                        Un fichier avec l'extension .xcos sera ouvert par Xcos.
                     </para>
-                    <para>Un fichier avec l'extension .xcos sera ouvert par Xcos.</para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                     <para>
                         Les valeurs possible pour sont <literal>-l fr</literal> pour
                         sélectionner le francais et <literal>-l en</literal> pour
-                        sélectionner l'anglais. La langue par défaut est l'anglais, ce
-                        défaut est fixé dans le fichier
+                        sélectionner l'anglais. La langue par défaut est établie à l'anglais dans le fichier
                         <literal>scilab.start</literal>.
                     </para>
                     <para>Avec certains systèmes, la compilation des locales peut être
                         nécessaire pour rendre correctement les polices UTF-8.
                     </para>
                     <para>Scilab peut être aussi appellé de la manière suivante:</para>
-                    <programlisting>LANG=ja_JP scilab
-                        # équivalent à
-                        scilab -l ja_JP
-                    </programlisting>
+                    <screen><![CDATA[ LANG=ja_JP scilab
+ # équivalent à
+ scilab -l ja_JP
+]]></screen>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-nb</term>
                 <listitem>
-                    <para>si cette option est présente le message de chargement de Scilab n'est pas affiché.
+                    <para>"no banner" : supprime l'affichage du message de chargement de Scilab.
                     </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-ns</term>
                 <listitem>
-                    <para>si cette option est présente le script de démarrage
+                    <para>"no startup" : supprime l'éxécution du script de démarrage
                         "principal" <literal>SCI/etc/scilab.start</literal> ainsi que les
                         fichiers de démarrage "utilisateur"
                         <literal>SCIHOME/.scilab</literal> et
                         <literal>SCIHOME/scilab.ini</literal> ne sont pas pas
                         exécutés.
                     </para>
-                    <para>L'utilisation de cette option désactivera de nombreuses
-                        fonctionnalités de Scilab (Ne l'utilisez que si vous savez ce que
-                        vous faites).
-                    </para>
+                    <warning>
+                        Cette option désactive de nombreuses fonctionnalités de Scilab.
+                        À utiliser avec expertise et discernement.
+                    </warning>
                 </listitem>
             </varlistentry>
             <varlistentry>
             <varlistentry>
                 <term>-noatomsautoload</term>
                 <listitem>
-                    <para>Si cette option est fournie, les modules ATOMS précédemment installés ne sont pas chargés durant cette session.</para>
+                    <para>
+                        supprime le chargement en début de session des modules ATOMS installés.
+                    </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-nw</term>
                 <listitem>
-                    <para>si cette option est présente Scilab est lancé en tant que
-                        interpreteur de commande avancé (graphiques, fonctionnalité de
-                        construction de l'aide, etc).
-                    </para>
-                    <para>The option peut être utilisé avec les arguments -f ou
-                        -e.
+                    <para>si cette option est présente, Scilab est lancé en tant
+                        qu'interprêteur de commandes avancé : la console est sans
+                        menus, mais les fonctionnalités Java sont disponibles
+                        (graphiques, export, xcos, scinotes, navigateur d'aide,
+                        module JIMS, etc).
                     </para>
                     <para>A partir de la version 5.2 de Scilab:</para>
                     <itemizedlist>
             <varlistentry>
                 <term>-nwni / -nogui</term>
                 <listitem>
-                    <para>si cette option est présente Scilab est lancé en tant que
-                        interpreteur de commande (sans graphique, ni fonctionnalité de
-                        construction de l'aide, etc).
-                    </para>
-                    <para>The option peut être utilisé avec les arguments -f ou
-                        -e.
+                    <important>
+                        Cette option supprime le chargement de la Machine Virtuelle Java en mémoire.
+                        Elle accélère le démarrage de Scilab et réduit la mémoire consommée.
+                    </important>
+                    <para>si cette option est présente, Scilab est lancé en tant
+                        qu'interprêteur de commandes (sans graphiques ni interfaces
+                        ni fonctionnalité de construction de l'aide, etc).
                     </para>
                     <para>A partir de la version 5.2 de Scilab:</para>
                     <itemizedlist>
                         <listitem>
+                            <para>Les fonctionnalités de pipe sont accessibles pour tous les
+                                systèmes d'exploitations (voir les exemples pour plus de
+                                détails)
+                            </para>
+                        </listitem>
+                        <listitem>
                             <para>La distribution de Scilab fournit aussi un binaire dédié
                                 faisant la même chose que l'option <emphasis>-nw</emphasis>:
                                 <emphasis>scilab-cli</emphasis> (Scilab Command Line
                                 Interpreter).
                             </para>
                         </listitem>
-                        <listitem>
-                            <para>Les fonctionnalités de pipe sont accessibles pour tous les
-                                systèmes d'exploitations (voir les examples pour plus de
-                                détails)
-                            </para>
-                        </listitem>
                     </itemizedlist>
-                    <para>Ce mode ne charge pas la Machine Virtuelle Java (plus rapide à
-                        démarer et consomme moins de mémoire).
-                    </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>--texmacs</term>
                 <listitem>
-                    <para>Cette option est réservée pour TeXMacs.</para>
-                    <para>Veuillez installer le module ATOMS atomsInstall('texmacs')</para>
+                    <para>Cette option est réservée au module externe TeXMacs.</para>
+                    <para>
+                        Celui-ci peut être préalablement installé avec <code>atomsInstall('texmacs')</code>
+                    </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
             </varlistentry>
         </variablelist>
     </refsection>
+    <refsection role="arguments">
+        <title>Options supplémentaires sous Unix/Linux ou Mac OS X</title>
+        <para>Conseil: utiliser ces options à partir de l'arborescence source de Scilab.</para>
+        <variablelist>
+            <varlistentry>
+                <term>-debug</term>
+                <listitem>
+                    <para>Lance Scilab sous gdb.</para>
+                    <para>Définir la variable SCILAB_GDB_OPT pour ajouter des options
+                        supplémentaire à gdb.
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-debug-kdbg</term>
+                <listitem>
+                    <para>Lance Scilab sous kdbg.</para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-profiling</term>
+                <listitem>
+                    <para>Lance Scilab sous valgrind.</para>
+                    <para>Définir la variable SCILAB_VALGRIND_OPT pour ajouter des
+                        options supplémentaire à valgrind (et surcharger les options de
+                        valgrind existantes).
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-profiling-visu</term>
+                <listitem>
+                    <para>Lance Scilab sous callgrind.</para>
+                    <para>Définir la variable SCILAB_VALGRIND_OPT pour ajouter des
+                        options supplémentaires à callgrind (et surcharger les options de
+                        callgrind existante).
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-electric-fence</term>
+                <listitem>
+                    <para>Lance Scilab sous Electric Fence.</para>
+                </listitem>
+            </varlistentry>
+        </variablelist>
+    </refsection>
     <refsection role="description">
-        <title>Description des variables d'environnement</title>
+        <title>Variables d'environnement</title>
         <variablelist>
             <varlistentry>
                 <term>SCIVERBOSE</term>
         </variablelist>
     </refsection>
     <refsection role="description">
-        <title>Java Virtual Machine options</title>
+        <title>Options JVM (Java Virtual Machine)</title>
+        <para>
+            Les options décrites ci-dessous sont inutiles et sans effet lorsque l'option <literal>-nwni</literal> est utilisée.
+        </para>
         <para>A partir de la version 5.0 de Scilab, l'interface graphique et le
             système de génération de la documentation sont basés sur des
             fonctionnalités Java. Dans certains cas, il peut être intéressant de
     </refsection>
     <refsection role="examples">
         <title>Exemples</title>
-        <programlisting role="example">
-            # Lançons Scilab en mode profilage sans qu'un gdb soit lancé à chaque SIGSEGV.
-            # On est sous Bash
-            export SCILAB_VALGRIND_OPT="--db-attach=no --log-file=myfile.txt"
-            scilab -profiling
-
-            # Lançons Scilab en mode debug sans s'arrêter à chaque SIGSEGV
-            # D'abord écrivons un petit fichier de commandes
-            echo "handle SIGSEGV nostop" &amp;gt; debug.txt
-            # On règle l'option de gdb
-            # On est sous Bash
-            export SCILAB_GDB_OPT="--command=debug.txt"
-            # Lançons Scilab en mode debug
-            scilab -debug
-        </programlisting>
-        <programlisting role="example-cli">
-            # Sous GNU/Linux, Mac OS X or Unix:
-            $ echo "disp(%pi)"|scilab-cli
-            ou
-            $ echo "disp(%pi)"|scilab -nwni
+        <screen><![CDATA[
+# Lançons Scilab en mode profilage sans qu'un gdb soit lancé à chaque SIGSEGV.
+# On est sous Bash
+export SCILAB_VALGRIND_OPT="--db-attach=no --log-file=myfile.txt"
+scilab -profiling
 
-            # Ouvre uniquement la fenêtre d'aide Scilab:
-            $ scilab-adv-cli -e "help()"
-            or
-            $ scilab -nw -e "help()"
+# Lançons Scilab en mode debug sans s'arrêter à chaque SIGSEGV
+# D'abord écrivons un petit fichier de commandes
+echo "handle SIGSEGV nostop" &amp;gt; debug.txt
+# On règle l'option de gdb
+# On est sous Bash
+export SCILAB_GDB_OPT="--command=debug.txt"
+# Lançons Scilab en mode debug
+scilab -debug ]]></screen>
+        <para></para>
+        <screen><![CDATA[
+# Sous GNU/Linux, Mac OS X or Unix:
+$ echo "disp(%pi)"|scilab-cli
+ou
+$ echo "disp(%pi)"|scilab -nwni
 
+# Ouvre uniquement la fenêtre d'aide Scilab:
+$ scilab-adv-cli -e "help()"
+or
+$ scilab -nw -e "help()"
 
-            # Scilab utilisé en tant que moteur de scripting
-            echo "if 1&lt;&gt;2 then exit(99) end"|scilab-cli
-            echo $?
-        </programlisting>
+# Scilab utilisé en tant que moteur de scripting
+echo "if 1&lt;&gt;2 then exit(99) end"|scilab-cli
+echo $? ]]></screen>
     </refsection>
     <refsection role="see also">
         <title>Voir aussi</title>
         <simplelist type="inline">
             <member>
-                <link linkend="exit">exit</link>
+                <link linkend="startup">startup</link>
             </member>
             <member>
-                <link linkend="startup">startup</link>
+                <link linkend="sciargs">sciargs</link>
+            </member>
+            <member>
+                <link linkend="getpid">getpid</link>
+            </member>
+            <member>
+                <link linkend="getenv">getenv</link>
+            </member>
+            <member>
+                <link linkend="getenv">getversion</link>
+            </member>
+            <member>
+                <link linkend="consolebox">consolebox</link>
+            </member>
+            <member>
+                <link linkend="exit">exit</link>
             </member>
         </simplelist>
     </refsection>
index ae34c3b..796fc37 100644 (file)
 <?xml version="1.0" encoding="UTF-8"?>
-
-<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns4="http://www.w3.org/1999/xhtml" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org" xml:id="scilab" xml:lang="ja">
-
+<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"
+    xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns4="http://www.w3.org/1999/xhtml"
+    xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook"
+    xmlns:scilab="http://www.scilab.org" xml:id="scilab" xml:lang="ja">
+    <refnamediv xml:id="wscilex">
+    </refnamediv>
+    <refnamediv xml:id="scilex">
+    </refnamediv>
     <refnamediv>
-
-        <refname>scilab</refname>
-
+        <refname>scilex | scilab</refname>
         <refpurpose>
-
             Scilabおよび関連ツールを起動するためのツール
-
-            (GNU/Linux, Unix および Mac OS X)
-
         </refpurpose>
-
     </refnamediv>
-
     <refsynopsisdiv>
-
         <title>呼出し手順</title>
-
-        <synopsis>scilab &lt;Options&gt;
-
-            scilab-adv-cli &lt;Options&gt;
-
-            scilab-cli &lt;Options&gt;
-
+        <synopsis>
+#      MS Windows          |  # Linux / Unix / Mac OS X
+wscilex     &lt;Options&gt;     |  scilab         &lt;Options&gt;
+wscilex -nw &lt;Options&gt; |  scilab-adv-cli &lt;Options&gt;
+scilex      &lt;Options&gt;      |  scilab-cli     &lt;Options&gt;
         </synopsis>
-
     </refsynopsisdiv>
-
     <refsection role="arguments">
-
         <title>説定</title>
-
         <variablelist>
-
             <varlistentry>
-
-                <term>-args Arguments</term>
-
+                <term>-args arg#1 arg#2 ..</term>
                 <listitem>
-
                     <para>
-
-                        このオプションが存在する場合,引数がScilabに渡されます.
-
-                        これらは,<link linkend="sciargs">sciargs</link>関数で取得することが
-
-                        できます.
-
-                        複数の引数を指定する場合,以下のように一連の複数の単語を引用符で括り,
-
-                        空白で分割してください: <literal>scilab -args 'foo1 foo2'</literal>.
-
-                        このオプションを指定しない場合,未知の引数は受け付けられません.
-
+                        This option allows to send some data to the Scilab session:
+                        <itemizedlist>
+                            <listitem>Consecutive data are separated by one or several spaces.
+                            </listitem>
+                            <listitem>An expression between double-quotes is a single data.
+                            </listitem>
+                            <listitem>To include a double-quote in a data, write <literal>\"</literal> instead of <literal>"</literal>.
+                            </listitem>
+                            <listitem>The single quote <literal>'</literal> is a regular character. It has no special meaning.
+                            </listitem>
+                        </itemizedlist>
                     </para>
-
+                    <para>
+                      Inside the opened session, these data can be retrieved as separated strings with <link linkend="sciargs">sciargs()</link>.
+                     </para>
+                     <para>
+                      Example:
+                        <screen><![CDATA[C:\Users\Me> scilex -nb -args "Hello \"%USERNAME%\"" 1.2345 \"%cd%\"]]></screen>
+                        <programlisting><![CDATA[
+// Inside the opened session:
+a = sciargs()
+i = find(a=="-args")
+a(i+1)
+evstr(a(i+2))*2
+"This session has been launched from " + a(i+3)
+                        ]]>
+                        </programlisting>
+                        <screen><![CDATA[
+--> // Inside the opened session:
+--> a = sciargs()
+ a  =
+!c:\SCIdir\bin\scilex  -nw  -nb  -noatomsautoload  -args  Hello "John"  1.2345  "C:\Users\Me" !
+
+--> i = find(a=="-args")
+ i  =
+    5.
+
+--> a(i+1)
+ ans  =
+ Hello "John"
+
+--> evstr(a(i+2))*2
+ ans  =
+    2.469
+
+--> "This session has been launched from " + a(i+3)
+ ans  =
+ This session has been launched from "C:\Users\Me"
+
+-->
+]]></screen>
+                     </para>
+                     <para>
+                     <note>Using <literal>-args</literal> as the <emphasis role="italic">last</emphasis> command line option is safer.
+                     </note>
+                     </para>
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>-display Display</term>
-
                 <listitem>
-
                     <para>
-
                         Xwindow システム上でのみ使用可能で, 表示する
-
                         Xサーバーを指定します.
-
                         デフォルトの表示先は unix:0.0 です.
-
                     </para>
-
                     <para>
-
                         <literal>-display</literal> は,
-
                         <literal>-d</literal>と短縮形で指定できます.
-
-                    </para>
-
-                </listitem>
-
-            </varlistentry>
-
-            <varlistentry>
-
-                <term>-debug</term>
-
-                <listitem>
-
-                    <para>デバッガgdb上でScilabを開始します(Unix/Linux/Mac OS Xのみ).</para>
-
-                    <para>
-
-                        gdb にカスタムオプションを追加する場合,
-
-                        変数<literal>SCILAB_GDB_OPT</literal>を定義します.
-
-                    </para>
-
-                    <para>助言: このオプションをScilabソースツリー上で使用してください.</para>
-
-                </listitem>
-
-            </varlistentry>
-
-            <varlistentry>
-
-                <term>-debug-kdbg</term>
-
-                <listitem>
-
-                    <para>kdbg上でScilabを開始します (Unix/Linux/Mac OS X のみ).</para>
-
-                    <para>助言: このオプションをScilabソースツリー上で使用してください.</para>
-
-                </listitem>
-
-            </varlistentry>
-
-            <varlistentry>
-
-                <term>-profiling</term>
-
-                <listitem>
-
-                    <para>valgrind上でScilabを開始します (Unix/Linux/Mac OS X のみ).</para>
-
-                    <para>
-
-                        valgrind にカスタムオプションを追加する場合
-
-                        (および既存の valgrind オプションを上書きする場合),SCILAB_VALGRIND_OPT
-
-                        を定義してください.
-
                     </para>
-
-                    <para>助言: このオプションをScilabソースツリー上で使用してください.</para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
-                <term>-profiling-visu</term>
-
-                <listitem>
-
-                    <para>callgrind上でScilabを開始します (Unix/Linux/Mac OS X のみ).</para>
-
-                    <para>
-
-                        callgrind にカスタムオプションを追加する場合
-
-                        (および既存の callgrind オプションを上書きする場合),SCILAB_VALGRIND_OPT
-
-                        を定義してください.
-
-                    </para>
-
-                    <para>助言: このオプションをScilabソースツリー上で使用してください.</para>
-
-                </listitem>
-
-            </varlistentry>
-
-            <varlistentry>
-
-                <term>-electric-fence</term>
-
-                <listitem>
-
-                    <para>Electric Fence を指定して Scilab を開始します(Unix/Linux/Mac OS Xのみ).</para>
-
-                    <para>助言: このオプションをScilabソースツリー上で使用してください.</para>
-
-                </listitem>
-
-            </varlistentry>
-
-            <varlistentry>
-
-                <term>-e 命令</term>
-
+                <term>-e Instructions</term>
                 <listitem>
-
-                    <para>
-
-                        このオプションを指定すると Scilab 命令
-
-                        <literal>Instruction</literal> が(スタートアップファイルの実行直後に)
-
-                        まずScilabで実行されます.
-
-                        <literal>-e</literal> および
-
-                        <literal>-f</literal> オプションは相互に排他的です.
-
-                    </para>
-
                     <para>
-                        <literal>-e</literal>により複数の命令を指定できることに注意してください.
+                        At the end of the whole session startup, this option
+                        <itemizedlist>
+                            <listitem>
+                                <para>sets the current working directory to the shell directory from which Scilab has been launched. Please see the example given here-below for the <literal>-f</literal> option. Then,
+                                </para>
+                            </listitem>
+                            <listitem>
+                                <para>executes Scilab <literal>Instructions</literal> provided in a string. Example:
+                                    <screen><![CDATA[ scilab-cli -e  "disp(\"Hello\"); a=%pi+%i; disp(exp(a)); exit;" -nb]]></screen>
+                                </para>
+                            </listitem>
+                        </itemizedlist>
                     </para>
-
-                    <programlisting role="no-scilab-exec">scilab-cli -e  "a=1+%i; aPlusPi=a+%pi; disp(aPlusPi);exit;" -nb</programlisting>
-
+                    <warning>
+                        <literal>-e</literal> および <literal>-f</literal> オプションは相互に排他的です.
+                    </warning>
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>-f file</term>
-
                 <listitem>
-
                     <para>
-
-                        このオプションを指定すると, Scilab はスクリプト <literal>file</literal>
-
-                        を(スタートアップファイルの実行直後,)Scilab上で最初に実行します.
-
-
-
-                        <literal>-e</literal> および
-
-                        <literal>-f</literal> オプションは相互に排他的です.
-
+                        If this option is used, then at the beginning of the Scilab session, after the execution of the scilab and user startup files, and after the setting of user Preferences -- including the working directory ones --,
+                        <itemizedlist>
+                            <listitem>
+                                <para>
+                                    the current Scilab working directory is set to the shell directory from which Scilab has been launched. For instance,
+                                    <screen><![CDATA[ D:\users\me\scilab\dev> C:\scilab-5.5.2\bin\scilex -f ..\test.sce]]></screen>
+                                    will do a <literal>cd("D:\users\me\scilab\dev")</literal>.
+                                </para>
+                            </listitem>
+                            <listitem>
+                                <para>
+                                    the Scilab script <literal>file</literal> is executed. If a relative path is used (default <literal>.\</literal>, or like <literal>..\</literal> in the sample here-above), it refers to the new Scilab working directory.
+                                </para>
+                            </listitem>
+                        </itemizedlist>
                     </para>
-
                     <para>.xcos 拡張子を有するファイルはXcosで開かれます.</para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
                 <term>-quit</term>
                 <listitem>
                     </para>
                 </listitem>
             </varlistentry>
-
             <varlistentry>
-
                 <term>-l lang</term>
-
                 <listitem>
-
                     <para>このオプションを指定した場合,
-
                         ユーザ言語を指定します.
-
                         <emphasis>lang</emphasis> は以下の値を指定できます: <emphasis>ca_ES de_DE en_US es_ES
-
                             fr_FR ja_JP pt_BR ru_RU zh_CN zh_TW
-
                         </emphasis>
-
                         (Scilab 5.2以降).
-
                     </para>
-
                     <para>
-
                         互換性維持のため,その他に <literal>lang</literal> の値は,フランス語として
-
                         <literal>'fr'</literal> および英語として <literal>'en'</literal> を使用可能です.
-
                         デフォルト値は,<literal>scilab.start</literal>ファイルで指定されます.
-
                     </para>
-
                     <para>いくつかのシステムでは,UTF-8フォントを正しく描画するために,
-
                         ロケールをコンパイルする必要があります.
-
                     </para>
-
                     <para>Scilab を以下のようにコールすることも可能です:</para>
-
-                    <programlisting role="no-scilab-exec">LANG=ja_JP scilab
-
-                        # これは以下と等価です
-
-                        scilab -l ja_JP
-
-                    </programlisting>
-
+                    <screen><![CDATA[ LANG=ja_JP scilab
+ # これは以下と等価です
+ scilab -l ja_JP
+]]></screen>
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>-nb</term>
-
                 <listitem>
-
-                    <para>
-
+                    <para>"no banner" :
                         このオプションが指定された場合, Scilabの Welcome バナーは表示されません.
-
                     </para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>-ns</term>
-
                 <listitem>
-
-                    <para>
-
+                    <para>"No Startup files" :
                         このオプションが指定された場合, スタートアップファイル
-
                         <literal>SCI/etc/scilab.start</literal> およびユーザスタートアップファイル
-
                         <literal>SCIHOME/.scilab</literal>,
-
                         <literal>SCIHOME/scilab.ini</literal> は実行されません.
-
                     </para>
-
                     <para>このオプションは, Scilabの多くの機能を無効にします (動作を理解している場合のみ
-
                         使用してください).
-
                     </para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>-nouserstartup</term>
-
                 <listitem>
-
                     <para>このオプションが指定された場合, スタートアップファイル
-
                         <literal>SCIHOME/.scilab</literal>,
-
                         <literal>SCIHOME/scilab.ini</literal> は実行されません.
-
                     </para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>-noatomsautoload</term>
-
                 <listitem>
-
                     <para>
-
                         このオプションが指定された場合,イントール済みのATOMモジュールは
-
                         このセッションでロードされません.
-
                     </para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>-nw</term>
-
                 <listitem>
-
                     <para>
-
                         このオプションが指定された場合, Scilab は
-
                         先進的な機能(グラフィック, export, xcos, scinotes, ヘルプブラウザ, ...)
-
                         と共にコマンドラインで起動されます.
-
                     </para>
-
-                    <para>
-                        このオプションは <literal>-f</literal>または <literal>-e</literal>
-
-                        オプションと同時に指定することができます.
-                    </para>
-
                     <para>Scilab 5.2以降:</para>
-
                     <itemizedlist>
-
                         <listitem>
-
+                            <para>全てのオペレーティングシステムについて
+                                パイプが有効です (詳細については例を参照ください).
+                            </para>
+                        </listitem>
+                        <listitem>
                             <para>Scilab のディストリビューションには,
-
                                 <literal>-nw</literal>と同様のバイナリを提供します:
-
                                 <literal>scilab-adv-cli</literal>
-
                                 (Scilab Advanced Command Line Interpreter).
-
                             </para>
-
                         </listitem>
-
-                        <listitem>
-
-                            <para>全てのオペレーティングシステムについて
-
-                                パイプが有効です (詳細については例を参照ください).
-
-                            </para>
-
-                        </listitem>
-
                     </itemizedlist>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>-nwni / -nogui</term>
-
                 <listitem>
-
+                    <important>このモードでは Java 仮想マシンはロードされません.
+                        (起動は高速化され,メモリ消費量は減少します)
+                    </important>
                     <para>このオプションが指定された場合, Scilab は先進的な機能
-
                         (グラフィック, export, xcos, scinotes, ヘルプブラウザ, ...)なしで
-
                         コマンドラインで起動されます.
-
-                    </para>
-
-                    <para>
-                        このオプションは <literal>-f</literal> または <literal>-e</literal>
-
-                        オプションと同時に指定することができます.
                     </para>
-
                     <para>Scilab 5.2以降:</para>
-
                     <itemizedlist>
-
                         <listitem>
-
+                            <para>全てのオペレーティングシステムについて
+                                パイプが有効です (詳細については例を参照ください).
+                            </para>
+                        </listitem>
+                        <listitem>
                             <para>
-
                                 Scilab のディストリビューションでは,
-
                                 <literal>-nwni</literal>と同じ専用バイナリが提供されています
-
                                 : <literal>scilab-cli</literal>
-
                                 (Scilab Command Line Interpreter).
-
-                            </para>
-
-                        </listitem>
-
-                    </itemizedlist>
-
-                    <itemizedlist>
-
-                        <listitem>
-
-                            <para>全てのオペレーティングシステムについて
-
-                                パイプが有効です (詳細については例を参照ください).
-
                             </para>
-
                         </listitem>
-
                     </itemizedlist>
-
-                    <para>このモードでは Java 仮想マシンはロードされません.
-
-                        (起動は高速化され,メモリ消費量は減少します)
-
-                    </para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>--texmacs</term>
-
                 <listitem>
-
                     <para>このオプションは TeXMacs用に予約されています.</para>
-
                     <para>
-
                         ATOMSモジュールをインストールしてください: <programlisting role="">atomsInstall('texmacs')</programlisting>
-
                     </para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>-version</term>
-
                 <listitem>
-
                     <para>このオプションはプロダクトのバージョンを出力し,終了します.</para>
-
                 </listitem>
-
             </varlistentry>
-
         </variablelist>
+    </refsection>
 
+    <refsection role="arguments">
+        <title>Additional options for Unix/Linux and Mac OS X</title>
+        <para>助言: これらのオプションをScilabソースツリー上で使用してください.</para>
+        <variablelist>
+            <varlistentry>
+                <term>-debug</term>
+                <listitem>
+                    <para>デバッガgdb上でScilabを開始します.</para>
+                    <para>
+                        gdb にカスタムオプションを追加する場合,
+                        変数<literal>SCILAB_GDB_OPT</literal>を定義します.
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-debug-kdbg</term>
+                <listitem>
+                    <para>kdbg上でScilabを開始します.</para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-profiling</term>
+                <listitem>
+                    <para>valgrind上でScilabを開始します.</para>
+                    <para>
+                        valgrind にカスタムオプションを追加する場合
+                        (および既存の valgrind オプションを上書きする場合),SCILAB_VALGRIND_OPT
+                        を定義してください.
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-profiling-visu</term>
+                <listitem>
+                    <para>callgrind上でScilabを開始します.</para>
+                    <para>
+                        callgrind にカスタムオプションを追加する場合
+                        (および既存の callgrind オプションを上書きする場合),SCILAB_VALGRIND_OPT
+                        を定義してください.
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-electric-fence</term>
+                <listitem>
+                    <para>Electric Fence を指定して Scilab を開始します.</para>
+                </listitem>
+            </varlistentry>
+        </variablelist>
     </refsection>
 
     <refsection role="description">
-
         <title>環境変数の説明</title>
-
         <variablelist>
-
             <varlistentry>
-
                 <term>SCIVERBOSE</term>
-
                 <listitem>
-
                     <para>
-
                         この変数が存在した場合, Scilab起動スクリプトは起動時デバッグ情報を表示します.
-
                         主にバグレポートおよびデバッグ目的で使用されます.
-
                     </para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>JAVA_HOME</term>
-
                 <listitem>
-
                     <para>
-
                         使用するJavaを指定します. 例えば,
-
                         <literal>JAVA_HOME=/usr/lib/jvm/java-7-openjdk/ scilab</literal> は
-
                         Java 7 でScilabを起動します.
-
                     </para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>SCI_DISABLE_TK</term>
-
                 <listitem>
-
                     <para>Tk (Tclではなく) 機能を無効にします.</para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>SCI_JAVA_ENABLE_HEADLESS</term>
-
                 <listitem>
-
                     <para>
-
                         ヘッドレスJava仮想マシン (すなわち,GUI機能なし).
-
                     </para>
-
                 </listitem>
-
             </varlistentry>
-
         </variablelist>
-
     </refsection>
-
     <refsection role="description">
-
         <title>Java 仮想マシンオプション</title>
-
+        <warning>
+            The options described here-below are useless and are cancelled if the option <literal>-nwni</literal> is used.
+        </warning>
         <para>Scilab 5.0以降, グラフィカルユーザインターフェイス (GUI) および
-
             ドキュメントの構築は,Java機能に基づいています.
-
             いくつかのケースでは,
-
             JVM (Java仮想マシン)オプションを編集することが重要となります.
-
         </para>
-
         <para>これらのオプションは,
-
             <emphasis>jvm_options.xml</emphasis>ファイルで利用可能です.
-
         </para>
-
         <para>5.0.X および 5.1.Xでは, このファイルは
-
             <emphasis>SCI/modules/jvm/etc/jvm_options.xml</emphasis>に保存されています.
-
         </para>
-
         <para>&gt;= 5.2.0以降, このファイルは
-
             <emphasis>
-
                 etc/jvm_options.xml<emphasis> </emphasis>
-
             </emphasis>
-
             にあります.
-
         </para>
-
         <para>デフォルトで, 以下の3つのオプションが
-
             設定ファイルで容易にアクセス可能です:
-
         </para>
-
         <variablelist>
-
             <varlistentry>
-
                 <term>-XmxXXXm</term>
-
                 <listitem>
-
                     <para>
-
                         このオプションは,Java仮想マシンで利用可能なメモリ量を設定します.
-
                         デフォルトで, 256M が確保されます.
-
                         この値を変更した場合, その値がシステムで利用可能なメモリを
-
                         超えないことを確認してください.
-
                     </para>
-
                     <para>
-
                         Scilab 5.4.0以降, この値は設定メニュー内で変更可能です.
-
                     </para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>-Djava.compiler=JIT</term>
-
                 <listitem>
-
                     <para>
-
                         このオプションを引数<emphasis>JIT</emphasis>を付けて指定すると,
-
                         Java Just In Time compilerが有効になります.
-
                         このオプションはデフォルトで有効となります.
-
                         <emphasis>NONE</emphasis>によりJITは無効となり,
-
                         著しく性能が低下します.
-
                     </para>
-
                 </listitem>
-
             </varlistentry>
-
             <varlistentry>
-
                 <term>-verbose:jni / -Xcheck:jni</term>
-
                 <listitem>
-
                     <para>
-
                         これらのオプションは,JNIコールとその出力をより詳細に確認します.
-
                         デバッグ時にはこれらのオプションを利用可能ですが,
-
                         性能を低下させるためデフォルトでは無効となっています.
-
                     </para>
-
                 </listitem>
-
             </varlistentry>
-
         </variablelist>
-
         <para>より多くのオプションが利用可能です.
-
             これにより性能を改善したり,ルックアンドフィールを変更したり,
-
             メモリ管理を変更したりといったことが可能です.
-
             参照:  <ulink url="http://www.oracle.com/technetwork/java/javase/tech/vmoptions-jsp-140102.html">http://www.oracle.com/technetwork/java/javase/tech/vmoptions-jsp-140102.html</ulink>
-
         </para>
-
     </refsection>
-
     <refsection role="examples">
-
         <title>例</title>
-
-        <programlisting role="no-scilab-exec"><![CDATA[
+        <screen><![CDATA[
 # Let's start Scilab in profiling mode without attaching a gdb once a SIGSEGV is met.
 # We are under Bash shell
 export SCILAB_VALGRIND_OPT="--db-attach=no --log-file=myfile.txt"
 scilab -profiling
-
 # Let's start Scilab in debug mode without stopping after each SIGSEGV
 # First, we write a small command file
 echo "handle SIGSEGV nostop" &> debug.txt
@@ -766,68 +464,57 @@ echo "handle SIGSEGV nostop" &> debug.txt
 # We are under Bash shell
 export SCILAB_GDB_OPT="--command=debug.txt"
 # Start Scilab in debug mode
-scilab -debug]]></programlisting>
-
-        <programlisting role="no-scilab-exec"><![CDATA[
+scilab -debug ]]></screen>
+        <para></para>
+        <screen><![CDATA[
 # Under GNU/Linux, Mac OS X or Unix:
 $ echo "disp(%pi)"|scilab-cli
 or
 $ echo "disp(%pi)"|scilab -nwni
-
 # Only open the Scilab help window:
 $ scilab-adv-cli -e "help()"
 or
 $ scilab -nw -e "help()"
-
-
 # Scilab can be used for scripting aspects:
 echo "if 1<>2 then exit(99) end"|scilab-cli
-echo $? ]]></programlisting>
-
+echo $? ]]></screen>
     </refsection>
-
     <refsection role="see also">
-
         <title>参照</title>
-
         <simplelist type="inline">
-
             <member>
-
-                <link linkend="exit">exit</link>
-
+                <link linkend="startup">startup</link>
             </member>
-
             <member>
-
-                <link linkend="startup">startup</link>
-
+                <link linkend="sciargs">sciargs</link>
+            </member>
+            <member>
+                <link linkend="getpid">getpid</link>
+            </member>
+            <member>
+                <link linkend="getenv">getenv</link>
+            </member>
+            <member>
+                <link linkend="getenv">getversion</link>
+            </member>
+            <member>
+                <link linkend="consolebox">consolebox</link>
+            </member>
+            <member>
+                <link linkend="exit">exit</link>
             </member>
-
         </simplelist>
-
     </refsection>
-
     <refsection role="history">
-
         <title>履歴</title>
-
         <revhistory>
-
             <revision>
-
                 <revnumber>5.4.0</revnumber>
-
                 <revremark>-noatomsautoload が追加されました.</revremark>
-
             </revision>
-
             <revision>
-
                 <revnumber>5.4.1</revnumber>
-
                 <revremark>scinotes と xcos 個別スクリプトが導入されました. SEP #87参照.</revremark>
-
             </revision>
             <revision>
                 <revnumber>6.0.0</revnumber>
@@ -836,8 +523,5 @@ echo $? ]]></programlisting>
                 </revremark>
             </revision>
         </revhistory>
-
     </refsection>
-
-</refentry>
-
+</refentry>
\ No newline at end of file
index ce39812..150f652 100644 (file)
@@ -1,26 +1,89 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns3="http://www.w3.org/1999/xhtml" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org" xml:id="scilab" xml:lang="pt">
+<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"
+        xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns3="http://www.w3.org/1999/xhtml"
+        xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook"
+        xmlns:scilab="http://www.scilab.org" xml:id="scilab" xml:lang="pt">
+    <refnamediv xml:id="wscilex">
+    </refnamediv>
+    <refnamediv xml:id="scilex">
+    </refnamediv>
     <refnamediv>
-        <refname>scilab</refname>
-        <refpurpose>principal script para executar o Scilab e ferramentas de
-            miscelânea
+        <refname>scilex | scilab</refname>
+        <refpurpose>principal script para executar o Scilab e ferramentas de miscelânea
         </refpurpose>
     </refnamediv>
     <refsynopsisdiv>
         <title>Sqeüência de Chamamento</title>
-        <synopsis>scilab &lt;Options&gt;</synopsis>
+        <synopsis>
+#      MS Windows          |  # Linux / Unix / Mac OS X
+wscilex     &lt;Options&gt;     |  scilab         &lt;Options&gt;
+wscilex -nw &lt;Options&gt; |  scilab-adv-cli &lt;Options&gt;
+scilex      &lt;Options&gt;      |  scilab-cli     &lt;Options&gt;
+        </synopsis>
     </refsynopsisdiv>
     <refsection role="arguments">
         <title>Parâmetros</title>
         <variablelist>
             <varlistentry>
-                <term>-args Arguments</term>
+                <term>-args arg#1 arg#2 ..</term>
                 <listitem>
-                    <para>Se esta opção estiver presente, os argumentos são passados ao
-                        Scilab. Eles podem ser recebidos pela função <link linkend="sciargs">sciargs</link>. para passagem de múltiplos
-                        argumentos use, seqüências de palavras separadas por espaços entre
-                        aspas simples: <literal>scilab -args 'foo1 foo2'</literal>
+                    <para>
+                        This option allows to send some data to the Scilab session:
+                        <itemizedlist>
+                            <listitem>Consecutive data are separated by one or several spaces.
+                            </listitem>
+                            <listitem>An expression between double-quotes is a single data.
+                            </listitem>
+                            <listitem>To include a double-quote in a data, write <literal>\"</literal> instead of <literal>"</literal>.
+                            </listitem>
+                            <listitem>The single quote <literal>'</literal> is a regular character. It has no special meaning.
+                            </listitem>
+                        </itemizedlist>
                     </para>
+                    <para>
+                      Inside the opened session, these data can be retrieved as separated strings with <link linkend="sciargs">sciargs()</link>.
+                     </para>
+                     <para>
+                      Example:
+                        <screen><![CDATA[C:\Users\Me> scilex -nb -args "Hello \"%USERNAME%\"" 1.2345 \"%cd%\"]]></screen>
+                        <programlisting><![CDATA[
+// Inside the opened session:
+a = sciargs()
+i = find(a=="-args")
+a(i+1)
+evstr(a(i+2))*2
+"This session has been launched from " + a(i+3)
+                        ]]>
+                        </programlisting>
+                        <screen><![CDATA[
+--> // Inside the opened session:
+--> a = sciargs()
+ a  =
+!c:\SCIdir\bin\scilex  -nw  -nb  -noatomsautoload  -args  Hello "John"  1.2345  "C:\Users\Me" !
+
+--> i = find(a=="-args")
+ i  =
+    5.
+
+--> a(i+1)
+ ans  =
+ Hello "John"
+
+--> evstr(a(i+2))*2
+ ans  =
+    2.469
+
+--> "This session has been launched from " + a(i+3)
+ ans  =
+ This session has been launched from "C:\Users\Me"
+
+-->
+]]></screen>
+                     </para>
+                     <para>
+                     <note>Using <literal>-args</literal> as the <emphasis role="italic">last</emphasis> command line option is safer.
+                     </note>
+                     </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 </listitem>
             </varlistentry>
             <varlistentry>
-                <term>-debug</term>
+                <term>-e Instructions</term>
                 <listitem>
-                    <para>Inicia o Scilab no debugger gdb (apenas para
-                        Unix/Linux/Mac OS X).
+                    <para>
+                        No final de toda a sessão de inicialização, esta opção
+                        <itemizedlist>
+                            <listitem>
+                                <para>Define o diretório de trabalho atual para o diretório shell do qual o Scilab foi lançado. Por favor veja o exemplo dado aqui-abaixo para a opção <literal> -f </literal>. Então,
+                                </para>
+                            </listitem>
+                            <listitem>
+                                <para>executa dado Scilab <literal>Instructions</literal>. Exemplo :
+                                    <screen><![CDATA[ scilab-cli -e  "disp(\"Hello\"); a=%pi+%i; disp(exp(a)); exit;" -nb]]></screen>
+                                </para>
+                            </listitem>
+                        </itemizedlist>
                     </para>
+                    <warning>
+                        As opções <literal>-e</literal> e <literal>-f</literal> são mutuamente exclusivas.
+                    </warning>
                 </listitem>
             </varlistentry>
             <varlistentry>
-                <term>-e Instrução</term>
+                <term>-f file</term>
                 <listitem>
-                    <para>Se esta opção estiver presente, então a instrução Scilab
-                        <literal>Instrução</literal> é executada primeiro (logo após a
-                        execução do arquivo de inicialização) no Scilab. As opções
-                        <literal>-e</literal> e <literal>-f</literal> são mutuamente
-                        exclusivas
+                    <para>
+                        If this option is used, then at the beginning of the Scilab session, after the execution of the scilab and user startup files, and after the setting of user Preferences -- including the working directory ones --,
+                        <itemizedlist>
+                            <listitem>
+                                <para>
+                                    the current Scilab working directory is set to the shell directory from which Scilab has been launched. For instance,
+                                    <screen><![CDATA[ D:\users\me\scilab\dev> C:\scilab-5.5.2\bin\scilex -f ..\test.sce]]></screen>
+                                    will do a <literal>cd("D:\users\me\scilab\dev")</literal>.
+                                </para>
+                            </listitem>
+                            <listitem>
+                                <para>
+                                    the Scilab script <literal>file</literal> is executed. If a relative path is used (default <literal>.\</literal>, or like <literal>..\</literal> in the sample here-above), it refers to the new Scilab working directory.
+                                </para>
+                            </listitem>
+                        </itemizedlist>
                     </para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-f arquivo</term>
-                <listitem>
-                    <para>Se esta opção estiver presente, então o script Scilab
-                        <literal>arquivo</literal> é executado primeiro (logo após a
-                        execução do arquivo de inicialização) no Scilab. As opções
-                        <literal>-e</literal> e <literal>-f</literal> são mutuamente
-                        exclusivas.
+                    <para>
+                        A file with .xcos extension will be opened by Xcos.
                     </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-nb</term>
                 <listitem>
-                    <para>Se esta opção está presente, então o cartão de boas-vindas não
-                        é impresso.
+                    <para>"no banner" : Se esta opção está presente, então o cartão de boas-vindas não é impresso.
                     </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-ns</term>
                 <listitem>
-                    <para>Se esta opção está presente, o arquivo de inicialização
+                    <para>"No Startup files" : Se esta opção está presente, o arquivo de inicialização
                         <literal>SCI/etc/scilab.start</literal> e os arquivos de
                         inicialização do usuário <literal>SCIHOME/.scilab</literal>,
                         <literal>SCIHOME/scilab.ini</literal> não são executados.
             <varlistentry>
                 <term>-nwni / -nogui</term>
                 <listitem>
+                    <important>
+                        This mode prevents loading the Java Virtual Machine.
+                        It starts faster and uses less memory.
+                    </important>
                     <para>Se esta opção estiver presente, então o Scilab não é executado
-                        em uma janela específica e não aceita interação do usuário. Esta
-                        opção pode ser utilizada com as opções -f ou -e .
+                        em uma janela específica e não aceita interação do usuário
+                        (graphics, export, xcos, scinotes, help browser, Java module,...).
                     </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-version</term>
                 <listitem>
-                    <para>Esta opção imprime a versão do produto e sai.</para>
+                    <para>Esta opção imprime a versão do Scilab.</para>
+                </listitem>
+            </varlistentry>
+        </variablelist>
+    </refsection>
+    <refsection role="arguments">
+        <title>Additional options for Unix/Linux and Mac OS X</title>
+        <para>Advice: use theses options on a Scilab source tree.</para>
+        <variablelist>
+            <varlistentry>
+                <term>-debug</term>
+                <listitem>
+                    <para>Inicia o Scilab no debugger gdb.</para>
+                    <para>
+                        The variable <literal>SCILAB_GDB_OPT</literal> may be set to add custom options to gdb.
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-debug-kdbg</term>
+                <listitem>
+                    <para>Start Scilab under kdbg.</para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-profiling</term>
+                <listitem>
+                    <para>Start Scilab under valgrind.</para>
+                    <para>The variable SCILAB_VALGRIND_OPT may be set to add custom options
+                        to valgrind (and override the existing valgrind options).
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-profiling-visu</term>
+                <listitem>
+                    <para>Start Scilab under callgrind.</para>
+                    <para>The variable SCILAB_VALGRIND_OPT may be set to add custom options
+                        to callgrind (and override the existing callgrind options).
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-electric-fence</term>
+                <listitem>
+                    <para>Start Scilab with the Electric Fence.</para>
                 </listitem>
             </varlistentry>
         </variablelist>
     </refsection>
     <refsection role="description">
-        <title>Description of environment variables</title>
+        <title>Environment variables</title>
         <variablelist>
             <varlistentry>
                 <term>SCIVERBOSE</term>
     </refsection>
     <refsection role="description">
         <title>Java Virtual Machine options</title>
+        <warning>
+            The options described here-below are useless and are cancelled if the option <literal>-nwni</literal> is used.
+        </warning>
         <para>Starting from Scilab 5.0, the graphical user interface (GUI) and the
             build documentation are based on Java features. In some cases, it can be
             important to edit the JVM options (Java Virtual Machine).
     </refsection>
     <refsection role="examples">
         <title>Exemplos</title>
-        <programlisting role="no-scilab-exec"><![CDATA[
+        <screen><![CDATA[
 # Let's start Scilab in profiling mode without attaching a gdb once a SIGSEGV is met.
 # We are under Bash shell
 export SCILAB_VALGRIND_OPT="--db-attach=no --log-file=myfile.txt"
@@ -255,8 +386,9 @@ echo "handle SIGSEGV nostop" &> debug.txt
 # We are under Bash shell
 export SCILAB_GDB_OPT="--command=debug.txt"
 # Start Scilab in debug mode
-scilab -debug]]></programlisting>
-        <programlisting role="no-scilab-exec"><![CDATA[
+scilab -debug ]]></screen>
+        <para></para>
+        <screen><![CDATA[
 # Under GNU/Linux, Mac OS X or Unix:
 $ echo "disp(%pi)"|scilab-cli
 or
@@ -270,16 +402,31 @@ $ scilab -nw -e "help()"
 
 # Scilab can be used for scripting aspects:
 echo "if 1<>2 then exit(99) end"|scilab-cli
-echo $? ]]></programlisting>
+echo $? ]]></screen>
     </refsection>
     <refsection role="see also">
         <title>Ver também</title>
         <simplelist type="inline">
             <member>
-                <link linkend="exit">exit</link>
+                <link linkend="startup">startup</link>
             </member>
             <member>
-                <link linkend="startup">startup</link>
+                <link linkend="sciargs">sciargs</link>
+            </member>
+            <member>
+                <link linkend="getpid">getpid</link>
+            </member>
+            <member>
+                <link linkend="getenv">getenv</link>
+            </member>
+            <member>
+                <link linkend="getenv">getversion</link>
+            </member>
+            <member>
+                <link linkend="consolebox">consolebox</link>
+            </member>
+            <member>
+                <link linkend="exit">exit</link>
             </member>
         </simplelist>
     </refsection>
index 1c12ac9..810ca7b 100644 (file)
@@ -1,33 +1,95 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns4="http://www.w3.org/1999/xhtml" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org" xml:id="scilab" xml:lang="ru">
+<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"
+    xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns4="http://www.w3.org/1999/xhtml"
+    xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook"
+    xmlns:scilab="http://www.scilab.org" xml:id="scilab" xml:lang="ru">
+    <refnamediv xml:id="wscilex">
+    </refnamediv>
+    <refnamediv xml:id="scilex">
+    </refnamediv>
     <refnamediv>
-        <refname>scilab</refname>
+        <refname>scilex | scilab</refname>
         <refpurpose>
-            главный файл-сценарий для запуска Scilab'а и различных инструментов(GNU/Linux, Unix и Mac OS X)
+            главный файл-сценарий для запуска Scilab'а и различных инструментов
         </refpurpose>
     </refnamediv>
     <refsynopsisdiv>
         <title>Синтаксис</title>
         <synopsis>
-            scilab &lt;Options&gt;
-            scilab-adv-cli &lt;Options&gt;
-            scilab-cli &lt;Options&gt;
+#      MS Windows          |  # Linux / Unix / Mac OS X
+wscilex     &lt;Options&gt;     |  scilab         &lt;Options&gt;
+wscilex -nw &lt;Options&gt; |  scilab-adv-cli &lt;Options&gt;
+scilex      &lt;Options&gt;      |  scilab-cli     &lt;Options&gt;
         </synopsis>
     </refsynopsisdiv>
     <refsection role="arguments">
         <title>Аргументы</title>
         <variablelist>
             <varlistentry>
-                <term>-args Arguments</term>
+                <term>-args arg№1 arg№2 ..</term>
                 <listitem>
                     <para>
-                        Если есть эта опция, то в Scilab передаются аргументы <literal>Arguments</literal>.
-                        Они могут затем быть получены с помощью функции
-                        <link linkend="sciargs">sciargs</link>. Для множества передаваемых
-                        аргументов используйте кавычки и разделяйте слова пробелами. Например,
-                        <literal>scilab -args 'foo1 foo2'</literal>. Без этого неизвестные
-                        аргументы не будут приняты.
+                        Эта опция позволяет переслать  данные в сессию Scilab'а:
+                        <itemizedlist>
+                            <listitem>
+                              Последовательность данных, разделённых одним или несколькими пробелами.
+                            </listitem>
+                            <listitem>
+                              Выражение между двойными кавычками является единым куском данных.
+                            </listitem>
+                            <listitem>
+                              Чтобы внести двойные кавычки в данные, запишите <literal>\"</literal> вместо <literal>"</literal>.
+                            </listitem>
+                            <listitem>
+                              Одинарная кавычка <literal>'</literal> является обычным символом. У неё нет специального значения.
+                            </listitem>
+                        </itemizedlist>
                     </para>
+                    <para>
+                      Внутри открытой сессии эти данные могут быть получены  виде раздельных строк с помощью <link linkend="sciargs">sciargs()</link>.
+                     </para>
+                     <para>
+                      Пример:
+                        <screen><![CDATA[C:\Users\Me> scilex -nb -args "Привет, \"%USERNAME%\"" 1.2345 \"%cd%\"]]></screen>
+                        <programlisting><![CDATA[
+// Внутри открытой сессии:
+a = sciargs()
+i = find(a=="-args")
+a(i+1)
+evstr(a(i+2))*2
+"Эта сессия была запущена из " + a(i+3)
+                        ]]>
+                        </programlisting>
+                        <screen><![CDATA[
+--> // Внутри открытой сессии:
+--> a = sciargs()
+ a  =
+!c:\SCIdir\bin\scilex  -nw  -nb  -noatomsautoload  -args  Привет, "Иван"  1.2345  "C:\Users\Me" !
+
+--> i = find(a=="-args")
+ i  =
+    5.
+
+--> a(i+1)
+ ans  =
+ Привет, "Иван"
+
+--> evstr(a(i+2))*2
+ ans  =
+    2.469
+
+--> "Эта сессия была запущена из " + a(i+3)
+ ans  =
+ Эта сессия была запущена из "C:\Users\Me"
+
+-->
+]]></screen>
+                     </para>
+                     <para>
+                     <note>
+                       Безопаснее использовать <literal>-args</literal> в качестве <emphasis role="italic">последней</emphasis> опции командной строки.
+                     </note>
+                     </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 </listitem>
             </varlistentry>
             <varlistentry>
-                <term>-debug</term>
-                <listitem>
-                    <para>
-                        Запуск Scilab'а в отладчике gdb (только Unix/Linux/Mac OS X).
-                    </para>
-                    <para>
-                        Определите переменную  <literal>SCILAB_GDB_OPT</literal> для добавления
-                        пользовательских настроек в gdb.
-                    </para>
-                    <para>Совет: используйте эту опцию в дереве исходников Scilab'а.</para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-debug-kdbg</term>
+                <term>-e Instructions</term>
                 <listitem>
-                    <para>Запуск Scilab'а в kdbg (только Unix/Linux/Mac OS X).</para>
-                    <para>Совет: используйте эту опцию в дереве исходников Scilab'а.</para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-profiling</term>
-                <listitem>
-                    <para>Запуск Scilab'а в valgrind (только Unix/Linux/Mac OS X).</para>
                     <para>
-                        Определите переменную  <literal>SCILAB_VALGRIND_OPT</literal>  для
-                        добавления пользовательских настроек в valgrind (и отмены существующих
-                        опций valgrind).
-                    </para>
-                    <para>Совет: используйте эту опцию в дереве исходников Scilab'а.</para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-profiling-visu</term>
-                <listitem>
-                    <para>Запуск Scilab'а в callgrind (только Unix/Linux/Mac OS X).</para>
-                    <para>
-                        Определите переменную <literal>SCILAB_VALGRIND_OPT</literal> для
-                        добавления пользовательских настроек в callgrind (и отмены существующих
-                        опций callgrind).
-                    </para>
-                    <para>Совет: используйте эту опцию в дереве исходников Scilab'а.</para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-electric-fence</term>
-                <listitem>
-                    <para>Запуск Scilab'а в Electric Fence (только Unix/Linux/Mac OS X).</para>
-                    <para>Совет: используйте эту опцию в дереве исходников Scilab'а.</para>
-                </listitem>
-            </varlistentry>
-            <varlistentry>
-                <term>-e Instruction</term>
-                <listitem>
-                    <para>
-                        Если есть эта опция, то инструкция <literal>Instruction</literal> выполняется
-                        первой (сразу же после исполнения файла запуска) в Scilab'e. Опции <literal>-e</literal>
-                        и <literal>-f</literal> взаимоисключающие.
-                    </para>
-                    <para>
-                        Заметьте, что с <literal>-e</literal> можно использовать несколько инструкций.
-                    </para>
-                    <programlisting role="no-scilab-exec">scilab-cli -e  "a=1+%i; aPlusPi=a+%pi; disp(aPlusPi);exit;" -nb</programlisting>
+                        По окончании запуска всей сессии, этот вариант
+                        <itemizedlist>
+                            <listitem>
+                                <para>
+                                  устанавливает текущий рабочий каталог в каталог оболочки, из которой Scilab был запущен.
+                                  Пожалуйста, смотрите пример, приведенный здесь ниже для опции <literal>-f</literal>. Затем,
+                                </para>
+                            </listitem>
+                            <listitem>
+                                <para>эта опция выполняет инструкции Scilab <literal>Instructions</literal>, указанные в строке. Пример :
+                                    <screen><![CDATA[ scilab-cli -e  "disp(\"Привет\"); a=%pi+%i; disp(exp(a)); exit;" -nb]]></screen>
+                                </para>
+                            </listitem>
+                        </itemizedlist>
+                    </para>
+                    <warning>
+                        Опции <literal>-e</literal> и <literal>-f</literal> взаимоисключающие.
+                    </warning>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-f file</term>
                 <listitem>
                     <para>
-                        Если есть эта опция, то файл-сценарий Scilab'a <literal>file</literal> исполняется
-                        первым (сразу же после  исполнения файла запуска) в Scilab'e. <literal>-e</literal> и
-                        <literal>-f</literal>  взаимоисключающие.
-                    </para>
-                    <para>Файл с расширением .xcos будет открыт в Xcos.</para>
+                        Если эта опцпия используется, то в начале сессии Scilab, после исполнения файлов запуска Sciblab и
+                        пользовательских файлов запуска, и после установки пользовательских настроек, включая настройки рабочей директории,
+                        <itemizedlist>
+                            <listitem>
+                                <para>
+                                    текущая рабочая директория Scilab  устаровлена в каталоге оболочки, из которой Scilab был запущен. Например,
+                                    <screen><![CDATA[ D:\users\me\scilab\dev> C:\scilab-5.5.2\bin\scilex -f ..\test.sce]]></screen>
+                                    будет исполнять <literal>cd("D:\users\me\scilab\dev")</literal>.
+                                </para>
+                            </listitem>
+                            <listitem>
+                                <para>
+                                    Scilab-сценарий <literal>file</literal> выполнен. Если относительный путь используется
+                                    (по умолчанию <literal>.\</literal> или как <literal>..\</literal> в примере выше), то
+                                    он отсылается в новую рабочую директорию Scilab.
+                                </para>
+                            </listitem>
+                        </itemizedlist>
+                    </para>
+                  <para>Файл с расширением <literal>.xcos</literal> будет открыт в Xcos.</para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-quit</term>
                 <listitem>
                     <para>
-                        This option forces scilab to always exit after the instruction(s) passed with the <literal>-e</literal>
-                        option, or the script referred to by the <literal>-f</literal> option, have been executed,
-                        even in case of a runtime error. This option should always be used in batch mode.
-                        It is ignored if neither <literal>-e</literal> nor <literal>-f</literal> options are present.
+                        Эта опция заставляет Scilab всегда выходить после инструкций, переданных вместе с опцией
+                        <literal>-e</literal>, или  сценарий, на который ссылается оция <literal>-f</literal>,
+                        будет исполнен, даже в случае ошибки времени исполнения. Эта опция всегда должна использоваться
+                        в режиме пакетной обработки. Она игнорируется, если нет ни опции <literal>-e</literal>
+                        ни опции <literal>-f</literal>.
                     </para>
                 </listitem>
             </varlistentry>
                         В некоторых системах для правильного отображения шрифтов в кодировке UTF-8 локали должны быть откомпилированы.
                     </para>
                     <para>Scilab также может быть запущен следующим образом:</para>
-                    <programlisting role="no-scilab-exec">LANG=ja_JP scilab
-                        #  то же, что и
-                        scilab -l ja_JP
-                    </programlisting>
+                    <screen><![CDATA[ LANG=ja_JP scilab
+ #  то же, что и
+ scilab -l ja_JP
+]]></screen>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-nb</term>
                 <listitem>
                     <para>
-                        Если есть эта опция, то сообщение о загрузке Scilab'а не будет отображаться.
+                        "no banner" : Если есть эта опция, то сообщение о загрузке Scilab'а не будет отображаться.
                     </para>
                 </listitem>
             </varlistentry>
                 <term>-ns</term>
                 <listitem>
                     <para>
+                        "No Startup files" :
                         Если есть эта опция, то файл запуска <literal>SCI/etc/scilab.start</literal> и пользовательские
                         файлы запуска <literal>SCIHOME/.scilab</literal> и <literal>SCIHOME/scilab.ini</literal> не исполняются.
                     </para>
                     <para>
                         Если есть эта опция,то Scilab запускается как командная строка с улучшенными возможностями (графические окна, экспорт, xcos, scinotes, справочная система, ...).
                     </para>
-                    <para>
-                        Эта опция может быть использована совместно с опциями <literal>-f</literal> и <literal>-e</literal>.
-                    </para>
                     <para>Начиная с Scilab 5.2:</para>
                     <itemizedlist>
                         <listitem>
                             <para>
-                                Дистрибутив Scilab также предоставляет специальный бинарный файл, который
-                                делает то же, что и <literal>-nw</literal>: <literal>scilab-adv-cli</literal>
-                                (Интерпретатор Scilab с улучшенной командной строкой).
+                                конвейеры доступны во всех операционных системах (см. примеры для дополнительной
+                                информации).
                             </para>
                         </listitem>
                         <listitem>
                             <para>
-                                конвейеры доступны во всех операционных системах (см. примеры для дополнительной
-                                информации).
+                                Дистрибутив Scilab также предоставляет специальный бинарный файл, который
+                                делает то же, что и <literal>-nw</literal>: <literal>scilab-adv-cli</literal>
+                                (Интерпретатор Scilab с улучшенной командной строкой).
                             </para>
                         </listitem>
                     </itemizedlist>
             <varlistentry>
                 <term>-nwni / -nogui</term>
                 <listitem>
+                    <important>
+                        Этот режим не загружает виртуальную машину Java (быстрее загружается и использует меньше памяти).
+                    </important>
                     <para>
                         Если есть эта опция, то Scilab запускается как командная строка без улучшенных возможностей (графических окон, экспорта, xcos, scinotes, справочной системы, ...).
                     </para>
-                    <para>
-                        Эта опция может использоваться совместно с опциями <literal>-f</literal> или
-                        <literal>-e</literal>.
-                    </para>
                     <para>Начиная с Scilab 5.2:</para>
                     <itemizedlist>
                         <listitem>
                             <para>
-                                Дистрибутив Scilab также предоставляет специальный бинарный файл, который
-                                делает то же, что и <literal>-nwni</literal>: <literal>scilab-cli</literal>
-                                (Интерпретатор Scilab с улучшенной командной строкой).
+                                конвейеры доступны во всех операционных системах (см. примеры для дополнительной
+                                информации).
                             </para>
                         </listitem>
-                    </itemizedlist>
-                    <itemizedlist>
                         <listitem>
                             <para>
-                                конвейеры доступны во всех операционных системах (см. примеры для дополнительной
-                                информации).
+                                Дистрибутив Scilab также предоставляет специальный бинарный файл, который
+                                делает то же, что и <literal>-nwni</literal>: <literal>scilab-cli</literal>
+                                (Интерпретатор Scilab с улучшенной командной строкой).
                             </para>
                         </listitem>
                     </itemizedlist>
-                    <para>
-                        Этот режим не загружает виртуальную машину Java (быстрее загружается и использует меньше памяти.
-                    </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <listitem>
                     <para>Эта опция предназначена для TeXMacs.</para>
                     <para>Пожалуйста, установите ATOMS-модуль TeXMacs:
-                        <programlisting role="">atomsInstall('texmacs')</programlisting>atomsInstall('texmacs')
+                        <code>atomsInstall('texmacs')</code>
                     </para>
                 </listitem>
             </varlistentry>
             <varlistentry>
                 <term>-version</term>
                 <listitem>
-                    <para>Эта опция выводит на экран версию продукта и выходит.</para>
+                    <para>Эта опция выводит на экран версию продукта.</para>
                 </listitem>
             </varlistentry>
         </variablelist>
     </refsection>
+
+    <refsection role="arguments">
+        <title>Дополнительные опции для Unix/Linux и Mac OS X</title>
+        <para>Совет: используйте эти параметры в дереве исходников Scilab'а.</para>
+        <variablelist>
+            <varlistentry>
+                <term>-debug</term>
+                <listitem>
+                    <para>
+                        Запуск Scilab'а в отладчике gdb.
+                    </para>
+                    <para>
+                        Определите переменную  <literal>SCILAB_GDB_OPT</literal> для добавления
+                        пользовательских настроек в gdb.
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-debug-kdbg</term>
+                <listitem>
+                    <para>Запуск Scilab'а в kdbg.</para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-profiling</term>
+                <listitem>
+                    <para>Запуск Scilab'а в valgrind.</para>
+                    <para>
+                        Определите переменную  <literal>SCILAB_VALGRIND_OPT</literal>  для
+                        добавления пользовательских настроек в valgrind (и отмены существующих
+                        опций valgrind).
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-profiling-visu</term>
+                <listitem>
+                    <para>Запуск Scilab'а в callgrind.</para>
+                    <para>
+                        Определите переменную <literal>SCILAB_VALGRIND_OPT</literal> для
+                        добавления пользовательских настроек в callgrind (и отмены существующих
+                        опций callgrind).
+                    </para>
+                </listitem>
+            </varlistentry>
+            <varlistentry>
+                <term>-electric-fence</term>
+                <listitem>
+                    <para>Запуск Scilab'а в Electric Fence.</para>
+                </listitem>
+            </varlistentry>
+        </variablelist>
+    </refsection>
+
     <refsection role="description">
         <title>Описание переменных окружения</title>
         <variablelist>
     </refsection>
     <refsection role="description">
         <title>Опции виртуальной машины Java</title>
+        <warning>
+            Опции, описаные ниже бесполезны и будут удалены, если используется опция <literal>-nwni</literal>.
+        </warning>
         <para>
             Начиная с Scilab 5.0, графический пользовательский интерфейс (GUI) и встроенная
             документация основаны на возможностях Java. В некоторых случаях может оказаться
     </refsection>
     <refsection role="examples">
         <title>Примеры</title>
-        <programlisting role="example"><![CDATA[
+        <screen><![CDATA[
 # Запустим Scilab в режиме профилирования без прикрепления gdb после каждого SIGSEGV.
 # Мы находимся в оболочке Bash
 export SCILAB_VALGRIND_OPT="--db-attach=no --log-file=myfile.txt"
@@ -385,9 +471,9 @@ echo "handle SIGSEGV nostop" &> debug.txt
 # Мы находимся в оболочке Bash
 export SCILAB_GDB_OPT="--command=debug.txt"
 # Запуск Scilab'а в режиме отладки
-scilab -debug
-]]></programlisting>
-        <programlisting role="example-cli"><![CDATA[
+scilab -debug ]]></screen>
+        <para></para>
+        <screen><![CDATA[
 # В GNU/Linux, Mac OS X или Unix:
 $ echo "disp(%pi)"|scilab-cli
 или
@@ -401,16 +487,31 @@ $ scilab -nw -e "help()"
 
 # Scilab может быть использован написания сценариев:
 echo "if 1<>2 then exit(99) end"|scilab-cli
-echo $? ]]></programlisting>
+echo $? ]]></screen>
     </refsection>
     <refsection role="see also">
         <title>Смотрите также</title>
         <simplelist type="inline">
             <member>
-                <link linkend="exit">exit</link>
+                <link linkend="startup">начальный запуск</link>
             </member>
             <member>
-                <link linkend="startup">начальный запуск</link>
+                <link linkend="sciargs">sciargs</link>
+            </member>
+            <member>
+                <link linkend="getpid">getpid</link>
+            </member>
+            <member>
+                <link linkend="getenv">getenv</link>
+            </member>
+            <member>
+                <link linkend="getenv">getversion</link>
+            </member>
+            <member>
+                <link linkend="consolebox">consolebox</link>
+            </member>
+            <member>
+                <link linkend="exit">exit</link>
             </member>
         </simplelist>
     </refsection>
@@ -431,7 +532,7 @@ echo $? ]]></programlisting>
             <revision>
                 <revnumber>6.0.0</revnumber>
                 <revremark>
-                    <literal>-quit</literal> option added. <literal>-mem</literal> option removed.
+                    Добавлена опция <literal>-quit</literal>. Опция <literal>-mem</literal> удалена.
                 </revremark>
             </revision>
         </revhistory>