Graphics.drawArc

Overview | Methods | This Package | All Packages

Graphics.drawArc

Draws an elliptical arc in the specified bounding rectangle.

Syntax

public final void drawArc( Rectangle rect, Point start, Point end )

public final void drawArc( Rectangle rect, Point start, Point end, RasterOp op )

public final void drawArc( int x, int y, int width, int height, int startX, int startY, int endX, int endY )

public final void drawArc( int x, int y, int width, int height, int startX, int startY, int endX, int endY, RasterOp op )

Parameters

rect

A Rectangle object that specifies the bounding rectangle for the ellipse.

start

A Point object that specifies the x and y coordinates for the arc's starting point.

end

A Point object that specifies the x and y coordinates for the arc's ending point.

op

A RasterOp object that describes how to render the arc.

x

The x-coordinate for the arc's bounding rectangle.

y

The y-coordinate for the arc's bounding rectangle.

width

The width of the arc's bounding rectangle.

height

The height of the arc's bounding rectangle.

startX

The x-coordinate for the arc's starting point.

startY

The y-coordinate for the arc's starting point.

endX

The x-coordinate for the arc's ending point.

endY

The y-coordinate for the arc's ending point.

Remarks

The drawArc method centers the arc in the specified bounding rectangle. From the center, the arc extends in the current drawing direction to the specified starting point. Next, the arc declines from the center to the specified ending point. If the starting point and ending point are the same, a complete ellipse is drawn.

The drawArc method always draws the arc counterclockwise.