ReactOS  0.4.14-dev-317-g96040ec
NtGdiCreateCompatibleDC.c File Reference
#include <win32nt.h>
Include dependency graph for NtGdiCreateCompatibleDC.c:

Go to the source code of this file.

Functions

 START_TEST (NtGdiCreateCompatibleDC)
 

Function Documentation

◆ START_TEST()

START_TEST ( NtGdiCreateCompatibleDC  )

Definition at line 10 of file NtGdiCreateCompatibleDC.c.

11 {
12  HDC hDC;
13  HGDIOBJ hObj;
14 
15  /* Test if aa NULL DC is accepted */
17  ok(hDC != NULL, "hDC was NULL.\n");
18 
19  /* We select a nwe palette. Note: SelectObject doesn't work with palettes! */
21  /* The old palette should be GetStockObject(DEFAULT_PALETTE) */
23 
24  /* The default bitmap should be GetStockObject(21) */
25  hObj = SelectObject(hDC, GetStockObject(21));
26  ok_ptr(hObj, GetStockObject(21));
27 
28  /* The default pen should be GetStockObject(BLACK_PEN) */
31 
32  ok(NtGdiDeleteObjectApp(hDC) != 0, "NtGdiDeleteObjectApp(hDC) was zero.\n");
33 }
HGDIOBJ WINAPI GetStockObject(_In_ int)
#define WHITE_PEN
Definition: wingdi.h:904
static HDC
Definition: imagelist.c:92
HGDIOBJ WINAPI SelectObject(_In_ HDC, _In_ HGDIOBJ)
Definition: dc.c:1497
#define ok_ptr(expression, result)
Definition: atltest.h:108
HPALETTE WINAPI SelectPalette(_In_ HDC, _In_ HPALETTE, _In_ BOOL)
smooth NULL
Definition: ftsmooth.c:416
#define DEFAULT_PALETTE
Definition: wingdi.h:912
__kernel_entry W32KAPI HDC APIENTRY NtGdiCreateCompatibleDC(_In_opt_ HDC hdc)
static HDC hDC
Definition: 3dtext.c:33
__kernel_entry W32KAPI BOOL APIENTRY NtGdiDeleteObjectApp(_In_ HANDLE hobj)
#define BLACK_PEN
Definition: wingdi.h:902
#define ok(value,...)
Definition: atltest.h:57