15,979
社区成员
发帖
与我相关
我的任务
分享
case WM_PAINT:
hdc = BeginPaint (hwnd, &ps) ;
SetViewportOrgEx (hdc, cxClient / 2, cyClient / 2, NULL);
SelectClipRgn (hdc, hRgnClip);
fRadius = _hypot (cxClient / 2.0, cyClient / 2.0);
for (fAngle = 0.0; fAngle < TWO_PI; fAngle += TWO_PI / 360)
{
MoveToEx (hdc, 0, 0, NULL);
LineTo (hdc, (int) ( fRadius * cos (fAngle) + 0.5),
(int) (-fRadius * sin (fAngle) + 0.5));
}
EndPaint (hwnd, &ps) ;
return 0 ;