ReactOS 0.4.15-dev-8109-gd7be748
drawing.cpp
Go to the documentation of this file.
1/*
2 * PROJECT: PAINT for ReactOS
3 * LICENSE: LGPL-2.0-or-later (https://spdx.org/licenses/LGPL-2.0-or-later)
4 * PURPOSE: The drawing functions used by the tools
5 * COPYRIGHT: Copyright 2015 Benedikt Freisen <b.freisen@gmx.net>
6 */
7
8#include "precomp.h"
9
10/* FUNCTIONS ********************************************************/
11
12void
14{
15 HPEN oldPen = (HPEN) SelectObject(hdc, CreatePen(PS_SOLID, thickness, color));
16 MoveToEx(hdc, x1, y1, NULL);
17 LineTo(hdc, x2, y2);
20}
21
22void
23Rect(HDC hdc, LONG x1, LONG y1, LONG x2, LONG y2, COLORREF fg, COLORREF bg, int thickness, int style)
24{
25 HBRUSH oldBrush;
26 LOGBRUSH logbrush;
27 HPEN oldPen = (HPEN) SelectObject(hdc, CreatePen(PS_SOLID, thickness, fg));
28 logbrush.lbStyle = (style == 0) ? BS_HOLLOW : BS_SOLID;
29 logbrush.lbColor = (style == 2) ? fg : bg;
30 logbrush.lbHatch = 0;
31 oldBrush = (HBRUSH) SelectObject(hdc, CreateBrushIndirect(&logbrush));
32 Rectangle(hdc, x1, y1, x2, y2);
33 DeleteObject(SelectObject(hdc, oldBrush));
35}
36
37void
38Ellp(HDC hdc, LONG x1, LONG y1, LONG x2, LONG y2, COLORREF fg, COLORREF bg, int thickness, int style)
39{
40 HBRUSH oldBrush;
41 LOGBRUSH logbrush;
42 HPEN oldPen = (HPEN) SelectObject(hdc, CreatePen(PS_SOLID, thickness, fg));
43 logbrush.lbStyle = (style == 0) ? BS_HOLLOW : BS_SOLID;
44 logbrush.lbColor = (style == 2) ? fg : bg;
45 logbrush.lbHatch = 0;
46 oldBrush = (HBRUSH) SelectObject(hdc, CreateBrushIndirect(&logbrush));
47 Ellipse(hdc, x1, y1, x2, y2);
48 DeleteObject(SelectObject(hdc, oldBrush));
50}
51
52void
53RRect(HDC hdc, LONG x1, LONG y1, LONG x2, LONG y2, COLORREF fg, COLORREF bg, int thickness, int style)
54{
55 LOGBRUSH logbrush;
56 HBRUSH oldBrush;
57 HPEN oldPen = (HPEN) SelectObject(hdc, CreatePen(PS_SOLID, thickness, fg));
58 logbrush.lbStyle = (style == 0) ? BS_HOLLOW : BS_SOLID;
59 logbrush.lbColor = (style == 2) ? fg : bg;
60 logbrush.lbHatch = 0;
61 oldBrush = (HBRUSH) SelectObject(hdc, CreateBrushIndirect(&logbrush));
62 RoundRect(hdc, x1, y1, x2, y2, 16, 16);
63 DeleteObject(SelectObject(hdc, oldBrush));
65}
66
67void
68Poly(HDC hdc, POINT * lpPoints, int nCount, COLORREF fg, COLORREF bg, int thickness, int style, BOOL closed, BOOL inverted)
69{
70 LOGBRUSH logbrush;
71 HBRUSH oldBrush;
72 HPEN oldPen = (HPEN) SelectObject(hdc, CreatePen(PS_SOLID, thickness, fg));
73 UINT oldRop = GetROP2(hdc);
74
75 if (inverted)
77
78 logbrush.lbStyle = (style == 0) ? BS_HOLLOW : BS_SOLID;
79 logbrush.lbColor = (style == 2) ? fg : bg;
80 logbrush.lbHatch = 0;
81 oldBrush = (HBRUSH) SelectObject(hdc, CreateBrushIndirect(&logbrush));
82 if (closed)
83 Polygon(hdc, lpPoints, nCount);
84 else
85 Polyline(hdc, lpPoints, nCount);
86 DeleteObject(SelectObject(hdc, oldBrush));
88
89 SetROP2(hdc, oldRop);
90}
91
92void
93Bezier(HDC hdc, POINT p1, POINT p2, POINT p3, POINT p4, COLORREF color, int thickness)
94{
95 HPEN oldPen;
96 POINT fourPoints[4];
97 fourPoints[0] = p1;
98 fourPoints[1] = p2;
99 fourPoints[2] = p3;
100 fourPoints[3] = p4;
101 oldPen = (HPEN) SelectObject(hdc, CreatePen(PS_SOLID, thickness, color));
102 PolyBezier(hdc, fourPoints, 4);
103 DeleteObject(SelectObject(hdc, oldPen));
104}
105
106void
108{
109 HBRUSH oldBrush = (HBRUSH) SelectObject(hdc, CreateSolidBrush(color));
111 DeleteObject(SelectObject(hdc, oldBrush));
112}
113
114void
116{
117 LONG b = max(1, max(labs(x2 - x1), labs(y2 - y1)));
118 HBRUSH hbr = ::CreateSolidBrush(color);
119
120 for (LONG a = 0; a <= b; a++)
121 {
122 LONG cx = (x1 * (b - a) + x2 * a) / b;
123 LONG cy = (y1 * (b - a) + y2 * a) / b;
124 RECT rc = { cx - radius, cy - radius, cx + radius, cy + radius };
125 ::FillRect(hdc, &rc, hbr);
126 }
127
128 ::DeleteObject(hbr);
129}
130
131void
133{
134 LONG b = max(1, max(labs(x2 - x1), labs(y2 - y1)));
135
136 for (LONG a = 0; a <= b; a++)
137 {
138 LONG cx = (x1 * (b - a) + x2 * a) / b;
139 LONG cy = (y1 * (b - a) + y2 * a) / b;
140 RECT rc = { cx - radius, cy - radius, cx + radius, cy + radius };
141 for (LONG y = rc.top; y < rc.bottom; ++y)
142 {
143 for (LONG x = rc.left; x < rc.right; ++x)
144 {
145 if (::GetPixel(hdc, x, y) == fg)
146 ::SetPixelV(hdc, x, y, bg);
147 }
148 }
149 }
150}
151
152void
154{
155 for (LONG dy = -r; dy <= r; dy++)
156 {
157 for (LONG dx = -r; dx <= r; dx++)
158 {
159 if ((dx * dx + dy * dy <= r * r) && (rand() % r == 0))
160 ::SetPixelV(hdc, x + dx, y + dy, color);
161 }
162 }
163}
164
165void
167{
168 HPEN oldPen = (HPEN) SelectObject(hdc, CreatePen(PS_SOLID, 1, color));
169 HBRUSH oldBrush = (HBRUSH) SelectObject(hdc, CreateSolidBrush(color));
170
171 if (thickness <= 1)
172 {
173 Line(hdc, x1, y1, x2, y2, color, thickness);
174 }
175 else
176 {
177 LONG a, b = max(1, max(labs(x2 - x1), labs(y2 - y1)));
178 switch ((BrushStyle)style)
179 {
180 case BrushStyleRound:
181 for (a = 0; a <= b; a++)
182 {
183 Ellipse(hdc,
184 (x1 * (b - a) + x2 * a) / b - (thickness / 2),
185 (y1 * (b - a) + y2 * a) / b - (thickness / 2),
186 (x1 * (b - a) + x2 * a) / b + (thickness / 2),
187 (y1 * (b - a) + y2 * a) / b + (thickness / 2));
188 }
189 break;
190
191 case BrushStyleSquare:
192 for (a = 0; a <= b; a++)
193 {
195 (x1 * (b - a) + x2 * a) / b - (thickness / 2),
196 (y1 * (b - a) + y2 * a) / b - (thickness / 2),
197 (x1 * (b - a) + x2 * a) / b + (thickness / 2),
198 (y1 * (b - a) + y2 * a) / b + (thickness / 2));
199 }
200 break;
201
204 {
205 POINT offsetTop, offsetBottom;
207 {
208 offsetTop = { (thickness - 1) / 2, -(thickness - 1) / 2 };
209 offsetBottom = { -thickness / 2, thickness / 2 };
210 }
211 else
212 {
213 offsetTop = { -thickness / 2, -thickness / 2 };
214 offsetBottom = { (thickness - 1) / 2, (thickness - 1) / 2 };
215 }
216 POINT points[4] =
217 {
218 { x1 + offsetTop.x, y1 + offsetTop.y },
219 { x1 + offsetBottom.x, y1 + offsetBottom.y },
220 { x2 + offsetBottom.x, y2 + offsetBottom.y },
221 { x2 + offsetTop.x, y2 + offsetTop.y },
222 };
224 break;
225 }
226 }
227 }
228 DeleteObject(SelectObject(hdc, oldBrush));
229 DeleteObject(SelectObject(hdc, oldPen));
230}
231
232void
234{
235 HBRUSH oldBrush;
236 LOGBRUSH logbrush;
237 HPEN oldPen = (HPEN) SelectObject(hdc, CreatePen(PS_DOT, 1, GetSysColor(COLOR_HIGHLIGHT)));
238 UINT oldRop = GetROP2(hdc);
239
241
242 logbrush.lbStyle = BS_HOLLOW;
243 logbrush.lbColor = 0;
244 logbrush.lbHatch = 0;
245 oldBrush = (HBRUSH) SelectObject(hdc, CreateBrushIndirect(&logbrush));
246 Rectangle(hdc, x1, y1, x2, y2);
247 DeleteObject(SelectObject(hdc, oldBrush));
248 DeleteObject(SelectObject(hdc, oldPen));
249
250 SetROP2(hdc, oldRop);
251}
252
253void
255{
256 INT iSaveDC = ::SaveDC(hdc); // We will modify the clipping region. Save now.
257
258 CRect rc = { x1, y1, x2, y2 };
259
260 if (style == 0) // Transparent
261 {
263 }
264 else // Opaque
265 {
267 ::SetBkColor(hdc, bg);
268
269 HBRUSH hbr = ::CreateSolidBrush(bg);
270 ::FillRect(hdc, &rc, hbr); // Fill the background
271 ::DeleteObject(hbr);
272 }
273
274 IntersectClipRect(hdc, rc.left, rc.top, rc.right, rc.bottom);
275
276 HGDIOBJ hFontOld = ::SelectObject(hdc, font);
277 ::SetTextColor(hdc, fg);
278 const UINT uFormat = DT_LEFT | DT_TOP | DT_EDITCONTROL | DT_NOPREFIX | DT_NOCLIP |
280 ::DrawTextW(hdc, lpchText, -1, &rc, uFormat);
281 ::SelectObject(hdc, hFontOld);
282
283 ::RestoreDC(hdc, iSaveDC); // Restore
284}
285
286BOOL
287ColorKeyedMaskBlt(HDC hdcDest, int nXDest, int nYDest, int nWidth, int nHeight,
288 HDC hdcSrc, int nXSrc, int nYSrc, int nSrcWidth, int nSrcHeight,
289 HBITMAP hbmMask, COLORREF keyColor)
290{
291 HDC hTempDC1, hTempDC2;
292 HBITMAP hbmTempColor, hbmTempMask;
293 HGDIOBJ hbmOld1, hbmOld2;
294
295 if (hbmMask == NULL)
296 {
297 if (keyColor == CLR_INVALID)
298 {
299 ::StretchBlt(hdcDest, nXDest, nYDest, nWidth, nHeight,
300 hdcSrc, nXSrc, nYSrc, nSrcWidth, nSrcHeight, SRCCOPY);
301 }
302 else
303 {
304 ::GdiTransparentBlt(hdcDest, nXDest, nYDest, nWidth, nHeight,
305 hdcSrc, nXSrc, nYSrc, nSrcWidth, nSrcHeight, keyColor);
306 }
307 return TRUE;
308 }
309 else if (nWidth == nSrcWidth && nHeight == nSrcHeight && keyColor == CLR_INVALID)
310 {
311 ::MaskBlt(hdcDest, nXDest, nYDest, nWidth, nHeight,
312 hdcSrc, nXSrc, nYSrc, hbmMask, 0, 0, MAKEROP4(SRCCOPY, 0xAA0029));
313 return TRUE;
314 }
315
316 hTempDC1 = ::CreateCompatibleDC(hdcDest);
317 hTempDC2 = ::CreateCompatibleDC(hdcDest);
318 hbmTempMask = ::CreateBitmap(nWidth, nHeight, 1, 1, NULL);
319 hbmTempColor = CreateColorDIB(nWidth, nHeight, RGB(255, 255, 255));
320
321 // hbmTempMask <-- hbmMask (stretched)
322 hbmOld1 = ::SelectObject(hTempDC1, hbmMask);
323 hbmOld2 = ::SelectObject(hTempDC2, hbmTempMask);
324 ::StretchBlt(hTempDC2, 0, 0, nWidth, nHeight, hTempDC1, 0, 0, nSrcWidth, nSrcHeight, SRCCOPY);
325 ::SelectObject(hTempDC2, hbmOld2);
326 ::SelectObject(hTempDC1, hbmOld1);
327
328 hbmOld1 = ::SelectObject(hTempDC1, hbmTempColor);
329 if (keyColor == CLR_INVALID)
330 {
331 // hbmTempColor <-- hdcSrc (stretched)
332 ::StretchBlt(hTempDC1, 0, 0, nWidth, nHeight,
333 hdcSrc, nXSrc, nYSrc, nSrcWidth, nSrcHeight, SRCCOPY);
334
335 // hdcDest <-- hbmTempColor (masked)
336 ::MaskBlt(hdcDest, nXDest, nYDest, nWidth, nHeight, hTempDC1, 0, 0,
337 hbmTempMask, 0, 0, MAKEROP4(SRCCOPY, 0xAA0029));
338 }
339 else
340 {
341 // hbmTempColor <-- hdcDest
342 ::BitBlt(hTempDC1, 0, 0, nWidth, nHeight, hdcDest, nXDest, nYDest, SRCCOPY);
343
344 // hbmTempColor <-- hdcSrc (color key)
345 ::GdiTransparentBlt(hTempDC1, 0, 0, nWidth, nHeight,
346 hdcSrc, nXSrc, nYSrc, nSrcWidth, nSrcHeight, keyColor);
347
348 // hdcDest <-- hbmTempColor (masked)
349 ::MaskBlt(hdcDest, nXDest, nYDest, nWidth, nHeight, hTempDC1, 0, 0,
350 hbmTempMask, 0, 0, MAKEROP4(SRCCOPY, 0xAA0029));
351 }
352 ::SelectObject(hTempDC1, hbmOld1);
353
354 ::DeleteObject(hbmTempColor);
355 ::DeleteObject(hbmTempMask);
356 ::DeleteDC(hTempDC2);
357 ::DeleteDC(hTempDC1);
358
359 return TRUE;
360}
361
363{
364 HGDIOBJ oldPen = ::SelectObject(hdc, ::CreatePen(PS_SOLID, 0, RGB(0, 0, 0)));
366 INT oldRop2 = SetROP2(hdc, R2_NOTXORPEN);
368 ::SetROP2(hdc, oldRop2);
369 ::SelectObject(hdc, oldBrush);
371}
Arabic default style
Definition: afstyles.h:94
DWORD GetPixel(LPDIRECTDRAWSURFACE7 Surface, UINT x, UINT y)
Definition: blt.cpp:2
char * Text
Definition: combotst.c:136
HBITMAP CreateColorDIB(int width, int height, COLORREF rgb)
Definition: dib.cpp:65
#define NULL
Definition: types.h:112
#define TRUE
Definition: types.h:120
void RectSel(HDC hdc, LONG x1, LONG y1, LONG x2, LONG y2)
Definition: drawing.cpp:233
void Bezier(HDC hdc, POINT p1, POINT p2, POINT p3, POINT p4, COLORREF color, int thickness)
Definition: drawing.cpp:93
void Ellp(HDC hdc, LONG x1, LONG y1, LONG x2, LONG y2, COLORREF fg, COLORREF bg, int thickness, int style)
Definition: drawing.cpp:38
void Poly(HDC hdc, POINT *lpPoints, int nCount, COLORREF fg, COLORREF bg, int thickness, int style, BOOL closed, BOOL inverted)
Definition: drawing.cpp:68
BOOL ColorKeyedMaskBlt(HDC hdcDest, int nXDest, int nYDest, int nWidth, int nHeight, HDC hdcSrc, int nXSrc, int nYSrc, int nSrcWidth, int nSrcHeight, HBITMAP hbmMask, COLORREF keyColor)
Definition: drawing.cpp:287
void DrawXorRect(HDC hdc, const RECT *prc)
Definition: drawing.cpp:362
void RRect(HDC hdc, LONG x1, LONG y1, LONG x2, LONG y2, COLORREF fg, COLORREF bg, int thickness, int style)
Definition: drawing.cpp:53
void Replace(HDC hdc, LONG x1, LONG y1, LONG x2, LONG y2, COLORREF fg, COLORREF bg, LONG radius)
Definition: drawing.cpp:132
void Erase(HDC hdc, LONG x1, LONG y1, LONG x2, LONG y2, COLORREF color, LONG radius)
Definition: drawing.cpp:115
void Airbrush(HDC hdc, LONG x, LONG y, COLORREF color, LONG r)
Definition: drawing.cpp:153
void Fill(HDC hdc, LONG x, LONG y, COLORREF color)
Definition: drawing.cpp:107
static VOID BitBlt(_In_ ULONG Left, _In_ ULONG Top, _In_ ULONG Width, _In_ ULONG Height, _In_reads_bytes_(Delta *Height) PUCHAR Buffer, _In_ ULONG BitsPerPixel, _In_ ULONG Delta)
Definition: common.c:57
#define RGB(r, g, b)
Definition: precomp.h:71
unsigned int BOOL
Definition: ntddk_ex.h:94
pKey DeleteObject()
GLint GLint GLint GLint GLint x
Definition: gl.h:1548
GLint GLint GLint GLint GLint GLint y
Definition: gl.h:1548
GLdouble GLdouble GLdouble r
Definition: gl.h:2055
GLuint color
Definition: glext.h:6243
GLboolean GLboolean GLboolean b
Definition: glext.h:6204
GLboolean GLboolean GLboolean GLboolean a
Definition: glext.h:6204
GLsizei const GLfloat * points
Definition: glext.h:8112
_Check_return_ long __cdecl labs(_In_ long x)
_Check_return_ int __cdecl rand(void)
Definition: rand.c:10
#define a
Definition: ke_i.h:78
#define b
Definition: ke_i.h:79
GLint dy
Definition: linetemp.h:97
GLint dx
Definition: linetemp.h:97
HDC hdc
Definition: main.c:9
static HBITMAP
Definition: button.c:44
static HDC
Definition: imagelist.c:92
static DWORD *static HFONT(WINAPI *pCreateFontIndirectExA)(const ENUMLOGFONTEXDVA *)
Definition: mk_font.cpp:20
unsigned int UINT
Definition: ndis.h:50
_Out_ LPRECT prc
Definition: ntgdi.h:1658
INT WINAPI DrawTextW(HDC hdc, LPCWSTR str, INT count, LPRECT rect, UINT flags)
Definition: defwnd.c:16
long LONG
Definition: pedump.c:60
BOOL Polygon(CONST PPOINT UnsafePoints, int Count, int polyFillMode)
Definition: polytest.cpp:730
_Out_opt_ int _Out_opt_ int * cy
Definition: commctrl.h:586
_Out_opt_ int * cx
Definition: commctrl.h:585
#define _countof(array)
Definition: sndvol32.h:70
Definition: ncftp.h:79
UINT lbStyle
Definition: wingdi.h:1747
ULONG_PTR lbHatch
Definition: wingdi.h:1749
COLORREF lbColor
Definition: wingdi.h:1748
long y
Definition: polytest.cpp:48
long x
Definition: polytest.cpp:48
LONG right
Definition: windef.h:308
LONG bottom
Definition: windef.h:309
LONG top
Definition: windef.h:307
LONG left
Definition: windef.h:306
#define max(a, b)
Definition: svc.c:63
BrushStyle
Definition: toolsmodel.h:32
@ BrushStyleForeSlash
Definition: toolsmodel.h:35
@ BrushStyleRound
Definition: toolsmodel.h:33
@ BrushStyleBackSlash
Definition: toolsmodel.h:36
@ BrushStyleSquare
Definition: toolsmodel.h:34
int32_t INT
Definition: typedefs.h:58
BOOL WINAPI GdiTransparentBlt(HDC hdcDst, int xDst, int yDst, int wDst, int hDst, HDC hdcSrc, int xSrc, int ySrc, int wSrc, int hSrc, UINT crTransparent)
_In_ CLIPOBJ _In_ BRUSHOBJ _In_ LONG _In_ LONG _In_ LONG x2
Definition: winddi.h:3710
_In_ CLIPOBJ _In_ BRUSHOBJ _In_ LONG _In_ LONG y1
Definition: winddi.h:3709
_In_ CLIPOBJ _In_ BRUSHOBJ _In_ LONG x1
Definition: winddi.h:3708
_In_ CLIPOBJ _In_ BRUSHOBJ _In_ LONG _In_ LONG _In_ LONG _In_ LONG y2
Definition: winddi.h:3711
DWORD COLORREF
Definition: windef.h:300
HBRUSH WINAPI CreateBrushIndirect(_In_ const LOGBRUSH *plb)
BOOL WINAPI PolyBezier(_In_ HDC hdc, _In_reads_(cpt) const POINT *apt, _In_ DWORD cpt)
Definition: painting.c:263
HGDIOBJ WINAPI GetStockObject(_In_ int)
BOOL WINAPI Polyline(_In_ HDC hdc, _In_reads_(cpt) const POINT *apt, _In_ int cpt)
HBITMAP WINAPI CreateBitmap(_In_ INT cx, _In_ INT cy, _In_ UINT cPlanes, _In_ UINT cBitsPerPel, _In_opt_ const VOID *pvBits)
BOOL WINAPI Ellipse(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int)
COLORREF WINAPI SetBkColor(_In_ HDC, _In_ COLORREF)
Definition: dc.c:999
#define PS_DOT
Definition: wingdi.h:588
int WINAPI IntersectClipRect(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int)
#define FLOODFILLSURFACE
Definition: wingdi.h:645
HGDIOBJ WINAPI SelectObject(_In_ HDC, _In_ HGDIOBJ)
Definition: dc.c:1539
BOOL WINAPI MoveToEx(_In_ HDC, _In_ int, _In_ int, _Out_opt_ LPPOINT)
BOOL WINAPI MaskBlt(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ HDC, _In_ int, _In_ int, _In_ HBITMAP, _In_ int, _In_ int, _In_ DWORD)
#define R2_NOTXORPEN
Definition: wingdi.h:351
HDC WINAPI CreateCompatibleDC(_In_opt_ HDC hdc)
#define TRANSPARENT
Definition: wingdi.h:950
BOOL WINAPI StretchBlt(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_opt_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ DWORD)
#define CLR_INVALID
Definition: wingdi.h:883
BOOL WINAPI RestoreDC(_In_ HDC, _In_ int)
#define SRCCOPY
Definition: wingdi.h:333
#define BS_HOLLOW
Definition: wingdi.h:1088
int WINAPI GetROP2(_In_ HDC)
Definition: dc.c:1086
#define NULL_BRUSH
Definition: wingdi.h:901
#define OPAQUE
Definition: wingdi.h:949
BOOL WINAPI SetPixelV(_In_ HDC, _In_ int, _In_ int, _In_ COLORREF)
int WINAPI FillRect(HDC, LPCRECT, HBRUSH)
BOOL WINAPI Rectangle(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int)
int WINAPI SetBkMode(_In_ HDC, _In_ int)
Definition: dc.c:1056
COLORREF WINAPI SetTextColor(_In_ HDC, _In_ COLORREF)
Definition: text.c:918
int WINAPI SetROP2(_In_ HDC, _In_ int)
Definition: dc.c:1107
BOOL WINAPI RoundRect(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int)
HBRUSH WINAPI CreateSolidBrush(_In_ COLORREF)
BOOL WINAPI DeleteDC(_In_ HDC)
HPEN WINAPI CreatePen(_In_ int, _In_ int, _In_ COLORREF)
BOOL WINAPI ExtFloodFill(_In_ HDC, _In_ int, _In_ int, _In_ COLORREF, _In_ UINT)
BOOL WINAPI LineTo(_In_ HDC, _In_ int, _In_ int)
#define BS_SOLID
Definition: wingdi.h:1086
#define PS_SOLID
Definition: wingdi.h:586
int WINAPI SaveDC(_In_ HDC)
#define MAKEROP4(f, b)
Definition: wingdi.h:2946
DWORD WINAPI GetSysColor(_In_ int)
#define DT_NOPREFIX
Definition: winuser.h:537
#define COLOR_HIGHLIGHT
Definition: winuser.h:926
#define DT_NOCLIP
Definition: winuser.h:536
#define DT_LEFT
Definition: winuser.h:534
#define DT_TOP
Definition: winuser.h:542
#define DT_WORDBREAK
Definition: winuser.h:544
#define DT_EXPANDTABS
Definition: winuser.h:532
#define DT_EDITCONTROL
Definition: winuser.h:528
static HDC hdcSrc
Definition: xlate.c:32
const WCHAR * LPCWSTR
Definition: xmlstorage.h:185