1 <?xml version="1.0" encoding="UTF-8"?>
2 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" version="5.0-subset Scilab" xml:lang="en" xml:id="figure">
4 <pubdate>$LastChangedDate$</pubdate>
7 <refname>figure</refname>
8 <refpurpose> create a figure</refpurpose>
11 <title>Calling Sequence</title>
14 f = figure("PropertyName1", Propertyvalue1, ..., ..., "PropertyNameN", PropertyvalueN);
18 <title>Description</title>
20 This routine creates a figure. If an ID is given, the figure corresponding to this ID is created.
21 Otherwise, the window is created with the first free ID, that is the lowest integer not already used by a window.
25 <title>Parameters</title>
30 <para>ID of the window to create. If not specified, the first free ID is used.</para>
34 <term>PropertyName{1, ..., N}</term>
36 <para>character string name of a property to set. One of the property names listed below.</para>
40 <term>PropertyValue{1, ..., N}</term>
42 <para>scilab object value to give to the corresponding property.</para>
48 <para>handle of the newly created window.</para>
54 <title>Properties</title>
57 <term>BackgroundColor</term>
59 <para>[1,3] real vector or string Background color of the figure. A
60 color is specified as Red, Green and Blue values. Those values are
61 real in [0,1]. The color can be given as a real vector, ie [R,G,B] or
62 a string where each value is separated by a "|", ie "R|G|B"</para>
66 <term>Figure_name</term>
68 <para>character string, allows to set the title of the figure.
73 <term>ForegroundColor</term>
75 <para>[1,3] real vector or string Foreground color of the figure. A
76 color is specified as Red, Green and Blue values. Those values are
77 real in [0,1]. The color can be given as a real vector, ie [R,G,B] or
78 a string where each value is separated by a "|", ie "R|G|B"</para>
84 <para>allows to control the geometrical aspect of the figure.
85 It is a [1,4] real vector [x y width height] where the letters stand for the x
86 location of the top left corner, the y location of the top left corner, the width and the height of the virtual graphics window
87 (the part of the figure which contains uicontrols and graphics).
88 See the <emphasis role="bold">axes_size</emphasis> property description in <link linkend="figure_properties">figure properties</link> help page.
89 One can also set this property by giving a string where the fields are separated by a "|", ie "x|y|width|height".
96 <para>string this property is generally used to identify the figure. It
97 allows to give it a "name". Mainly used in conjontion with findobj().
102 <term>Userdata</term>
104 <para>this can be used to associate some Scilab objects to a fugure.</para>
110 <title>Examples</title>
111 <programlisting role="example"><![CDATA[
113 // Create figure having figure_id==3
115 // Add a text uicontrol in figure 3
116 uicontrol(h, "style", "text", ...
117 "string", "This is a figure", ...
118 "position", [50 70 100 100], ...
122 // Create figure having figure_id==1
124 // Add a text uicontrol in figure 1
125 uicontrol("style", "text", ...
126 "string", "Another figure", ...
127 "position", [50 70 100 100], ...
130 // Close current figure (ie figure 1)
138 <title>See Also</title>
139 <simplelist type="inline">
141 <link linkend="close">close</link>
144 <link linkend="gcf">gcf</link>
149 <title>Authors</title>
150 <para>Bertrand Guiheneuf</para>