Skip to content

Commit cfb5936

Browse files
committed
Changes to documentation for circle() and square()
1 parent 9c3b519 commit cfb5936

File tree

1 file changed

+35
-2
lines changed

1 file changed

+35
-2
lines changed

core/src/processing/core/PGraphics.java

Lines changed: 35 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2729,7 +2729,25 @@ protected void rectImpl(float x1, float y1, float x2, float y2,
27292729
endShape(CLOSE);
27302730
}
27312731

2732-
2732+
/**
2733+
* ( begin auto-generated from square.xml )
2734+
*
2735+
* Draws a square to the screen. A square is a four-sided shape with
2736+
* every angle at ninety degrees and each side is the same length.
2737+
* By default, the first two parameters set the location of the
2738+
* upper-left corner, the third sets the width and height. The way
2739+
* these parameters are interpreted, however, may be changed with the
2740+
* <b>rectMode()</b> function.
2741+
*
2742+
* ( end auto-generated )
2743+
*
2744+
* @webref shape:2d_primitives
2745+
* @param a x-coordinate of the rectangle by default
2746+
* @param b y-coordinate of the rectangle by default
2747+
* @param c width and height of the rectangle by default
2748+
* @see PGraphics#rect(int, int, int, int)
2749+
* @see PGraphics#rectMode(int)
2750+
*/
27332751
public void square(float x, float y, float extent) {
27342752
rect(x, y, extent, extent);
27352753
}
@@ -2910,7 +2928,22 @@ protected void arcImpl(float x, float y, float w, float h,
29102928
showMissingWarning("arc");
29112929
}
29122930

2913-
2931+
/**
2932+
* ( begin auto-generated from circle.xml )
2933+
*
2934+
* Draws a circle to the screen. By default, the first two parameters
2935+
* set the location of the center, and the third sets the shape's width
2936+
* and height. The origin may be changed with the <b>ellipseMode()</b>
2937+
* function.
2938+
*
2939+
* ( end auto-generated )
2940+
* @webref shape:2d_primitives
2941+
* @param a x-coordinate of the ellipse
2942+
* @param b y-coordinate of the ellipse
2943+
* @param c width and height of the ellipse by default
2944+
* @see PApplet#ellipse(float, float, float, float)
2945+
* @see PApplet#ellipseMode(int)
2946+
*/
29142947
public void circle(float x, float y, float extent) {
29152948
ellipse(x, y, extent, extent);
29162949
}

0 commit comments

Comments
 (0)