3 Test_NtGdiEnumFontOpen(PTESTINFO pti
)
8 PGDI_TABLE_ENTRY pEntry
;
10 hDC
= CreateDCW(L
"DISPLAY",NULL
,NULL
,NULL
);
12 // FIXME: We should load the font first
14 idEnum
= NtGdiEnumFontOpen(hDC
, 2, 0, 32, L
"Courier", ANSI_CHARSET
, &ulCount
);
17 /* we should have a gdi handle here */
18 TEST(GDI_HANDLE_GET_TYPE(idEnum
) == GDI_OBJECT_TYPE_ENUMFONT
);
19 pEntry
= &GdiHandleTable
[GDI_HANDLE_GET_INDEX(idEnum
)];
20 TEST(pEntry
->KernelData
!= NULL
);
21 TEST(pEntry
->ProcessId
== GetCurrentProcessId());
22 TEST(pEntry
->UserData
== 0);
23 TEST(pEntry
->Type
== ((idEnum
>> 16) | GDI_OBJECT_TYPE_ENUMFONT
));
25 /* We should not be able to use DeleteObject() on the handle */
26 TEST(DeleteObject((HGDIOBJ
)idEnum
) == FALSE
);
28 NtGdiEnumFontClose(idEnum
);
30 // Test no logfont (NULL): should word
31 // Test empty lfFaceName string: should not work
34 return APISTATUS_NORMAL
;