Windows desktop applications
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

ArcTo function

The ArcTo function draws an elliptical arc.

Syntax


BOOL ArcTo(
  _In_ HDC hdc,
  _In_ int nLeftRect,
  _In_ int nTopRect,
  _In_ int nRightRect,
  _In_ int nBottomRect,
  _In_ int nXRadial1,
  _In_ int nYRadial1,
  _In_ int nXRadial2,
  _In_ int nYRadial2
);

Parameters

hdc [in]

A handle to the device context where drawing takes place.

nLeftRect [in]

The x-coordinate, in logical units, of the upper-left corner of the bounding rectangle.

nTopRect [in]

The y-coordinate, in logical units, of the upper-left corner of the bounding rectangle.

nRightRect [in]

The x-coordinate, in logical units, of the lower-right corner of the bounding rectangle.

nBottomRect [in]

The y-coordinate, in logical units, of the lower-right corner of the bounding rectangle.

nXRadial1 [in]

The x-coordinate, in logical units, of the endpoint of the radial defining the starting point of the arc.

nYRadial1 [in]

The y-coordinate, in logical units, of the endpoint of the radial defining the starting point of the arc.

nXRadial2 [in]

The x-coordinate, in logical units, of the endpoint of the radial defining the ending point of the arc.

nYRadial2 [in]

The y-coordinate, in logical units, of the endpoint of the radial defining the ending point of the arc.

Return value

If the function succeeds, the return value is nonzero.

If the function fails, the return value is zero.

Remarks

ArcTo is similar to the Arc function, except that the current position is updated.

The points (nLeftRect, nTopRect) and (nRightRect, nBottomRect) specify the bounding rectangle. An ellipse formed by the specified bounding rectangle defines the curve of the arc. The arc extends counterclockwise from the point where it intersects the radial line from the center of the bounding rectangle to the (nXRadial1, nYRadial1) point. The arc ends where it intersects the radial line from the center of the bounding rectangle to the (nXRadial2, nYRadial2) point. 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.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Wingdi.h (include Windows.h)

Library

Gdi32.lib

DLL

Gdi32.dll

See also

Lines and Curves Overview
Line and Curve Functions
AngleArc
Arc
SetArcDirection

 

 

Show:
© 2016 Microsoft