Let the other namespaces in!
[shapes.git] / doc / parts / bindings / syntax.sxml
blob5f4ecf6477e5cba770fab64c64546e59cd2ba416
1 <!-- This file is part of Shapes.                                           -->
2 <!--                                                                        -->
3 <!-- Shapes is free software: you can redistribute it and/or modify         -->
4 <!-- it under the terms of the GNU General Public License as published by   -->
5 <!-- the Free Software Foundation, either version 3 of the License, or      -->
6 <!-- any later version.                                                     -->
7 <!--                                                                        -->
8 <!-- Shapes is distributed in the hope that it will be useful,              -->
9 <!-- but WITHOUT ANY WARRANTY; without even the implied warranty of         -->
10 <!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          -->
11 <!-- GNU General Public License for more details.                           -->
12 <!--                                                                        -->
13 <!-- You should have received a copy of the GNU General Public License      -->
14 <!-- along with Shapes.  If not, see <http://www.gnu.org/licenses/>.        -->
15 <!--                                                                        -->
16 <!-- Copyright 2008 Henrik Tidefelt                                         -->
18 <section id="bindings/syntax">
19 <title>Syntax equivalents</title>
20 <top>
21 <p>The functions in this section correspond directly to syntactic constructs.</p>
23 <p>The user should generally <em>not</em> use these functions directly.</p>
24 </top>
26 <system-binding name="coords">
27         <function>
28                 <case constructor-of="FloatPair">
29                         <arguments>
30                                 <arg>
31                                         <type><named-type name="Float" /></type>
32                                 </arg>
33                                 <arg>
34                                         <type><named-type name="Float" /></type>
35                                 </arg>
36                         </arguments>
37                         <dynamic-references></dynamic-references>
38                         <description>
39                                 <p>Implements <syntax name="float-pair" />.</p>
40                         </description>
41                 </case>
42                 <case constructor-of="Coords">
43                         <arguments>
44                                 <arg>
45                                         <type><named-type name="LengthLike" /></type>
46                                 </arg>
47                                 <arg>
48                                         <type><named-type name="LengthLike" /></type>
49                                 </arg>
50                         </arguments>
51                         <dynamic-references></dynamic-references>
52                         <description>
53                                 <p>Implements <syntax name="coords-2D" />.</p>
54                                 <p>One of the arguments is allowed to be the special <named-type name="Float" /> value zero, which is interpreted as a zero absolute length.</p>
55                         </description>
56                 </case>
57         </function>
58 </system-binding>
60 <system-binding name="coords3D">
61         <function>
62                 <case constructor-of="FloatTriple">
63                         <arguments>
64                                 <arg>
65                                         <type><named-type name="Float" /></type>
66                                 </arg>
67                                 <arg>
68                                         <type><named-type name="Float" /></type>
69                                 </arg>
70                                 <arg>
71                                         <type><named-type name="Float" /></type>
72                                 </arg>
73                         </arguments>
74                         <dynamic-references></dynamic-references>
75                         <description>
76                                 <p>Implements <syntax name="float-triple" />.</p>
77                         </description>
78                 </case>
79                 <case constructor-of="Coords3D">
80                         <arguments>
81                                 <arg>
82                                         <type><named-type name="LengthLike" /></type>
83                                 </arg>
84                                 <arg>
85                                         <type><named-type name="LengthLike" /></type>
86                                 </arg>
87                                 <arg>
88                                         <type><named-type name="LengthLike" /></type>
89                                 </arg>
90                         </arguments>
91                         <dynamic-references></dynamic-references>
92                         <description>
93                                 <p>Implements <syntax name="coords-3D" />.</p>
94                                 <p>Note that all arguments must be <named-type name="LengthLike" />, with no exception.</p>
95                         </description>
96                 </case>
97         </function>
98 </system-binding>
100 <system-binding name="cornercoords">
101         <function>
102                 <case constructor-of="Coords">
103                         <arguments>
104                                 <arg>
105                                         <type><named-type name="LengthLike" /></type>
106                                 </arg>
107                                 <arg>
108                                         <type><named-type name="LengthLike" /></type>
109                                 </arg>
110                                 <arg>
111                                         <type><named-type name="Float" /></type>
112                                 </arg>
113                         </arguments>
114                         <dynamic-references></dynamic-references>
115                         <description>
116                                 <p>Implements <syntax name="corner-point-2D" />.</p>
117                         </description>
118                 </case>
119         </function>
120 </system-binding>
122 <system-binding name="polarhandleFree_r">
123         <function>
124                 <case constructor-of="PolarHandle">
125                         <arguments>
126                                 <arg>
127                                         <type><named-type name="Float" /></type>
128                                 </arg>
129                         </arguments>
130                         <dynamic-references><dynamic name="defaultunit" /></dynamic-references>
131                         <description>
132                                 <p>Implements <syntax name="polar-handle-2D" /> in the case when the modulus of the handle is not specified.</p>
133                         </description>
134                 </case>
135         </function>
136 </system-binding>
138 <system-binding name="polarhandleFree_ra">
139         <function>
140                 <case constructor-of="PolarHandle">
141                         <arguments>
142                         </arguments>
143                         <dynamic-references><dynamic name="defaultunit" /></dynamic-references>
144                         <description>
145                                 <p>Implements <syntax name="polar-handle-2D" /> in the case when neither modulus nor angle of the handle is not specified.</p>
146                         </description>
147                 </case>
148         </function>
149 </system-binding>
151 <system-binding name="Unicode">
152         <function>
153                 <case constructor-of="Character">
154                         <arguments>
155                                 <arg>
156                                         <type><named-type name="Integer" /></type>
157                                 </arg>
158                         </arguments>
159                         <description>
160                                 <p>The functional alternative to using the form of <syntax name="character" /> based on code points.  Using the syntax <syntax name="character" /> is more efficient when the argument is known beforehand.</p>
161                         </description>
162                 </case>
163         </function>
164 </system-binding>
166 <system-binding name="AdobeGlyphList">
167         <function>
168                 <case constructor-of="Character">
169                         <arguments>
170                                 <arg>
171                                         <type><named-type name="Symbol" /></type>
172                                 </arg>
173                         </arguments>
174                         <description>
175                                 <p>The functional alternative to using the form of <syntax name="character" /> based on glyph names.  Using the syntax <syntax name="character" /> is more efficient when the argument is known beforehand.</p>
176                         </description>
177                 </case>
178         </function>
179 </system-binding>
181 </section>