Bug Fix #13966 - twinkle, twinkle(n) now supported
[scilab.git] / scilab / modules / graphics / help / en_US / twinkle.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3  * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
4  * Copyright (C) INRIA
5  * Copyright (C) 2015 - 2016 - Samuel GOUGEON
6  * Copyright (C) 2012 - 2016 - Scilab Enterprises
7  *
8  * This file is hereby licensed under the terms of the GNU GPL v2.0,
9  * pursuant to article 5.3.4 of the CeCILL v.2.1.
10  * This file was originally licensed under the terms of the CeCILL v2.1,
11  * and continues to be available under such terms.
12  * For more information, see the COPYING file which you should have received
13  * along with this program.
14  *
15  -->
16 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org"  xml:lang="en" xml:id="twinkle">
17     <refnamediv>
18         <refname>twinkle</refname>
19         <refpurpose>is used to have a graphics entity blinking</refpurpose>
20     </refnamediv>
21     <refsynopsisdiv>
22         <title>Syntax</title>
23         <synopsis>twinkle
24 twinkle(n)
25 twinkle(h)
26 twinkle(h,n)
27         </synopsis>
28     </refsynopsisdiv>
29     <refsection role="arguments">
30         <title>Arguments</title>
31         <variablelist>
32             <varlistentry>
33                 <term>h</term>
34                 <listitem>
35                     <para>handle of the unique graphics entity to blink. By default, the current graphic entity handled with <literal>gce()</literal> is considered.</para>
36                 </listitem>
37             </varlistentry>
38             <varlistentry>
39                 <term>n</term>
40                 <listitem>
41                     <para>positive integer number: the number of blinks. Default n = 5.</para>
42                 </listitem>
43             </varlistentry>
44         </variablelist>
45     </refsection>
46     <refsection role="description">
47         <title>Description</title>
48         <para>
49             <function>twinkle</function> blinks <varname>n</varname> times the graphical entity
50             handled with <varname>h</varname>. If <function>twinkle()</function> is run while no
51             graphical figure exists, it does nothing and returns. If the handle <varname>h</varname>
52             is invalid (the entity has been deleted in the meantime),
53             <function>twinkle(h..)</function> yields an error.
54         </para>
55     </refsection>
56     <refsection role="examples">
57         <title>Examples</title>
58         <programlisting role="example"><![CDATA[
59 clf
60 plot()
61 twinkle     // twinkles the last group of curves plotted in the plot() example
62 twinkle(3)  // twinkles it only three times
63
64 clf
65 x = linspace(-2*%pi,2*%pi,100)';
66 plot2d(x,[sin(x),cos(x)]);
67 e = gce();
68 p1 = e.children(1);
69 p2 = e.children(2);
70 twinkle(p1)       // cos plot twinkle
71 twinkle(p2,10)    // sin plot twinkle 10 times
72 twinkle(gca())    // axes twinkle
73  ]]></programlisting>
74     </refsection>
75     <refsection role="see also">
76         <title>See Also</title>
77         <simplelist type="inline">
78             <member>
79                 <link linkend="graphics_entities">graphics entities</link>
80             </member>
81         </simplelist>
82     </refsection>
83     <refsection role="history">
84         <title>History</title>
85         <revhistory>
86             <revision>
87                 <revnumber>6.0</revnumber>
88                 <revdescription>
89                     <para>twinkle() and twinkle(n) added.</para>
90                 </revdescription>
91             </revision>
92         </revhistory>
93     </refsection>
94 </refentry>