gdi32/tests: Create a window for justification tests that generate output
instead of painting over the desktop.
This commit is contained in:
parent
795b40187e
commit
6ede7a1130
|
@ -998,10 +998,11 @@ static void testJustification(HDC hdc, PSTR str, RECT *clientArea)
|
|||
|
||||
static void test_SetTextJustification(void)
|
||||
{
|
||||
HDC hdc = GetDC(0);
|
||||
RECT clientArea = {0, 0, 400, 400};
|
||||
HDC hdc;
|
||||
RECT clientArea;
|
||||
LOGFONTA lf;
|
||||
HFONT hfont;
|
||||
HWND hwnd;
|
||||
static char testText[] =
|
||||
"Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do "
|
||||
"eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut "
|
||||
|
@ -1011,6 +1012,10 @@ static void test_SetTextJustification(void)
|
|||
"nulla pariatur. Excepteur sint occaecat cupidatat non proident, "
|
||||
"sunt in culpa qui officia deserunt mollit anim id est laborum.";
|
||||
|
||||
hwnd = CreateWindowExA(0, "static", "", WS_POPUP, 0,0, 400,400, 0, 0, 0, NULL);
|
||||
GetClientRect( hwnd, &clientArea );
|
||||
hdc = GetDC( hwnd );
|
||||
|
||||
memset(&lf, 0, sizeof lf);
|
||||
lf.lfCharSet = ANSI_CHARSET;
|
||||
lf.lfClipPrecision = CLIP_DEFAULT_PRECIS;
|
||||
|
@ -1024,7 +1029,8 @@ static void test_SetTextJustification(void)
|
|||
testJustification(hdc, testText, &clientArea);
|
||||
|
||||
DeleteObject(hfont);
|
||||
ReleaseDC(0, hdc);
|
||||
ReleaseDC(hwnd, hdc);
|
||||
DestroyWindow(hwnd);
|
||||
}
|
||||
|
||||
static void test_font_charset(void)
|
||||
|
|
Loading…
Reference in New Issue