partly implement gdi32 Escape
[reactos.git] / reactos / dll / win32 / gdi32 / misc / stubs.c
1 /* $Id$
2 *
3 * reactos/lib/gdi32/misc/stubs.c
4 *
5 * GDI32.DLL Stubs
6 *
7 * When you implement one of these functions,
8 * remove its stub from this file.
9 *
10 */
11
12 #include "precomp.h"
13
14 #define SIZEOF_DEVMODEA_300 124
15 #define SIZEOF_DEVMODEA_400 148
16 #define SIZEOF_DEVMODEA_500 156
17 #define SIZEOF_DEVMODEW_300 188
18 #define SIZEOF_DEVMODEW_400 212
19 #define SIZEOF_DEVMODEW_500 220
20
21 #define UNIMPLEMENTED DbgPrint("GDI32: %s is unimplemented, please try again later.\n", __FUNCTION__);
22
23
24 /*
25 * @unimplemented
26 */
27 int
28 STDCALL
29 StretchDIBits(HDC hdc,
30 int XDest,
31 int YDest,
32 int nDestWidth,
33 int nDestHeight,
34 int XSrc,
35 int YSrc,
36 int nSrcWidth,
37 int nSrcHeight,
38 CONST VOID *lpBits,
39 CONST BITMAPINFO *lpBitsInfo,
40 UINT iUsage,
41 DWORD dwRop)
42
43 {
44 /* FIXME share memory */
45 return NtGdiStretchDIBitsInternal(hdc, XDest, YDest, nDestWidth, nDestHeight, XSrc, YSrc,
46 nSrcWidth, nSrcHeight, (LPBYTE)lpBits, (LPBITMAPINFO)lpBitsInfo, (DWORD)iUsage, dwRop, 0, 0, NULL);
47 }
48
49 /*
50 * @implemented
51 *
52 */
53 INT
54 STDCALL
55 SetDIBitsToDevice(
56 HDC hDC,
57 int XDest,
58 int YDest,
59 DWORD Width,
60 DWORD Height,
61 int XSrc,
62 int YSrc,
63 UINT StartScan,
64 UINT ScanLines,
65 CONST VOID *Bits,
66 CONST BITMAPINFO *lpbmi,
67 UINT ColorUse)
68 {
69 return NtGdiSetDIBitsToDeviceInternal(hDC,
70 XDest,
71 YDest,
72 Width,
73 Height,
74 XSrc,
75 YSrc,
76 StartScan,
77 ScanLines,
78 (LPBYTE)Bits,
79 (LPBITMAPINFO)lpbmi,
80 ColorUse,
81 lpbmi->bmiHeader.biSizeImage,
82 lpbmi->bmiHeader.biSize,
83 FALSE,
84 NULL);
85 }
86
87 /*
88 * @unimplemented
89 */
90 BOOL
91 STDCALL
92 PtInRegion(IN HRGN hrgn,
93 int x,
94 int y)
95 {
96 /* FIXME some stuff at user mode need be fixed */
97 return NtGdiPtInRegion(hrgn,x,y);
98 }
99
100 /*
101 * @unimplemented
102 */
103 BOOL
104 STDCALL
105 RectInRegion(HRGN hrgn,
106 LPCRECT prcl)
107 {
108 /* FIXME some stuff at user mode need be fixed */
109 return NtGdiRectInRegion(hrgn, (LPRECT) prcl);
110 }
111
112 /*
113 * @unimplemented
114 */
115 BOOL
116 STDCALL
117 RestoreDC(IN HDC hdc,
118 IN INT iLevel)
119 {
120 /* FIXME Sharememory */
121 return NtGdiRestoreDC(hdc, iLevel);
122 }
123
124 /*
125 * @unimplemented
126 */
127 INT
128 STDCALL
129 SaveDC(IN HDC hdc)
130 {
131 /* FIXME Sharememory */
132 return NtGdiSaveDC(hdc);
133 }
134
135
136
137 /*
138 * @unimplemented
139 */
140 BOOL
141 STDCALL
142 CancelDC(HDC hdc)
143 {
144 UNIMPLEMENTED;
145 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
146 return FALSE;
147 }
148
149
150 /*
151 * @unimplemented
152 */
153 int
154 STDCALL
155 DrawEscape(HDC hdc,
156 int a1,
157 int a2,
158 LPCSTR a3)
159 {
160 UNIMPLEMENTED;
161 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
162 return 0;
163 }
164
165
166 /*
167 * @unimplemented
168 */
169 int
170 STDCALL
171 EnumObjects(HDC hdc,
172 int a1,
173 GOBJENUMPROC a2,
174 LPARAM a3)
175 {
176 UNIMPLEMENTED;
177 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
178 return 0;
179 }
180
181
182
183 /*
184 * @implemented
185 */
186 UINT
187 STDCALL
188 GetBoundsRect(
189 HDC hdc,
190 LPRECT lprcBounds,
191 UINT flags
192 )
193 {
194 return NtGdiGetBoundsRect(hdc,lprcBounds,flags & DCB_RESET);
195 }
196
197
198 /*
199 * @unimplemented
200 */
201 UINT
202 STDCALL
203 GetMetaFileBitsEx(
204 HMETAFILE a0,
205 UINT a1,
206 LPVOID a2
207 )
208 {
209 UNIMPLEMENTED;
210 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
211 return 0;
212 }
213
214
215 /*
216 * @unimplemented
217 */
218 DWORD
219 STDCALL
220 GetFontLanguageInfo(
221 HDC hDc
222 )
223 {
224 UNIMPLEMENTED;
225 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
226 return 0;
227 }
228
229 /*
230 * @unimplemented
231 */
232 BOOL
233 STDCALL
234 PlayMetaFile(
235 HDC a0,
236 HMETAFILE a1
237 )
238 {
239 UNIMPLEMENTED;
240 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
241 return FALSE;
242 }
243
244 /*
245 * @implemented
246 */
247 UINT
248 STDCALL
249 SetBoundsRect(HDC hdc,
250 CONST RECT *prc,
251 UINT flags)
252 {
253 /* FIXME add check for vaildate the flags */
254 return NtGdiSetBoundsRect(hdc, (LPRECT)prc, flags);
255 }
256
257
258 /*
259 * @unimplemented
260 */
261 DWORD
262 STDCALL
263 SetMapperFlags(
264 HDC a0,
265 DWORD a1
266 )
267 {
268 UNIMPLEMENTED;
269 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
270 return 0;
271 }
272
273 /*
274 * @unimplemented
275 */
276 HMETAFILE
277 STDCALL
278 SetMetaFileBitsEx(
279 UINT a0,
280 CONST BYTE *a1
281 )
282 {
283 UNIMPLEMENTED;
284 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
285 return 0;
286 }
287
288 /*
289 * @unimplemented
290 */
291 BOOL
292 STDCALL
293 PlayMetaFileRecord(
294 HDC a0,
295 LPHANDLETABLE a1,
296 LPMETARECORD a2,
297 UINT a3
298 )
299 {
300 UNIMPLEMENTED;
301 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
302 return FALSE;
303 }
304
305
306 /*
307 * @unimplemented
308 */
309 BOOL
310 STDCALL
311 EnumMetaFile(
312 HDC a0,
313 HMETAFILE a1,
314 MFENUMPROC a2,
315 LPARAM a3
316 )
317 {
318 UNIMPLEMENTED;
319 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
320 return FALSE;
321 }
322
323 /*
324 * @unimplemented
325 */
326 BOOL
327 STDCALL
328 DeleteEnhMetaFile(
329 HENHMETAFILE a0
330 )
331 {
332 UNIMPLEMENTED;
333 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
334 return FALSE;
335 }
336
337 /*
338 * @unimplemented
339 */
340 BOOL
341 STDCALL
342 EnumEnhMetaFile(
343 HDC a0,
344 HENHMETAFILE a1,
345 ENHMFENUMPROC a2,
346 LPVOID a3,
347 CONST RECT *a4
348 )
349 {
350 UNIMPLEMENTED;
351 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
352 return FALSE;
353 }
354
355 /*
356 * @unimplemented
357 */
358 UINT
359 STDCALL
360 GetEnhMetaFileBits(
361 HENHMETAFILE a0,
362 UINT a1,
363 LPBYTE a2
364 )
365 {
366 UNIMPLEMENTED;
367 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
368 return 0;
369 }
370
371
372 /*
373 * @unimplemented
374 */
375 UINT
376 STDCALL
377 GetEnhMetaFileHeader(
378 HENHMETAFILE a0,
379 UINT a1,
380 LPENHMETAHEADER a2
381 )
382 {
383 UNIMPLEMENTED;
384 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
385 return 0;
386 }
387
388 /*
389 * @unimplemented
390 */
391 UINT
392 STDCALL
393 GetEnhMetaFilePaletteEntries(
394 HENHMETAFILE a0,
395 UINT a1,
396 LPPALETTEENTRY a2
397 )
398 {
399 UNIMPLEMENTED;
400 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
401 return 0;
402 }
403
404 /*
405 * @unimplemented
406 */
407 UINT
408 STDCALL
409 GetWinMetaFileBits(
410 HENHMETAFILE a0,
411 UINT a1,
412 LPBYTE a2,
413 INT a3,
414 HDC a4
415 )
416 {
417 UNIMPLEMENTED;
418 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
419 return 0;
420 }
421
422
423 /*
424 * @unimplemented
425 */
426 BOOL
427 STDCALL
428 PlayEnhMetaFile(
429 HDC a0,
430 HENHMETAFILE a1,
431 CONST RECT *a2
432 )
433 {
434 UNIMPLEMENTED;
435 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
436 return FALSE;
437 }
438
439
440 /*
441 * @unimplemented
442 */
443 BOOL
444 STDCALL
445 PlayEnhMetaFileRecord(
446 HDC a0,
447 LPHANDLETABLE a1,
448 CONST ENHMETARECORD *a2,
449 UINT a3
450 )
451 {
452 UNIMPLEMENTED;
453 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
454 return FALSE;
455 }
456
457
458 /*
459 * @unimplemented
460 */
461 HENHMETAFILE
462 STDCALL
463 SetEnhMetaFileBits(
464 UINT a0,
465 CONST BYTE *a1
466 )
467 {
468 UNIMPLEMENTED;
469 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
470 return 0;
471 }
472
473
474 /*
475 * @unimplemented
476 */
477 HENHMETAFILE
478 STDCALL
479 SetWinMetaFileBits(
480 UINT a0,
481 CONST BYTE *a1,
482 HDC a2,
483 CONST METAFILEPICT *a3)
484 {
485 UNIMPLEMENTED;
486 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
487 return 0;
488 }
489
490
491 /*
492 * @unimplemented
493 */
494 BOOL
495 STDCALL
496 GdiComment(
497 HDC hDC,
498 UINT bytes,
499 CONST BYTE *buffer
500 )
501 {
502 #if 0
503 if (GDI_HANDLE_GET_TYPE(hDC) == GDI_OBJECT_TYPE_EMF)
504 {
505 PLDC pLDC = GdiGetLDC(hDC);
506 if ( !pLDC )
507 {
508 SetLastError(ERROR_INVALID_HANDLE);
509 return FALSE;
510 }
511 if (pLDC->iType == LDC_EMFLDC)
512 { // Wine port
513 return EMFDRV_GdiComment( hDC, bytes, buffer );
514 }
515 }
516 #endif
517 return FALSE;
518 }
519
520
521 /*
522 * @unimplemented
523 */
524 BOOL
525 STDCALL
526 AngleArc(
527 HDC hdc,
528 int a1,
529 int a2,
530 DWORD a3,
531 FLOAT a4,
532 FLOAT a5
533 )
534 {
535 UNIMPLEMENTED;
536 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
537 return FALSE;
538 }
539
540
541 /*
542 * @unimplemented
543 */
544 BOOL
545 STDCALL
546 SetColorAdjustment(
547 HDC hdc,
548 CONST COLORADJUSTMENT *a1
549 )
550 {
551 UNIMPLEMENTED;
552 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
553 return FALSE;
554 }
555
556 /*
557 * @unimplemented
558 */
559 int
560 STDCALL
561 EndDoc(
562 HDC hdc
563 )
564 {
565 UNIMPLEMENTED;
566 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
567 return 0;
568 }
569
570
571 /*
572 * @unimplemented
573 */
574 int
575 STDCALL
576 StartPage(
577 HDC hdc
578 )
579 {
580 UNIMPLEMENTED;
581 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
582 return 0;
583 }
584
585
586 /*
587 * @unimplemented
588 */
589 int
590 STDCALL
591 EndPage(
592 HDC hdc
593 )
594 {
595 UNIMPLEMENTED;
596 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
597 return 0;
598 }
599
600
601 /*
602 * @unimplemented
603 */
604 int
605 STDCALL
606 AbortDoc(
607 HDC hdc
608 )
609 {
610 UNIMPLEMENTED;
611 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
612 return 0;
613 }
614
615
616 /*
617 * @unimplemented
618 */
619 int
620 STDCALL
621 SetAbortProc(
622 HDC hdc,
623 ABORTPROC a1
624 )
625 {
626 UNIMPLEMENTED;
627 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
628 return 0;
629 }
630
631 /*
632 * @implemented
633 */
634 BOOL
635 STDCALL
636 UnrealizeObject(HGDIOBJ hgdiobj)
637 {
638 BOOL retValue = TRUE;
639
640 if (GDI_HANDLE_GET_TYPE(hgdiobj) != GDI_OBJECT_TYPE_BRUSH)
641 {
642 retValue = NtGdiUnrealizeObject(hgdiobj);
643 }
644
645 return retValue;
646 }
647
648
649 /*
650 * @implemented
651 */
652 BOOL
653 STDCALL
654 GdiFlush()
655 {
656 NtGdiFlush();
657 return TRUE;
658 }
659
660
661 /*
662 * @unimplemented
663 */
664 int
665 STDCALL
666 SetICMMode(
667 HDC a0,
668 int a1
669 )
670 {
671 UNIMPLEMENTED;
672 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
673 return 0;
674 }
675
676
677 /*
678 * @unimplemented
679 */
680 BOOL
681 STDCALL
682 CheckColorsInGamut(
683 HDC a0,
684 LPVOID a1,
685 LPVOID a2,
686 DWORD a3
687 )
688 {
689 UNIMPLEMENTED;
690 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
691 return FALSE;
692 }
693
694
695 /*
696 * @unimplemented
697 */
698 HCOLORSPACE
699 STDCALL
700 GetColorSpace(HDC hDc)
701 {
702 UNIMPLEMENTED;
703 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
704 return 0;
705 }
706
707
708 /*
709 * @unimplemented
710 */
711 HCOLORSPACE
712 STDCALL
713 SetColorSpace(
714 HDC a0,
715 HCOLORSPACE a1
716 )
717 {
718 UNIMPLEMENTED;
719 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
720 return FALSE;
721 }
722
723 /*
724 * @implemented
725 */
726 BOOL
727 STDCALL
728 GetDeviceGammaRamp( HDC hdc,
729 LPVOID lpGammaRamp)
730 {
731 BOOL retValue = FALSE;
732 if (lpGammaRamp == NULL)
733 {
734 SetLastError(ERROR_INVALID_PARAMETER);
735 }
736 else
737 {
738 retValue = NtGdiGetDeviceGammaRamp(hdc,lpGammaRamp);
739 }
740
741 return retValue;
742 }
743
744 /*
745 * @implemented
746 */
747 BOOL
748 STDCALL
749 SetDeviceGammaRamp(HDC hdc,
750 LPVOID lpGammaRamp)
751 {
752 BOOL retValue = FALSE;
753
754 if (lpGammaRamp)
755 {
756 retValue = NtGdiSetDeviceGammaRamp(hdc, lpGammaRamp);
757 }
758 else
759 {
760 SetLastError(ERROR_INVALID_PARAMETER);
761 }
762
763 return retValue;
764 }
765
766
767 /*
768 * @unimplemented
769 */
770 BOOL
771 STDCALL
772 ColorMatchToTarget(
773 HDC a0,
774 HDC a1,
775 DWORD a2
776 )
777 {
778 UNIMPLEMENTED;
779 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
780 return FALSE;
781 }
782
783
784 /*
785 * @unimplemented
786 */
787 BOOL
788 STDCALL
789 wglCopyContext(
790 HGLRC a0,
791 HGLRC a1,
792 UINT a2
793 )
794 {
795 UNIMPLEMENTED;
796 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
797 return FALSE;
798 }
799
800
801 /*
802 * @unimplemented
803 */
804 HGLRC
805 STDCALL
806 wglCreateContext(
807 HDC hDc
808 )
809 {
810 UNIMPLEMENTED;
811 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
812 return 0;
813 }
814
815
816 /*
817 * @unimplemented
818 */
819 HGLRC
820 STDCALL
821 wglCreateLayerContext(
822 HDC hDc,
823 int a1
824 )
825 {
826 UNIMPLEMENTED;
827 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
828 return 0;
829 }
830
831
832 /*
833 * @unimplemented
834 */
835 BOOL
836 STDCALL
837 wglDeleteContext(
838 HGLRC a
839 )
840 {
841 UNIMPLEMENTED;
842 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
843 return FALSE;
844 }
845
846
847 /*
848 * @unimplemented
849 */
850 HGLRC
851 STDCALL
852 wglGetCurrentContext(VOID)
853 {
854 UNIMPLEMENTED;
855 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
856 return 0;
857 }
858
859
860 /*
861 * @unimplemented
862 */
863 HDC
864 STDCALL
865 wglGetCurrentDC(VOID)
866 {
867 UNIMPLEMENTED;
868 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
869 return 0;
870 }
871
872
873 /*
874 * @unimplemented
875 */
876 PROC
877 STDCALL
878 wglGetProcAddress(
879 LPCSTR a0
880 )
881 {
882 UNIMPLEMENTED;
883 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
884 return 0;
885 }
886
887
888 /*
889 * @unimplemented
890 */
891 BOOL
892 STDCALL
893 wglMakeCurrent(
894 HDC a0,
895 HGLRC a1
896 )
897 {
898 UNIMPLEMENTED;
899 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
900 return FALSE;
901 }
902
903
904 /*
905 * @unimplemented
906 */
907 BOOL
908 STDCALL
909 wglShareLists(
910 HGLRC a0,
911 HGLRC a1
912 )
913 {
914 UNIMPLEMENTED;
915 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
916 return FALSE;
917 }
918
919
920 /*
921 * @unimplemented
922 */
923 BOOL
924 STDCALL
925 wglDescribeLayerPlane(
926 HDC a0,
927 int a1,
928 int a2,
929 UINT a3,
930 LPLAYERPLANEDESCRIPTOR a4
931 )
932 {
933 UNIMPLEMENTED;
934 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
935 return FALSE;
936 }
937
938
939 /*
940 * @unimplemented
941 */
942 int
943 STDCALL
944 wglSetLayerPaletteEntries(
945 HDC a0,
946 int a1,
947 int a2,
948 int a3,
949 CONST COLORREF *a4
950 )
951 {
952 UNIMPLEMENTED;
953 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
954 return 0;
955 }
956
957
958 /*
959 * @unimplemented
960 */
961 int
962 STDCALL
963 wglGetLayerPaletteEntries(
964 HDC a0,
965 int a1,
966 int a2,
967 int a3,
968 COLORREF *a4
969 )
970 {
971 UNIMPLEMENTED;
972 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
973 return 0;
974 }
975
976
977 /*
978 * @unimplemented
979 */
980 BOOL
981 STDCALL
982 wglRealizeLayerPalette(
983 HDC a0,
984 int a1,
985 BOOL a2
986 )
987 {
988 UNIMPLEMENTED;
989 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
990 return FALSE;
991 }
992
993
994 /*
995 * @unimplemented
996 */
997 BOOL
998 STDCALL
999 wglSwapLayerBuffers(
1000 HDC a0,
1001 UINT a1
1002 )
1003 {
1004 UNIMPLEMENTED;
1005 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1006 return FALSE;
1007 }
1008
1009
1010 /* === AFTER THIS POINT I GUESS... =========
1011 * (based on stack size in Norlander's .def)
1012 * === WHERE ARE THEY DEFINED? =============
1013 */
1014
1015 /*
1016 * @unimplemented
1017 */
1018 DWORD
1019 STDCALL
1020 IsValidEnhMetaRecord(
1021 DWORD a0,
1022 DWORD a1
1023 )
1024 {
1025 UNIMPLEMENTED;
1026 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1027 return 0;
1028
1029 }
1030
1031 /*
1032 * @unimplemented
1033 */
1034 DWORD
1035 STDCALL
1036 IsValidEnhMetaRecordOffExt(
1037 DWORD a0,
1038 DWORD a1,
1039 DWORD a2,
1040 DWORD a3
1041 )
1042 {
1043 UNIMPLEMENTED;
1044 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1045 return 0;
1046
1047 }
1048
1049 /*
1050 * @unimplemented
1051 */
1052 DWORD
1053 STDCALL
1054 GetGlyphOutlineWow(
1055 DWORD a0,
1056 DWORD a1,
1057 DWORD a2,
1058 DWORD a3,
1059 DWORD a4,
1060 DWORD a5,
1061 DWORD a6
1062 )
1063 {
1064 UNIMPLEMENTED;
1065 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1066 return 0;
1067 }
1068
1069 /*
1070 * @unimplemented
1071 */
1072 DWORD
1073 STDCALL
1074 gdiPlaySpoolStream(
1075 DWORD a0,
1076 DWORD a1,
1077 DWORD a2,
1078 DWORD a3,
1079 DWORD a4,
1080 DWORD a5
1081 )
1082 {
1083 UNIMPLEMENTED;
1084 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1085 return 0;
1086 }
1087
1088 /*
1089 * @unimplemented
1090 */
1091 HANDLE
1092 STDCALL
1093 AddFontMemResourceEx(
1094 PVOID pbFont,
1095 DWORD cbFont,
1096 PVOID pdv,
1097 DWORD *pcFonts
1098 )
1099 {
1100 UNIMPLEMENTED;
1101 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1102 return 0;
1103 }
1104
1105 /*
1106 * @unimplemented
1107 */
1108 int
1109 STDCALL
1110 AddFontResourceTracking(
1111 LPCSTR lpString,
1112 int unknown
1113 )
1114 {
1115 UNIMPLEMENTED;
1116 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1117 return 0;
1118 }
1119
1120
1121
1122 /*
1123 * @unimplemented
1124 */
1125 HBITMAP
1126 STDCALL
1127 ClearBitmapAttributes(HBITMAP hbm, DWORD dwFlags)
1128 {
1129 UNIMPLEMENTED;
1130 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1131 return 0;
1132 }
1133
1134 /*
1135 * @unimplemented
1136 */
1137 HBRUSH
1138 STDCALL
1139 ClearBrushAttributes(HBRUSH hbm, DWORD dwFlags)
1140 {
1141 UNIMPLEMENTED;
1142 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1143 return 0;
1144 }
1145
1146 /*
1147 * @unimplemented
1148 */
1149 BOOL
1150 STDCALL
1151 ColorCorrectPalette(HDC hDC,HPALETTE hPalette,DWORD dwFirstEntry,DWORD dwNumOfEntries)
1152 {
1153 UNIMPLEMENTED;
1154 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1155 return 0;
1156 }
1157
1158 /*
1159 * @unimplemented
1160 */
1161 int
1162 STDCALL
1163 EndFormPage(HDC hdc)
1164 {
1165 UNIMPLEMENTED;
1166 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1167 return 0;
1168 }
1169
1170
1171
1172 /*
1173 * @unimplemented
1174 */
1175 DWORD
1176 STDCALL
1177 GdiAddGlsBounds(HDC hdc,LPRECT prc)
1178 {
1179 UNIMPLEMENTED;
1180 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1181 return 0;
1182 }
1183
1184 /*
1185 * @unimplemented
1186 */
1187 BOOL
1188 STDCALL
1189 GdiArtificialDecrementDriver(LPWSTR pDriverName,BOOL unknown)
1190 {
1191 UNIMPLEMENTED;
1192 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1193 return 0;
1194 }
1195
1196 /*
1197 * @unimplemented
1198 */
1199 BOOL
1200 STDCALL
1201 GdiCleanCacheDC(HDC hdc)
1202 {
1203 UNIMPLEMENTED;
1204 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1205 return 0;
1206 }
1207
1208 /*
1209 * @unimplemented
1210 */
1211 HDC
1212 STDCALL
1213 GdiConvertAndCheckDC(HDC hdc)
1214 {
1215 UNIMPLEMENTED;
1216 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1217 return 0;
1218 }
1219
1220 /*
1221 * @unimplemented
1222 */
1223 HENHMETAFILE
1224 STDCALL
1225 GdiConvertEnhMetaFile(HENHMETAFILE hmf)
1226 {
1227 UNIMPLEMENTED;
1228 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1229 return 0;
1230 }
1231
1232 /*
1233 * @unimplemented
1234 */
1235 BOOL
1236 STDCALL
1237 GdiDrawStream(HDC dc, ULONG l, VOID *v)
1238 {
1239 UNIMPLEMENTED;
1240 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1241 return 0;
1242 }
1243
1244 /*
1245 * @unimplemented
1246 */
1247 BOOL
1248 STDCALL
1249 GdiIsMetaFileDC(HDC hdc)
1250 {
1251 UNIMPLEMENTED;
1252 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1253 return 0;
1254 }
1255
1256 /*
1257 * @unimplemented
1258 */
1259 BOOL
1260 STDCALL
1261 GdiIsMetaPrintDC(HDC hdc)
1262 {
1263 UNIMPLEMENTED;
1264 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1265 return 0;
1266 }
1267
1268 /*
1269 * @unimplemented
1270 */
1271 BOOL
1272 STDCALL
1273 GdiIsPlayMetafileDC(HDC hdc)
1274 {
1275 UNIMPLEMENTED;
1276 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1277 return 0;
1278 }
1279
1280 /*
1281 * @unimplemented
1282 */
1283 BOOL
1284 STDCALL
1285 GdiValidateHandle(HGDIOBJ hobj)
1286 {
1287 UNIMPLEMENTED;
1288 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1289 return 0;
1290 }
1291
1292 /*
1293 * @unimplemented
1294 */
1295 DWORD
1296 STDCALL
1297 GetBitmapAttributes(HBITMAP hbm)
1298 {
1299 UNIMPLEMENTED;
1300 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1301 return 0;
1302 }
1303
1304 /*
1305 * @unimplemented
1306 */
1307 DWORD
1308 STDCALL
1309 GetBrushAttributes(HBRUSH hbr)
1310 {
1311 UNIMPLEMENTED;
1312 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1313 return 0;
1314 }
1315
1316 /*
1317 * @implemented
1318 */
1319 ULONG
1320 STDCALL
1321 GetEUDCTimeStamp(VOID)
1322 {
1323 return NtGdiGetEudcTimeStampEx(NULL,0,TRUE);
1324 }
1325
1326 /*
1327 * @implemented
1328 */
1329 ULONG
1330 STDCALL
1331 GetFontAssocStatus(HDC hdc)
1332 {
1333 ULONG retValue = 0;
1334
1335 if (hdc)
1336 {
1337 retValue = NtGdiQueryFontAssocInfo(hdc);
1338 }
1339
1340 return retValue;
1341 }
1342
1343 /*
1344 * @implemented
1345 */
1346 BOOL
1347 STDCALL
1348 GetTextExtentExPointWPri(HDC hdc,
1349 LPWSTR lpwsz,
1350 ULONG cwc,
1351 ULONG dxMax,
1352 ULONG *pcCh,
1353 PULONG pdxOut,
1354 LPSIZE psize)
1355 {
1356 return NtGdiGetTextExtentExW(hdc,lpwsz,cwc,dxMax,pcCh,pdxOut,psize,0);
1357 }
1358
1359 /*
1360 * @implemented
1361 */
1362 INT
1363 STDCALL
1364 GetTextFaceAliasW(HDC hdc,
1365 int cChar,
1366 LPWSTR pszOut)
1367 {
1368 INT retValue = 0;
1369 if ((!pszOut) || (cChar))
1370 {
1371 retValue = NtGdiGetTextFaceW(hdc,cChar,pszOut,TRUE);
1372 }
1373 else
1374 {
1375 SetLastError(ERROR_INVALID_PARAMETER);
1376 }
1377 return retValue;
1378 }
1379
1380 /*
1381 * @unimplemented
1382 */
1383 DWORD
1384 STDCALL
1385 QueryFontAssocStatus(VOID)
1386 {
1387 UNIMPLEMENTED;
1388 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1389 return 0;
1390 }
1391
1392 /*
1393 * @implemented
1394 */
1395 BOOL
1396 STDCALL
1397 RemoveFontMemResourceEx(HANDLE fh)
1398 {
1399 BOOL retValue=0;
1400
1401 if (fh)
1402 {
1403 retValue = NtGdiRemoveFontMemResourceEx(fh);
1404 }
1405 else
1406 {
1407 SetLastError(ERROR_INVALID_PARAMETER);
1408 }
1409 return retValue;
1410 }
1411
1412 /*
1413 * @unimplemented
1414 */
1415 int
1416 STDCALL
1417 RemoveFontResourceTracking(LPCSTR lpString,int unknown)
1418 {
1419 UNIMPLEMENTED;
1420 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1421 return 0;
1422 }
1423
1424 /*
1425 * @unimplemented
1426 */
1427 HBITMAP
1428 STDCALL
1429 SetBitmapAttributes(HBITMAP hbm, DWORD dwFlags)
1430 {
1431 UNIMPLEMENTED;
1432 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1433 return 0;
1434 }
1435
1436 /*
1437 * @unimplemented
1438 */
1439 HBRUSH
1440 STDCALL
1441 SetBrushAttributes(HBRUSH hbm, DWORD dwFlags)
1442 {
1443 UNIMPLEMENTED;
1444 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1445 return 0;
1446 }
1447
1448 /*
1449 * @implemented
1450 */
1451 int
1452 STDCALL
1453 StartFormPage(HDC hdc)
1454 {
1455 return StartPage(hdc);
1456 }
1457
1458 /*
1459 * @unimplemented
1460 */
1461 VOID
1462 STDCALL
1463 UnloadNetworkFonts(DWORD unknown)
1464 {
1465 UNIMPLEMENTED;
1466 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1467 }
1468
1469 /*
1470 * @unimplemented
1471 */
1472 BOOL
1473 STDCALL
1474 GdiRealizationInfo(HDC hdc,
1475 PREALIZATION_INFO pri)
1476 {
1477 UNIMPLEMENTED;
1478 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1479 return 0;
1480 }
1481
1482 /*
1483 * @implemented
1484 */
1485 BOOL
1486 STDCALL
1487 GetETM(HDC hdc,
1488 EXTTEXTMETRIC *petm)
1489 {
1490 BOOL Ret = NtGdiGetETM(hdc, petm);
1491
1492 if (Ret && petm)
1493 petm->emKernPairs = GetKerningPairsA(hdc, 0, 0);
1494
1495 return Ret;
1496 }
1497
1498 /*
1499 * @unimplemented
1500 */
1501 int
1502 STDCALL
1503 Escape(HDC hdc, INT nEscape, INT cbInput, LPCSTR lpvInData, LPVOID lpvOutData)
1504 {
1505 int retValue = -1;
1506 HGDIOBJ hObject = hdc;
1507 UINT Type = 0;
1508
1509 Type = GDI_HANDLE_GET_TYPE(hObject);
1510
1511 if (Type == GDI_OBJECT_TYPE_METADC)
1512 {
1513 /* FIXME we do not support metafile */
1514 UNIMPLEMENTED;
1515 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1516 }
1517 else
1518 {
1519 switch (nEscape)
1520 {
1521 case GETCOLORTABLE:
1522 retValue = GetSystemPaletteEntries(hdc, (UINT)*lpvInData, 1, (LPPALETTEENTRY)lpvOutData);
1523 if ( !retValue )
1524 {
1525 retValue = -1;
1526 }
1527 break;
1528
1529 case GETEXTENDEDTEXTMETRICS:
1530 retValue = (int) GetETM( hdc, (EXTTEXTMETRIC *) lpvOutData) != 0;
1531 break;
1532
1533 case GETSCALINGFACTOR:
1534 /* Note GETSCALINGFACTOR is outdated have been replace by GetDeviceCaps */
1535 if ( Type == GDI_OBJECT_TYPE_DC )
1536 {
1537 if ( lpvOutData )
1538 {
1539 PPOINT ptr = (PPOINT) lpvOutData;
1540 ptr->x = 0;
1541 ptr->y = 0;
1542 }
1543 }
1544 retValue = 0;
1545 break;
1546
1547 default:
1548 UNIMPLEMENTED;
1549 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1550 }
1551 }
1552
1553 return retValue;
1554 }
1555
1556 /*
1557 * @unimplemented
1558 */
1559 BOOL
1560 STDCALL
1561 GdiAddGlsRecord(HDC hdc,
1562 DWORD unknown1,
1563 LPCSTR unknown2,
1564 LPRECT unknown3)
1565 {
1566 UNIMPLEMENTED;
1567 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1568 return 0;
1569 }
1570
1571 /*
1572 * @unimplemented
1573 */
1574 HANDLE
1575 STDCALL
1576 GdiConvertMetaFilePict(HGLOBAL hMem)
1577 {
1578 UNIMPLEMENTED;
1579 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1580 return 0;
1581 }
1582
1583 /*
1584 * @implemented
1585 */
1586 DEVMODEW *
1587 STDCALL
1588 GdiConvertToDevmodeW(DEVMODEA *dm)
1589 {
1590 LPDEVMODEW dmw;
1591
1592 dmw = HEAP_alloc(sizeof(DEVMODEW));
1593 #define COPYS(f,len) MultiByteToWideChar ( CP_THREAD_ACP, 0, (LPSTR)dm->f, len, dmw->f, len )
1594 #define COPYN(f) dmw->f = dm->f
1595 COPYS(dmDeviceName, CCHDEVICENAME );
1596 COPYN(dmSpecVersion);
1597 COPYN(dmDriverVersion);
1598 switch ( dm->dmSize )
1599 {
1600 case SIZEOF_DEVMODEA_300:
1601 dmw->dmSize = SIZEOF_DEVMODEW_300;
1602 break;
1603 case SIZEOF_DEVMODEA_400:
1604 dmw->dmSize = SIZEOF_DEVMODEW_400;
1605 break;
1606 case SIZEOF_DEVMODEA_500:
1607 default: /* FIXME what to do??? */
1608 dmw->dmSize = SIZEOF_DEVMODEW_500;
1609 break;
1610 }
1611 COPYN(dmDriverExtra);
1612 COPYN(dmFields);
1613 COPYN(dmPosition.x);
1614 COPYN(dmPosition.y);
1615 COPYN(dmScale);
1616 COPYN(dmCopies);
1617 COPYN(dmDefaultSource);
1618 COPYN(dmPrintQuality);
1619 COPYN(dmColor);
1620 COPYN(dmDuplex);
1621 COPYN(dmYResolution);
1622 COPYN(dmTTOption);
1623 COPYN(dmCollate);
1624 COPYS(dmFormName,CCHFORMNAME);
1625 COPYN(dmLogPixels);
1626 COPYN(dmBitsPerPel);
1627 COPYN(dmPelsWidth);
1628 COPYN(dmPelsHeight);
1629 COPYN(dmDisplayFlags); // aka dmNup
1630 COPYN(dmDisplayFrequency);
1631
1632 if ( dm->dmSize <= SIZEOF_DEVMODEA_300 )
1633 {
1634 return dmw; // we're done with 0x300 fields
1635 }
1636
1637 COPYN(dmICMMethod);
1638 COPYN(dmICMIntent);
1639 COPYN(dmMediaType);
1640 COPYN(dmDitherType);
1641 COPYN(dmReserved1);
1642 COPYN(dmReserved2);
1643
1644 if ( dm->dmSize <= SIZEOF_DEVMODEA_400 )
1645 {
1646 return dmw; // we're done with 0x400 fields
1647 }
1648
1649 COPYN(dmPanningWidth);
1650 COPYN(dmPanningHeight);
1651
1652 return dmw;
1653
1654 #undef COPYN
1655 #undef COPYS
1656 }
1657
1658 /*
1659 * @unimplemented
1660 */
1661 HENHMETAFILE
1662 STDCALL
1663 GdiCreateLocalEnhMetaFile(HENHMETAFILE hmo)
1664 {
1665 UNIMPLEMENTED;
1666 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1667 return 0;
1668 }
1669
1670 /*
1671 * @unimplemented
1672 */
1673 METAFILEPICT *
1674 STDCALL
1675 GdiCreateLocalMetaFilePict(HENHMETAFILE hmo)
1676 {
1677 UNIMPLEMENTED;
1678 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1679 return 0;
1680 }
1681
1682
1683 /*
1684 * @unimplemented
1685 */
1686 HANDLE
1687 STDCALL
1688 GdiGetSpoolFileHandle(LPWSTR pwszPrinterName,
1689 LPDEVMODEW pDevmode,
1690 LPWSTR pwszDocName)
1691 {
1692 UNIMPLEMENTED;
1693 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1694 return 0;
1695 }
1696
1697 /*
1698 * @unimplemented
1699 */
1700 BOOL
1701 STDCALL
1702 GdiDeleteSpoolFileHandle(HANDLE SpoolFileHandle)
1703 {
1704 UNIMPLEMENTED;
1705 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1706 return 0;
1707 }
1708
1709 /*
1710 * @unimplemented
1711 */
1712 DWORD
1713 STDCALL
1714 GdiGetPageCount(HANDLE SpoolFileHandle)
1715 {
1716 UNIMPLEMENTED;
1717 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1718 return 0;
1719 }
1720
1721 /*
1722 * @unimplemented
1723 */
1724 HDC
1725 STDCALL
1726 GdiGetDC(HANDLE SpoolFileHandle)
1727 {
1728 UNIMPLEMENTED;
1729 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1730 return 0;
1731 }
1732
1733 /*
1734 * @unimplemented
1735 */
1736 HANDLE
1737 STDCALL
1738 GdiGetPageHandle(HANDLE SpoolFileHandle,
1739 DWORD Page,
1740 LPDWORD pdwPageType)
1741 {
1742 UNIMPLEMENTED;
1743 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1744 return 0;
1745 }
1746
1747 /*
1748 * @unimplemented
1749 */
1750 BOOL
1751 STDCALL
1752 GdiStartDocEMF(HANDLE SpoolFileHandle,
1753 DOCINFOW *pDocInfo)
1754 {
1755 UNIMPLEMENTED;
1756 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1757 return 0;
1758 }
1759
1760 /*
1761 * @unimplemented
1762 */
1763 BOOL
1764 STDCALL
1765 GdiStartPageEMF(HANDLE SpoolFileHandle)
1766 {
1767 UNIMPLEMENTED;
1768 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1769 return 0;
1770 }
1771
1772 /*
1773 * @unimplemented
1774 */
1775 BOOL
1776 STDCALL
1777 GdiPlayPageEMF(HANDLE SpoolFileHandle,
1778 HANDLE hemf,
1779 RECT *prectDocument,
1780 RECT *prectBorder,
1781 RECT *prectClip)
1782 {
1783 UNIMPLEMENTED;
1784 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1785 return 0;
1786 }
1787
1788 /*
1789 * @unimplemented
1790 */
1791 BOOL
1792 STDCALL
1793 GdiEndPageEMF(HANDLE SpoolFileHandle,
1794 DWORD dwOptimization)
1795 {
1796 UNIMPLEMENTED;
1797 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1798 return 0;
1799 }
1800
1801 /*
1802 * @unimplemented
1803 */
1804 BOOL
1805 STDCALL
1806 GdiEndDocEMF(HANDLE SpoolFileHandle)
1807 {
1808 UNIMPLEMENTED;
1809 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1810 return 0;
1811 }
1812
1813 /*
1814 * @unimplemented
1815 */
1816 BOOL
1817 STDCALL
1818 GdiGetDevmodeForPage(HANDLE SpoolFileHandle,
1819 DWORD dwPageNumber,
1820 PDEVMODEW *pCurrDM,
1821 PDEVMODEW *pLastDM)
1822 {
1823 UNIMPLEMENTED;
1824 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1825 return 0;
1826 }
1827
1828 /*
1829 * @unimplemented
1830 */
1831 BOOL
1832 STDCALL
1833 GdiResetDCEMF(HANDLE SpoolFileHandle,
1834 PDEVMODEW pCurrDM)
1835 {
1836 UNIMPLEMENTED;
1837 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1838 return 0;
1839 }
1840
1841
1842 /*
1843 * @unimplemented
1844 */
1845 INT
1846 STDCALL
1847 CombineRgn(HRGN hDest,
1848 HRGN hSrc1,
1849 HRGN hSrc2,
1850 INT CombineMode)
1851 {
1852 /* FIXME some part should be done in user mode */
1853 return NtGdiCombineRgn(hDest, hSrc1, hSrc2, CombineMode);
1854 }
1855
1856 /*
1857 * @unimplemented
1858 */
1859 HBITMAP STDCALL
1860 CreateBitmap(INT Width,
1861 INT Height,
1862 UINT Planes,
1863 UINT BitsPixel,
1864 PCVOID pUnsafeBits)
1865 {
1866 /* FIXME some part should be done in user mode */
1867 return NtGdiCreateBitmap(Width, Height, Planes, BitsPixel, (LPBYTE) pUnsafeBits);
1868 }
1869
1870 /*
1871 * @unimplemented
1872 */
1873 LPWSTR STDCALL
1874 EngGetDriverName(HDEV hdev)
1875 {
1876 UNIMPLEMENTED;
1877 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1878 return 0;
1879 }
1880
1881 /*
1882 * @unimplemented
1883 */
1884 ULONG STDCALL
1885 XLATEOBJ_iXlate(XLATEOBJ *XlateObj,
1886 ULONG Color)
1887 {
1888 UNIMPLEMENTED;
1889 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1890 return 0;
1891 }
1892
1893 /*
1894 * @unimplemented
1895 */
1896 ULONG *
1897 STDCALL
1898 XLATEOBJ_piVector(XLATEOBJ *XlateObj)
1899 {
1900 return XlateObj->pulXlate;
1901 }
1902
1903 /*
1904 * @unimplemented
1905 */
1906 BOOL
1907 STDCALL
1908 GdiPlayEMF(LPWSTR pwszPrinterName,
1909 LPDEVMODEW pDevmode,
1910 LPWSTR pwszDocName,
1911 EMFPLAYPROC pfnEMFPlayFn,
1912 HANDLE hPageQuery
1913 )
1914 {
1915 UNIMPLEMENTED;
1916 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1917 return 0;
1918 }
1919
1920
1921
1922 /*
1923 * @unimplemented
1924 */
1925 BOOL
1926 STDCALL
1927 GdiPlayPrivatePageEMF(HANDLE SpoolFileHandle,
1928 DWORD unknown,
1929 RECT *prectDocument)
1930 {
1931 UNIMPLEMENTED;
1932 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1933 return 0;
1934 }
1935
1936 /*
1937 * @unimplemented
1938 */
1939 VOID STDCALL GdiInitializeLanguagePack(DWORD InitParam)
1940 {
1941 UNIMPLEMENTED;
1942 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
1943 }
1944
1945
1946 /*
1947 * @implemented
1948 */
1949 INT
1950 STDCALL
1951 ExcludeClipRect(IN HDC hdc, IN INT xLeft, IN INT yTop, IN INT xRight, IN INT yBottom)
1952 {
1953 /* FIXME some part need be done on user mode size */
1954 return NtGdiExcludeClipRect(hdc, xLeft, yTop, xRight, yBottom);
1955 }
1956
1957 /*
1958 * @implemented
1959 */
1960 INT
1961 STDCALL
1962 ExtSelectClipRgn( IN HDC hdc, IN HRGN hrgn, IN INT iMode)
1963 {
1964 /* FIXME some part need be done on user mode size */
1965 return NtGdiExtSelectClipRgn(hdc,hrgn, iMode);
1966 }
1967
1968 /*
1969 * @implemented
1970 */
1971 BOOL
1972 STDCALL
1973 GdiGradientFill(
1974 IN HDC hdc,
1975 IN PTRIVERTEX pVertex,
1976 IN ULONG nVertex,
1977 IN PVOID pMesh,
1978 IN ULONG nMesh,
1979 IN ULONG ulMode)
1980 {
1981 /* FIXME some part need be done in user mode */
1982 return NtGdiGradientFill(hdc, pVertex, nVertex, pMesh, nMesh, ulMode);
1983 }
1984
1985
1986 /*
1987 * @implemented
1988 */
1989 BOOL
1990 STDCALL
1991 GdiTransparentBlt(IN HDC hdcDst,
1992 IN INT xDst,
1993 IN INT yDst,
1994 IN INT cxDst,
1995 IN INT cyDst,
1996 IN HDC hdcSrc,
1997 IN INT xSrc,
1998 IN INT ySrc,
1999 IN INT cxSrc,
2000 IN INT cySrc,
2001 IN COLORREF TransColor
2002 )
2003 {
2004 /* FIXME some part need be done in user mode */
2005 return NtGdiTransparentBlt(hdcDst, xDst, yDst, cxDst, cyDst, hdcSrc, xSrc, ySrc, cxSrc, cySrc, TransColor);
2006 }
2007
2008 /*
2009 * @unimplemented
2010 */
2011 BOOL
2012 STDCALL
2013 GdiPrinterThunk(
2014 IN HUMPD humpd,
2015 DWORD *status,
2016 DWORD unuse)
2017 {
2018 /* FIXME figout the protypes, the HUMPD are a STRUCT or COM object */
2019 /* status contain some form of return value that being save, what it is I do not known */
2020 /* unsue seam have zero effect, what it is for I do not known */
2021
2022 // ? return NtGdiSetPUMPDOBJ(humpd->0x10,TRUE, humpd, ?) <- blackbox, OpenRCE info, and api hooks for anylaysing;
2023 return FALSE;
2024 }
2025
2026 /*
2027 * @unimplemented
2028 *
2029 */
2030 HBITMAP
2031 STDCALL
2032 GdiConvertBitmapV5(
2033 HBITMAP in_format_BitMap,
2034 HBITMAP src_BitMap,
2035 INT bpp,
2036 INT unuse)
2037 {
2038 /* FIXME guessing the prototypes */
2039
2040 /*
2041 * it have create a new bitmap with desired in format,
2042 * then convert it src_bitmap to new format
2043 * and return it as HBITMAP
2044 */
2045
2046 return FALSE;
2047 }
2048
2049
2050 /*
2051 * @implemented
2052 *
2053 */
2054 int
2055 STDCALL
2056 GetDeviceCaps(HDC hdc,
2057 int i)
2058 {
2059 /* FIXME some part need be done in user mode */
2060 return NtGdiGetDeviceCaps(hdc,i);
2061 }
2062
2063 /*
2064 * @implemented
2065 *
2066 */
2067 int
2068 STDCALL
2069 GetClipBox(HDC hdc,
2070 LPRECT lprc)
2071 {
2072 /* FIXME some part need be done in user mode */
2073 return NtGdiGetAppClipBox(hdc, lprc);
2074 }
2075
2076 /*
2077 * @implemented
2078 *
2079 */
2080 DWORD
2081 STDCALL
2082 GetFontData(HDC hdc,
2083 DWORD dwTable,
2084 DWORD dwOffset,
2085 LPVOID lpvBuffer,
2086 DWORD cbData)
2087 {
2088 if (!lpvBuffer)
2089 {
2090 cbData = 0;
2091 }
2092 return NtGdiGetFontData(hdc, dwTable, dwOffset, lpvBuffer, cbData);
2093 }
2094
2095
2096 /*
2097 * @implemented
2098 *
2099 */
2100 DWORD
2101 STDCALL
2102 GetRegionData(HRGN hrgn,
2103 DWORD nCount,
2104 LPRGNDATA lpRgnData)
2105 {
2106 if (!lpRgnData)
2107 {
2108 nCount = 0;
2109 }
2110
2111 return NtGdiGetRegionData(hrgn,nCount,lpRgnData);
2112 }
2113
2114
2115 /*
2116 * @implemented
2117 *
2118 */
2119 INT
2120 STDCALL
2121 GetRgnBox(HRGN hrgn,
2122 LPRECT prcOut)
2123 {
2124 /* FIXME some stuff need be done in user mode */
2125 return NtGdiGetRgnBox(hrgn, prcOut);
2126 }
2127
2128
2129 /*
2130 * @implemented
2131 *
2132 */
2133 INT
2134 STDCALL
2135 OffsetRgn( HRGN hrgn,
2136 int nXOffset,
2137 int nYOffset)
2138 {
2139 /* FIXME some part are done in user mode */
2140 return NtGdiOffsetRgn(hrgn,nXOffset,nYOffset);
2141 }
2142
2143
2144 INT
2145 STDCALL
2146 GetTextCharsetInfo(HDC hdc,
2147 LPFONTSIGNATURE lpSig,
2148 DWORD dwFlags)
2149 {
2150 /* FIXME some part are done in user mode */
2151 return NtGdiGetTextCharsetInfo(hdc, lpSig, dwFlags);
2152 }
2153
2154
2155
2156 INT
2157 STDCALL
2158 IntersectClipRect(HDC hdc,
2159 int nLeftRect,
2160 int nTopRect,
2161 int nRightRect,
2162 int nBottomRect)
2163 {
2164 /* FIXME some part are done in user mode */
2165 return NtGdiIntersectClipRect(hdc, nLeftRect, nTopRect, nRightRect, nBottomRect);
2166 }
2167
2168 INT
2169 STDCALL
2170 OffsetClipRgn(HDC hdc,
2171 int nXOffset,
2172 int nYOffset)
2173 {
2174 /* FIXME some part are done in user mode */
2175 return NtGdiOffsetClipRgn( hdc, nXOffset, nYOffset);
2176 }
2177
2178
2179 INT
2180 STDCALL
2181 NamedEscape(HDC hdc,
2182 PWCHAR pDriver,
2183 INT iEsc,
2184 INT cjIn,
2185 LPSTR pjIn,
2186 INT cjOut,
2187 LPSTR pjOut)
2188 {
2189 /* FIXME metadc, metadc are done most in user mode, and we do not support it
2190 * Windows 2000/XP/Vista ignore the current hdc, that are being pass and always set hdc to NULL
2191 * when it calls to NtGdiExtEscape from NamedEscape
2192 */
2193 return NtGdiExtEscape(NULL,pDriver,wcslen(pDriver),iEsc,cjIn,pjIn,cjOut,pjOut);
2194 }
2195
2196
2197
2198 /*
2199 * @unimplemented
2200 */
2201
2202 /* FIXME wrong protypes, it is a fastcall api */
2203 DWORD
2204 STDCALL
2205 cGetTTFFromFOT(DWORD x1 ,DWORD x2 ,DWORD x3, DWORD x4, DWORD x5, DWORD x6, DWORD x7)
2206 {
2207 UNIMPLEMENTED;
2208 SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
2209 return 0;
2210 }
2211