赞
踩
-
- CRect rectCheck = rectBox;
- rectCheck.left += 3;
- rectCheck.top += 3;
-
- penLed.DeleteObject();
- penLed.CreatePen(PS_SOLID, 1, RGB(19, 202, 0));
- pDC->SelectObject(&penLed);
- brushLed.DeleteObject();
- brushLed.CreateSolidBrush(RGB(19, 202, 0));
- POINT p[] = {
- {rectCheck.left + 0, rectCheck.top + 2},
- {rectCheck.left + 2, rectCheck.top + 4},
- {rectCheck.left + 6, rectCheck.top + 0},
- {rectCheck.left + 6, rectCheck.top + 2},
- {rectCheck.left + 2, rectCheck.top + 6},
- {rectCheck.left + 0, rectCheck.top + 4},
- {rectCheck.left + 0, rectCheck.top + 2}
- };
- pDC->Polygon(p,7);
- CRgn rg;
- rg.CreatePolygonRgn(p,7,WINDING);
- pDC->FillRgn(&rg,&brushLed);
运行结果为一个对号!
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。