CDC::ArcTo

BOOLArcTo(intx1**,inty1,intx2,inty2,intx3,inty3,intx4,inty4);**

BOOLArcTo(LPCRECTlpRect**,POINTptStart,POINTptEnd);**

Return Value

Nonzero if the function is successful; otherwise 0.

Parameters

x1

Specifies the x-coordinate of the upper-left corner of the bounding rectangle (in logical units).

y1

Specifies the y-coordinate of the upper-left corner of the bounding rectangle (in logical units).

x2

Specifies the x-coordinate of the lower-right corner of the bounding rectangle (in logical units).

y2

Specifies the y-coordinate of the lower-right corner of the bounding rectangle (in logical units).

x3

Specifies the x-coordinate of the point that defines the arc’s starting point (in logical units). This point does not have to lie exactly on the arc.

y3

Specifies the y-coordinate of the point that defines the arc’s starting point (in logical units). This point does not have to lie exactly on the arc.

x4

Specifies the x-coordinate of the point that defines the arc’s endpoint (in logical units). This point does not have to lie exactly on the arc.

y4

Specifies the y-coordinate of the point that defines the arc’s endpoint (in logical units). This point does not have to lie exactly on the arc.

lpRect

Specifies the bounding rectangle (in logical units). You can pass either a pointer to a RECT data structure or a CRect object for this parameter.

ptStart

Specifies the x- and y-coordinates of the point that defines the arc’s starting point (in logical units). This point does not have to lie exactly on the arc. You can pass either a POINT data structure or a CPoint object for this parameter.

ptEnd

Specifies the x- and y-coordinates of the point that defines the arc’s ending point (in logical units). This point does not have to lie exactly on the arc. You can pass either a POINT data structure or a CPoint object for this parameter.

Remarks

Draws an elliptical arc. This function is similar to CDC::Arc, except that the current position is updated. The points (x1,y1) and (x2,y2) specify the bounding rectangle. An ellipse formed by the given bounding rectangle defines the curve of the arc. The arc extends counterclockwise (the default arc direction) from the point where it intersects the radial line from the center of the bounding rectangle to (x3,y3). The arc ends where it intersects the radial line from the center of the bounding rectangle to (x4,y4). If the starting point and ending point are the same, a complete ellipse is drawn.

A line is drawn from the current position to the starting point of the arc. If no error occurs, the current position is set to the ending point of the arc. The arc is drawn using the current pen; it is not filled.

CDC OverviewClass MembersHierarchy Chart

See Also   CDC::AngleArc, CDC::Arc, CDC::SetArcDirection,