17#define ok_rect(rc, l,r,t,b) ok((rc.left == (l)) && (rc.right == (r)) && (rc.top == (t)) && (rc.bottom == (b)), "Wrong rect. expected %d, %d, %d, %d got %ld, %ld, %ld, %ld\n", l,t,r,b, rc.left, rc.top, rc.right, rc.bottom)
18#define ok_size(s, width, height) ok((s.cx == (width) && s.cy == (height)), "Expected size (%lu,%lu) got (%lu,%lu)\n", (LONG)width, (LONG)height, s.cx, s.cy)
26 hwnd1 =
CreateWindowW(
L"Button",
L"Test1", 0, 10, 10, 100, 100, 0,
NULL,
NULL,
NULL);
27 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
31 ok (
ret ==
TRUE,
"Expected BCM_GETTEXTMARGIN to succeed\n");
36 ok (
ret ==
TRUE,
"Expected BCM_SETTEXTMARGIN to succeed\n");
39 ok (
ret ==
TRUE,
"Expected BCM_GETTEXTMARGIN to succeed\n");
44 ok (
ret ==
TRUE,
"Expected BCM_SETTEXTMARGIN to succeed\n");
47 ok (
ret ==
TRUE,
"Expected BCM_GETTEXTMARGIN to succeed\n");
50 SetRect(&rc, 1000,1000,1000,1000);
52 ok (
ret ==
TRUE,
"Expected BCM_SETTEXTMARGIN to succeed\n");
55 ok (
ret ==
TRUE,
"Expected BCM_GETTEXTMARGIN to succeed\n");
56 ok_rect(rc, 1000, 1000, 1000, 1000);
60 hwnd1 =
CreateWindowW(
L"Button",
L"Test1",
BS_DEFPUSHBUTTON, 10, 10, 100, 100, 0,
NULL,
NULL,
NULL);
61 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
65 ok (
ret ==
TRUE,
"Expected BCM_GETTEXTMARGIN to succeed\n");
78 hwnd1 =
CreateWindowW(
L"Button",
L"Test2", 0, 10, 10, 100, 100, 0,
NULL,
NULL,
NULL);
79 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
82 ok (
ret ==
TRUE,
"Expected BCM_GETIMAGELIST to succeed\n");
83 ok (imlData.
himl == 0,
"Expected 0 himl\n");
84 ok (imlData.
uAlign == 0,
"Expected 0 uAlign\n");
89 ok (
ret ==
FALSE,
"Expected BCM_SETIMAGELIST to fail\n");
93 ok (
ret ==
TRUE,
"Expected BCM_SETIMAGELIST to fail\n");
96 ok (
ret ==
TRUE,
"Expected BCM_GETIMAGELIST to succeed\n");
98 ok (imlData.
uAlign == 0,
"Expected 0 uAlign\n");
103 ok (
ret ==
FALSE,
"Expected BCM_SETIMAGELIST to fail\n");
122 hwnd2 =
CreateWindowW(
L"Static",
L"", 0, 0, 0, 100, 100, 0,
NULL,
NULL,
NULL);
123 ok (hwnd2 !=
NULL,
"Expected CreateWindowW to succeed\n");
125 hwnd1 =
CreateWindowW(
L"Button",
L" ",
WS_CHILD, 10, 10, 100, 100, hwnd2,
NULL,
NULL,
NULL);
126 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
136 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
143 hwnd1 =
CreateWindowW(
L"Button",
L" ",
BS_USERBUTTON |
WS_CHILD, 10, 10, 100, 100, hwnd2,
NULL,
NULL,
NULL);
144 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
149 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
157 hwnd1 =
CreateWindowW(
L"Button",
L"",
WS_CHILD, 10, 10, 100, 100, hwnd2,
NULL,
NULL,
NULL);
158 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
164 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
168 ok (
hbmp != 0,
"Expected LoadImage to succeed\n");
174 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
178 ok (
himl != 0,
"Expected ImageList_LoadImage to succeed\n");
180 memset(&imlData, 0,
sizeof(imlData));
183 ok (
ret ==
TRUE,
"Expected BCM_SETIMAGELIST to fail\n");
187 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
196 hwnd1 =
CreateWindowW(
L"Button",
L"",
WS_CHILD, 10, 10, 5, 5, hwnd2,
NULL,
NULL,
NULL);
197 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
202 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
210 hwnd1 =
CreateWindowW(
L"Button",
L" ",
BS_BITMAP |
WS_CHILD, 10, 10, 100, 100, hwnd2,
NULL,
NULL,
NULL);
211 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
218 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
228 hwnd1 =
CreateWindowW(
L"Button",
L" ",
WS_CHILD, 10, 10, 100, 100, hwnd2,
NULL,
NULL,
NULL);
229 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
234 ok (
ret ==
TRUE,
"Expected BCM_SETTEXTMARGIN to succeed\n");
238 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
244 ok (
ret ==
TRUE,
"Expected BCM_SETTEXTMARGIN to succeed\n");
248 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
250 textent.
cy + 7 + 100);
254 ok (
ret ==
TRUE,
"Expected BCM_SETTEXTMARGIN to succeed\n");
257 ok (
ret ==
TRUE,
"Expected BCM_SETIMAGELIST to fail\n");
261 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
268 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
275 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
281 ok (
ret ==
TRUE,
"Expected BCM_SETIMAGELIST to fail\n");
285 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
292 ok (
ret ==
TRUE,
"Expected BCM_SETIMAGELIST to fail\n");
296 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
307 hwnd1 =
CreateWindowW(
L"Button",
L"Start",
BS_VCENTER |
WS_CHILD, 0, 0, 0, 0, hwnd2,
NULL,
NULL,
NULL);
308 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
318 ok (
ret ==
TRUE,
"Expected BCM_SETTEXTMARGIN to succeed\n");
322 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
331 hwnd1 =
CreateWindowW(
L"Button",
L"Some test text",
WS_CHILD, 10, 10, 100, 100, hwnd2,
NULL,
NULL,
NULL);
332 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
342 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
360 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
373 hwnd1 =
CreateWindowW(
L"Button",
L" ",
i|
WS_CHILD, 0, 0, 72, 72, hwnd2,
NULL,
NULL,
NULL);
374 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
377 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
383 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
387 hwnd1 =
CreateWindowW(
L"Button",
L" ",
i|
WS_CHILD, 0, 0, 12, 12, hwnd2,
NULL,
NULL,
NULL);
388 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
391 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
396 hwnd1 =
CreateWindowW(
L"Button",
L"",
i|
WS_CHILD, 0, 0, 72, 72, hwnd2,
NULL,
NULL,
NULL);
397 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
400 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
404 hwnd1 =
CreateWindowW(
L"Button",
L"",
i|
WS_CHILD, 0, 0, 150, 72, hwnd2,
NULL,
NULL,
NULL);
405 ok (hwnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
408 ok (
ret ==
TRUE,
"Expected BCM_GETIDEALSIZE to succeed\n");
418#define MOVE_CURSOR(x,y) mouse_event(MOUSEEVENTF_MOVE | MOUSEEVENTF_ABSOLUTE , \
419 x*(65535/GetSystemMetrics(SM_CXVIRTUALSCREEN)), \
420 y*(65535/GetSystemMetrics(SM_CYVIRTUALSCREEN)) , 0,0);
644 {2, WM_THEMECHANGED,
SENT},
704 hWnd1 =
CreateWindowW(
L"testClass",
L"Test parent",
WS_POPUP |
WS_VISIBLE, 100, 100, 200, 200, 0,
NULL,
NULL,
NULL);
705 ok (
hWnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
709 hWnd2 =
CreateWindowW(
L"Button",
L"test button",
WS_CHILD |
WS_VISIBLE, 0, 0, 100, 100,
hWnd1,
NULL,
NULL,
NULL);
710 ok (
hWnd2 !=
NULL,
"Expected CreateWindowW to succeed\n");
838 hWnd1 =
CreateWindowW(
L"testClass",
L"Test parent",
WS_POPUP |
WS_VISIBLE, 100, 100, 200, 200, 0,
NULL,
NULL,
NULL);
839 ok (
hWnd1 !=
NULL,
"Expected CreateWindowW to succeed\n");
842 hWnd2 =
CreateWindowW(
L"Button",
L"test button",
WS_CHILD |
WS_VISIBLE, 0, 0, 100, 100,
hWnd1,
NULL,
NULL,
NULL);
843 ok (
hWnd2 !=
NULL,
"Expected CreateWindowW to succeed\n");
937 skip(
"No active theme, skipping Test_MessagesThemed\n");
#define ok_hex(expression, result)
BOOL WINAPI SetWindowSubclass(HWND hWnd, SUBCLASSPROC pfnSubclass, UINT_PTR uIDSubclass, DWORD_PTR dwRef)
LRESULT WINAPI DefSubclassProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
BOOL WINAPI IsThemeActive(void)
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
static DWORD *static HFONT(WINAPI *pCreateFontIndirectExA)(const ENUMLOGFONTEXDVA *)
#define RECORD_MESSAGE(...)
#define COMPARE_CACHE(msg_chain)
unsigned __int3264 UINT_PTR
#define ImageList_LoadImage
struct _IMAGELIST * HIMAGELIST
#define BCN_HOTITEMCHANGE
#define BCM_SETTEXTMARGIN
#define BCM_GETTEXTMARGIN
_CRTIMP wchar_t *__cdecl wcscpy(_Out_writes_z_(_String_length_(_Source)+1) wchar_t *_Dest, _In_z_ const wchar_t *_Source)
WCHAR lfFaceName[LF_FACESIZE]
TW_UINT32 TW_UINT16 TW_UINT16 MSG
static __inline ATOM RegisterSimpleClass(WNDPROC lpfnWndProc, LPCWSTR lpszClassName)
HRESULT WINAPI SetWindowTheme(_In_ HWND hwnd, _In_ LPCWSTR pszSubAppName, _In_ LPCWSTR pszSubIdList)
HGDIOBJ WINAPI SelectObject(_In_ HDC, _In_ HGDIOBJ)
HFONT WINAPI CreateFontIndirectW(_In_ const LOGFONTW *)
BOOL WINAPI GetTextExtentPoint32W(_In_ HDC hdc, _In_reads_(c) LPCWSTR lpString, _In_ int c, _Out_ LPSIZE psizl)
BOOL WINAPI RedrawWindow(_In_opt_ HWND, _In_opt_ LPCRECT, _In_opt_ HRGN, _In_ UINT)
#define WM_CAPTURECHANGED
#define WM_IME_SETCONTEXT
BOOL WINAPI UpdateWindow(_In_ HWND)
HDC WINAPI GetDC(_In_opt_ HWND)
#define CreateWindowW(a, b, c, d, e, f, g, h, i, j, k)
LRESULT WINAPI DispatchMessageW(_In_ const MSG *)
#define RDW_INTERNALPAINT
BOOL WINAPI DestroyWindow(_In_ HWND)
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI SetRect(_Out_ LPRECT, _In_ int, _In_ int, _In_ int, _In_ int)