Skip to content

Commit 83ba0f4

Browse files
add square.xml
1 parent d1038f3 commit 83ba0f4

1 file changed

Lines changed: 42 additions & 0 deletions

File tree

‎Reference/api_en/square.xml‎

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2+
<root>
3+
<name>square()</name>
4+
5+
<category>Shape</category>
6+
7+
<subcategory>2D Primitives</subcategory>
8+
9+
<type></type>
10+
11+
<example>
12+
<image />
13+
<code><![CDATA[
14+
square(10, 10, 55)
15+
]]></code>
16+
</example>
17+
18+
<description><![CDATA[
19+
Draws a square to the screen. A square is a four-sided shape with every angle at ninety degrees and each side is the same length. By default, the first two parameters set the location of the upper-left corner, the third sets the width and height. The way these parameters are interpreted, however, may be changed with the <b>rectMode()</b> function.<br />
20+
]]></description>
21+
22+
<syntax>
23+
square(<c>a</c>, <c>b</c>, <c>extent</c>)
24+
</syntax>
25+
26+
<parameter>
27+
<label>a</label>
28+
<description><![CDATA[float: x-coordinate of the square by default]]></description>
29+
</parameter>
30+
31+
<parameter>
32+
<label>b</label>
33+
<description><![CDATA[float: y-coordinate of the square by default]]></description>
34+
</parameter>
35+
36+
<parameter>
37+
<label>extent</label>
38+
<description><![CDATA[float: extent of the square by default]]></description>
39+
</parameter>
40+
41+
<related>rect</related>
42+
<related>rectMode</related>

0 commit comments

Comments
 (0)