Remove NtGdiCheckColorsInGamut as it is not an API.
[reactos.git] / reactos / include / win32k / ntgdibad.h
1 #ifndef WIN32K_NTGDI_BAD_INCLUDED
2 #define WIN32K_NTGDI_BAD_INCLUDED
3
4 /*
5 *
6 * If you want to help, please read this:
7 *
8 * This file contains NtGdi APIs which are specific to ROS, including
9 * a short comment describing the solution on how to use the actual NtGdi
10 * call documented in ntgdi.h. Here are the main cases and information on
11 * how to remove them from this header.
12 *
13 * - Simple rename. This deals with an API simply having a different name,
14 * with absolutely no other changes needed.
15 * - Rename and new parameters. This deals with a case similar to the one
16 * above, except that new parameters have now
17 * been added. This is also usually extremly
18 * simple to fix. Either pass the right params
19 * or pass null/0 values that you ignore.
20 * - Rename and new structure. This is similar to the above, except that the
21 * information is now passed in a differently
22 * named and organized structure. Ask Alex for
23 * the structure you need and he will add it to
24 * ntgdityp.h
25 * - Rename and different semantics. Similar to the previous examples, except
26 * that parameters have usually been removed
27 * or need to be converted in user-mode in
28 * one form of another.
29 * - Does not exist: user-mode. This means that the API can be fully done in
30 * user mode. In 80% of cases, our API was already
31 * returning NOT_IMPLEMENTED in kernel-mode, so
32 * the work to be done is minimal. A good example
33 * are the ICM and Metafile APIs, which can simply
34 * be removed and added into gdi32.
35 * - Does not exist: GDI Shared Objects. This is by far the hardest case. This
36 * class cannot be fixed until ReactOS
37 * has a working Shared GDI Object table
38 * and a DC_ATTR structure in which the
39 * attributes, selection and deletion of
40 * objects can be quickly done from user-
41 * mode without requiring a kernel mode
42 * call.
43 */
44 /* Should be using ENUMFONTDATAW */
45 typedef struct tagFONTFAMILYINFO
46 {
47 ENUMLOGFONTEXW EnumLogFontEx;
48 NEWTEXTMETRICEXW NewTextMetricEx;
49 DWORD FontType;
50 } FONTFAMILYINFO, *PFONTFAMILYINFO;
51
52 /* Should be using NtGdiHfontCreate with an ENUMLOGFONT */
53 HFONT
54 NTAPI
55 NtGdiCreateFontIndirect(CONST LPLOGFONTW lf);
56
57 /* Should be using NtGdiHfontCreate with an ENUMLOGFONT */
58 HFONT
59 NTAPI
60 NtGdiCreateFont(
61 int Height,
62 int Width,
63 int Escapement,
64 int Orientation,
65 int Weight,
66 DWORD Italic,
67 DWORD Underline,
68 DWORD StrikeOut,
69 DWORD CharSet,
70 DWORD OutputPrecision,
71 DWORD ClipPrecision,
72 DWORD Quality,
73 DWORD PitchAndFamily,
74 LPCWSTR Face
75 );
76
77 /* Should be using NtGdiEnumFontChunk */
78 INT
79 NTAPI
80 NtGdiGetFontFamilyInfo(
81 HDC Dc,
82 LPLOGFONTW LogFont,
83 PFONTFAMILYINFO Info,
84 DWORD Size
85 );
86
87 /* Should be using NtGdiEnumFontChunk */
88 BOOL
89 NTAPI
90 NtGdiTranslateCharsetInfo(
91 PDWORD Src,
92 LPCHARSETINFO CSI,
93 DWORD Flags
94 );
95
96 /* The gdi32 call does all the work in user-mode, save for NtGdiMakeFontDir */
97 BOOL
98 NTAPI
99 NtGdiCreateScalableFontResource(
100 DWORD Hidden,
101 LPCWSTR FontRes,
102 LPCWSTR FontFile,
103 LPCWSTR CurrentPath
104 );
105
106 /* The gdi32 call Should Use NtGdiGetRandomRgn and nothing else */
107 HRGN
108 NTAPI
109 NtGdiGetClipRgn(HDC hDC);
110
111 /* The gdi32 call Should Use NtGdiGetTextExtent */
112 BOOL
113 NTAPI
114 NtGdiGetTextExtentPoint32(
115 HDC hDC,
116 LPCWSTR String,
117 int Count,
118 LPSIZE
119 );
120
121 BOOL
122 STDCALL
123 NtGdiGetCharWidth32(
124 HDC hDC,
125 UINT FirstChar,
126 UINT LastChar,
127 LPINT Buffer
128 );
129
130 /* Use NtGdiOpenDCW */
131 HDC
132 NTAPI
133 NtGdiCreateDC(
134 PUNICODE_STRING Driver,
135 PUNICODE_STRING Device,
136 PUNICODE_STRING Output,
137 CONST PDEVMODEW InitData
138 );
139
140 HDC
141 NTAPI
142 NtGdiCreateIC(
143 PUNICODE_STRING Driver,
144 PUNICODE_STRING Device,
145 PUNICODE_STRING Output,
146 CONST PDEVMODEW DevMode
147 );
148
149 /* Use NtGdiAddFontResourceW */
150 int
151 STDCALL
152 NtGdiAddFontResource(PUNICODE_STRING Filename,
153 DWORD fl);
154
155 /* Use NtGdiDoPalette with GdiPalAnimate */
156 BOOL
157 STDCALL
158 NtGdiAnimatePalette (
159 HPALETTE hpal,
160 UINT StartIndex,
161 UINT Entries,
162 CONST PPALETTEENTRY ppe
163 );
164
165 /* Use NtGdiArcInternal with GdiTypeArc */
166 BOOL
167 STDCALL
168 NtGdiArc(HDC hDC,
169 int LeftRect,
170 int TopRect,
171 int RightRect,
172 int BottomRect,
173 int XStartArc,
174 int YStartArc,
175 int XEndArc,
176 int YEndArc);
177
178 /* Use NtGdiArcInternal with GdiTypeArcTo */
179 BOOL
180 STDCALL
181 NtGdiArcTo(HDC hDC,
182 int LeftRect,
183 int TopRect,
184 int RightRect,
185 int BottomRect,
186 int XRadial1,
187 int YRadial1,
188 int XRadial2,
189 int YRadial2);
190
191 /* Use NtGdiArcInternal with GdiTypeChord */
192 BOOL
193 STDCALL
194 NtGdiChord(HDC hDC,
195 int LeftRect,
196 int TopRect,
197 int RightRect,
198 int BottomRect,
199 int XRadial1,
200 int YRadial1,
201 int XRadial2,
202 int YRadial2);
203
204 /* Metafiles are user mode */
205 HENHMETAFILE
206 STDCALL
207 NtGdiCloseEnhMetaFile (
208 HDC hDC
209 );
210
211 /* Metafiles are user mode */
212 HMETAFILE
213 STDCALL
214 NtGdiCloseMetaFile (
215 HDC hDC
216 );
217
218 /* Does not exist */
219 BOOL
220 STDCALL
221 NtGdiColorMatchToTarget(HDC hDC,
222 HDC hDCTarget,
223 DWORD Action);
224
225 /* Metafiles are user mode */
226 HENHMETAFILE
227 STDCALL
228 NtGdiCopyEnhMetaFile (
229 HENHMETAFILE Src,
230 LPCWSTR File
231 );
232
233 /* Metafiles are user mode */
234 HMETAFILE
235 STDCALL
236 NtGdiCopyMetaFile (
237 HMETAFILE Src,
238 LPCWSTR File
239 );
240
241 /* Use NtGdiCreateBitmap and expand the pbm-> */
242 HBITMAP
243 STDCALL
244 NtGdiCreateBitmapIndirect (
245 CONST BITMAP * BM
246 );
247
248 /* Use NtGdiCreateDIBitmapInternal */
249 HBITMAP
250 STDCALL
251 NtGdiCreateDIBitmap (
252 HDC hDC,
253 CONST BITMAPINFOHEADER * bmih,
254 DWORD Init,
255 CONST VOID * bInit,
256 CONST BITMAPINFO * bmi,
257 UINT Usage
258 );
259
260 /* Use NtGdiCreateCompatibleBitmap */
261 HBITMAP
262 STDCALL
263 NtGdiCreateDiscardableBitmap (
264 HDC hDC,
265 INT Width,
266 INT Height
267 );
268
269 /* Use NtGdiCreateEllipticRgn and expand the lprect-> */
270 HRGN
271 STDCALL
272 NtGdiCreateEllipticRgnIndirect(CONST PRECT rc);
273
274 /* Metafiles are user mode */
275 HDC
276 STDCALL
277 NtGdiCreateEnhMetaFile (
278 HDC hDCRef,
279 LPCWSTR File,
280 CONST LPRECT Rect,
281 LPCWSTR Description
282 );
283
284 /* Use NtGdiCreateHatchBrushInternal with FALSE at the end. */
285 HBRUSH STDCALL
286 NtGdiCreateHatchBrush(
287 INT Style,
288 COLORREF Color);
289
290 /* Metafiles are user mode */
291 HDC
292 STDCALL
293 NtGdiCreateMetaFile (
294 LPCWSTR File
295 );
296
297 /* Use NtGdiCreatePaletteInternal with palNumEntries at the end. */
298 HPALETTE
299 STDCALL
300 NtGdiCreatePalette (
301 CONST PLOGPALETTE lgpl
302 );
303
304 /* Use NtGdiCreatePatternBrushInternal with false, false at the end. */
305 HBRUSH STDCALL
306 NtGdiCreatePatternBrush(
307 HBITMAP hBitmap);
308
309 /* Use NtGdiCreatePen with -> as parameters. */
310 HPEN STDCALL
311 NtGdiCreatePenIndirect(
312 CONST PLOGPEN LogBrush);
313
314 /* Use NtGdiPolyPolyDraw with PolyPolyRgn. */
315 HRGN
316 STDCALL
317 NtGdiCreatePolygonRgn(CONST PPOINT pt,
318 INT Count,
319 INT PolyFillMode);
320
321 /* Use NtGdiPolyPolyDraw with PolyPolyRgn. */
322 HRGN
323 STDCALL
324 NtGdiCreatePolyPolygonRgn(CONST PPOINT pt,
325 CONST PINT PolyCounts,
326 INT Count,
327 INT PolyFillMode);
328
329 /* Use NtGdiCreateRectRgn with expanded paraemters. */
330 HRGN
331 STDCALL
332 NtGdiCreateRectRgnIndirect(CONST PRECT rc);
333
334 /* Use NtGdiTransformPoints with GdiDpToLp. */
335 BOOL
336 STDCALL
337 NtGdiDPtoLP (
338 HDC hDC,
339 LPPOINT Points,
340 int Count
341 );
342
343 /* Meta are user-mode. */
344 BOOL
345 STDCALL
346 NtGdiDeleteEnhMetaFile (
347 HENHMETAFILE emf
348 );
349
350 /* Meta are user-mode. */
351 BOOL
352 STDCALL
353 NtGdiDeleteMetaFile (
354 HMETAFILE mf
355 );
356
357 /* Should be done in user-mode. */
358 BOOL STDCALL NtGdiDeleteObject(HGDIOBJ hObject);
359
360 /* Meta are user-mode. */
361 BOOL
362 STDCALL
363 NtGdiEnumEnhMetaFile (
364 HDC hDC,
365 HENHMETAFILE emf,
366 ENHMFENUMPROC EnhMetaFunc,
367 LPVOID Data,
368 CONST LPRECT Rect
369 );
370
371 /* Should be done in user-mode. */
372 int
373 STDCALL
374 NtGdiEnumFonts(HDC hDC,
375 LPCWSTR FaceName,
376 FONTENUMPROCW FontFunc,
377 LPARAM lParam);
378
379 /* Should be done in user-mode. */
380 INT
381 STDCALL
382 NtGdiEnumICMProfiles(HDC hDC,
383 LPWSTR lpstrBuffer,
384 UINT cch );
385
386 /* Meta are user-mode. */
387 BOOL
388 STDCALL
389 NtGdiEnumMetaFile (
390 HDC hDC,
391 HMETAFILE mf,
392 MFENUMPROC MetaFunc,
393 LPARAM lParam
394 );
395
396 /* Should be done in user-mode. */
397 INT
398 STDCALL
399 NtGdiEscape(HDC hDC,
400 INT Escape,
401 INT InSize,
402 LPCSTR InData,
403 LPVOID OutData);
404
405 /* Use NtGdiExtTextOutW with 0, 0 at the end. */
406 BOOL
407 STDCALL
408 NtGdiExtTextOut(HDC hdc,
409 int X,
410 int Y,
411 UINT fuOptions,
412 CONST RECT *lprc,
413 LPCWSTR lpString,
414 UINT cbCount,
415 CONST INT *lpDx);
416
417 /* Use NtGdiExtFloodFill with FLOODFILLBORDER. */
418 BOOL
419 STDCALL
420 NtGdiFloodFill (
421 HDC hDC,
422 INT XStart,
423 INT YStart,
424 COLORREF Fill
425 );
426
427 /* Should be done in user-mode. */
428 BOOL
429 STDCALL
430 NtGdiGdiComment (
431 HDC hDC,
432 UINT Size,
433 CONST LPBYTE Data
434 );
435
436 /* Should be done in user-mode. */
437 BOOL STDCALL NtGdiGdiFlush (VOID);
438
439 /* Should be done in user-mode. */
440 DWORD STDCALL NtGdiGdiGetBatchLimit (VOID);
441
442 /* Should be done in user-mode. */
443 DWORD STDCALL NtGdiGdiSetBatchLimit (DWORD Limit);
444
445 /* Use NtGdiGetDCDword with GdiGetArcDirection. */
446 INT
447 STDCALL
448 NtGdiGetArcDirection ( HDC hDC );
449
450 /* Should be done in user-mode. */
451 BOOL
452 STDCALL
453 NtGdiGetAspectRatioFilterEx(HDC hDC,
454 LPSIZE AspectRatio);
455
456 /* Should be done in user-mode using shared GDI Objects. */
457 BOOL
458 STDCALL
459 NtGdiGetBitmapDimensionEx (
460 HBITMAP hBitmap,
461 LPSIZE Dimension
462 );
463
464 /* Should be done in user-mode using shared GDI Objects. */
465 COLORREF STDCALL NtGdiGetBkColor(HDC hDC);
466
467 /* Should be done in user-mode using shared GDI Objects. */
468 INT STDCALL NtGdiGetBkMode(HDC hDC);
469
470 /* Should be done in user-mode using shared GDI Objects. */
471 BOOL STDCALL NtGdiGetBrushOrgEx(HDC hDC, LPPOINT brushOrg);
472
473 /* Use NtGdiGetCharABCWidthsW */
474 BOOL
475 STDCALL
476 NtGdiGetCharABCWidths(HDC hDC,
477 UINT FirstChar,
478 UINT LastChar,
479 LPABC abc);
480
481 /* Should be done in user mode. */
482 BOOL
483 STDCALL
484 NtGdiGetCharABCWidthsFloat(HDC hDC,
485 UINT FirstChar,
486 UINT LastChar,
487 LPABCFLOAT abcF);
488
489 /* Should be done in user mode. */
490 DWORD
491 STDCALL
492 NtGdiGetCharacterPlacement(HDC hDC,
493 LPCWSTR String,
494 int Count,
495 int MaxExtent,
496 LPGCP_RESULTSW Results,
497 DWORD Flags);
498
499 /* Should be done in user mode. */
500 BOOL
501 STDCALL
502 NtGdiGetCharWidthFloat(HDC hDC,
503 UINT FirstChar,
504 UINT LastChar,
505 PFLOAT Buffer);
506
507 /* Use NtGdiGetAppClipBox. */
508 int
509 STDCALL
510 NtGdiGetClipBox (
511 HDC hDC,
512 LPRECT rc
513 );
514
515 /* Use NtGdiGetColorSpaceforBitmap. */
516 HCOLORSPACE
517 STDCALL
518 NtGdiGetColorSpace(HDC hDC);
519
520 /* Should be done in user-mode and/or NtGdiGetDCObject. */
521 HGDIOBJ STDCALL NtGdiGetCurrentObject(HDC hDC, UINT ObjectType);
522
523 /* Should be done in user mode. */
524 BOOL STDCALL NtGdiGetCurrentPositionEx(HDC hDC, LPPOINT currentPosition);
525
526 /* Use NtGdiGetDCPoint with GdiGetDCOrg. */
527 BOOL STDCALL NtGdiGetDCOrgEx(HDC hDC, LPPOINT Point);
528
529 /* Use NtGdiDoPalette with GdiPalGetColorTable. */
530 UINT
531 STDCALL
532 NtGdiGetDIBColorTable (
533 HDC hDC,
534 UINT StartIndex,
535 UINT Entries,
536 RGBQUAD * Colors
537 );
538
539 /* Use NtGdiGetDIBitsInternal. */
540 INT
541 STDCALL
542 NtGdiGetDIBits (
543 HDC hDC,
544 HBITMAP hBitmap,
545 UINT StartScan,
546 UINT ScanLines,
547 LPVOID Bits,
548 LPBITMAPINFO bi,
549 UINT Usage
550 );
551
552
553 /* Meta are user-mode. */
554 HENHMETAFILE
555 STDCALL
556 NtGdiGetEnhMetaFile (
557 LPCWSTR MetaFile
558 );
559
560 /* Meta are user-mode. */
561 UINT
562 STDCALL
563 NtGdiGetEnhMetaFileBits (
564 HENHMETAFILE hemf,
565 UINT BufSize,
566 LPBYTE Buffer
567 );
568
569 /* Meta are user-mode. */
570 UINT
571 STDCALL
572 NtGdiGetEnhMetaFileDescription (
573 HENHMETAFILE hemf,
574 UINT BufSize,
575 LPWSTR Description
576 );
577
578 /* Meta are user-mode. */
579 UINT
580 STDCALL
581 NtGdiGetEnhMetaFileHeader (
582 HENHMETAFILE hemf,
583 UINT BufSize,
584 LPENHMETAHEADER emh
585 );
586
587 /* Meta are user-mode. */
588 UINT
589 STDCALL
590 NtGdiGetEnhMetaFilePaletteEntries (
591 HENHMETAFILE hemf,
592 UINT Entries,
593 LPPALETTEENTRY pe
594 );
595
596 /* Meta are user-mode. */
597 UINT
598 STDCALL
599 NtGdiGetEnhMetaFilePixelFormat(HENHMETAFILE hEMF,
600 DWORD BufSize,
601 CONST PPIXELFORMATDESCRIPTOR pfd);
602
603 /* Should be done in user-mode. */
604 DWORD
605 STDCALL
606 NtGdiGetFontLanguageInfo(HDC hDC);
607
608 /* Should be done in user-mode. */
609 int
610 STDCALL
611 NtGdiGetGraphicsMode ( HDC hDC );
612
613 /* Should be done in user-mode. */
614 BOOL
615 STDCALL
616 NtGdiGetICMProfile(HDC hDC,
617 LPDWORD NameSize,
618 LPWSTR Filename);
619
620 /* Should be done in user-mode. */
621 BOOL
622 STDCALL
623 NtGdiGetLogColorSpace(HCOLORSPACE hColorSpace,
624 LPLOGCOLORSPACEW Buffer,
625 DWORD Size);
626
627 /* Should be done in user-mode using shared GDI Objects. */
628 INT STDCALL NtGdiGetMapMode(HDC hDC);
629
630 /* Meta files are user-mode. */
631 HMETAFILE
632 STDCALL
633 NtGdiGetMetaFile (
634 LPCWSTR MetaFile
635 );
636
637 /* Meta files are user-mode. */
638 UINT
639 STDCALL
640 NtGdiGetMetaFileBitsEx (
641 HMETAFILE hmf,
642 UINT Size,
643 LPVOID Data
644 );
645
646 /* Meta files are user-mode. */
647 int
648 STDCALL
649 NtGdiGetMetaRgn (
650 HDC hDC,
651 HRGN hrgn
652 );
653
654 /* Should be done in user-mode using shared GDI Objects. */
655 INT STDCALL NtGdiGetObject(HGDIOBJ hGDIObj,
656 INT BufSize,
657 LPVOID Object);
658
659 /* Should be done in user-mode using shared GDI Objects. */
660 DWORD STDCALL NtGdiGetObjectType(HGDIOBJ hGDIObj);
661
662 /* Use NtGdiGetOutlineTextMetricsInternalW. */
663 UINT
664 STDCALL
665 NtGdiGetOutlineTextMetrics(HDC hDC,
666 UINT Data,
667 LPOUTLINETEXTMETRICW otm);
668
669 /* Use NtGdiDoPalette with GdiPalGetEntries. */
670 UINT
671 STDCALL
672 NtGdiGetPaletteEntries (
673 HPALETTE hpal,
674 UINT StartIndex,
675 UINT Entries,
676 LPPALETTEENTRY pe
677 );
678
679 /* Should be done in user-mode using shared GDI Objects. */
680 INT
681 STDCALL
682 NtGdiGetPixelFormat(HDC hDC);
683
684 /* Should be done in user-mode using shared GDI Objects. */
685 INT STDCALL NtGdiGetPolyFillMode(HDC hDC);
686
687 /* Should be done in user-mode using shared GDI Objects. */
688 INT STDCALL NtGdiGetROP2(HDC hDC);
689
690 /* Should be done in user-mode using shared GDI Objects. */
691 INT STDCALL NtGdiGetRelAbs(HDC hDC);
692
693 /* Should be done in user-mode using shared GDI Objects. */
694 INT STDCALL NtGdiGetStretchBltMode(HDC hDC);
695
696 /* Use NtGdiDoPalette with GdiPalSetSystemEntries. */
697 UINT
698 STDCALL
699 NtGdiGetSystemPaletteEntries (
700 HDC hDC,
701 UINT StartIndex,
702 UINT Entries,
703 LPPALETTEENTRY pe
704 );
705
706 /* Should be done in user-mode using shared GDI Objects. */
707 UINT STDCALL NtGdiGetTextAlign(HDC hDC);
708
709 /* Should be done in user-mode using shared GDI Objects. */
710 UINT
711 STDCALL
712 NtGdiGetTextCharset(HDC hDC);
713
714 /* Needs to be done in user-mode, using shared GDI Object Attributes. */
715 COLORREF STDCALL NtGdiGetTextColor(HDC hDC);
716
717 /* Rename to NtGdiGetTextExtentExW. Add 0 at the end. */
718 BOOL
719 STDCALL
720 NtGdiGetTextExtentExPoint(HDC hDC,
721 LPCWSTR String,
722 int Count,
723 int MaxExtent,
724 LPINT Fit,
725 LPINT Dx,
726 LPSIZE Size);
727
728 /* Rename to NtGdiGetTextExtent. Add 0 at the end. */
729 BOOL
730 STDCALL
731 NtGdiGetTextExtentPoint(HDC hDC,
732 LPCWSTR String,
733 int Count,
734 LPSIZE Size);
735
736 /* Rename to NtGdiGetTextFaceW, add FALSE at the end. */
737 int
738 STDCALL
739 NtGdiGetTextFace(HDC hDC,
740 int Count,
741 LPWSTR FaceName);
742
743 /* Use NtGdiGetTextMetricsW with 0 at the end */
744 BOOL
745 STDCALL
746 NtGdiGetTextMetrics(HDC hDC,
747 LPTEXTMETRICW tm);
748
749 /* Use NtGdiGetDCPoint with GdiGetViewPortExt */
750 BOOL STDCALL NtGdiGetViewportExtEx(HDC hDC, LPSIZE viewportExt);
751
752 /* Needs to be done in user-mode. */
753 BOOL STDCALL NtGdiGetViewportOrgEx(HDC hDC, LPPOINT viewportOrg);
754
755 /* Metafiles are user-mode. */
756 UINT
757 STDCALL
758 NtGdiGetWinMetaFileBits (
759 HENHMETAFILE hemf,
760 UINT BufSize,
761 LPBYTE Buffer,
762 INT MapMode,
763 HDC Ref
764 );
765
766 /* Needs to be done in user-mode. */
767 BOOL STDCALL NtGdiGetWindowExtEx(HDC hDC, LPSIZE windowExt);
768
769 /* Needs to be done in user-mode. */
770 BOOL STDCALL NtGdiGetWindowOrgEx(HDC hDC, LPPOINT windowOrg);
771
772 /* Use NtGdiGetTransform with GdiWorldSpaceToPageSpace */
773 BOOL
774 STDCALL
775 NtGdiGetWorldTransform (
776 HDC hDC,
777 LPXFORM Xform
778 );
779
780 /* Use NtGdiTransformPoints with GdiDpToLp */
781 BOOL
782 STDCALL
783 NtGdiLPtoDP (
784 HDC hDC,
785 LPPOINT Points,
786 int Count
787 );
788
789 /* Needs to be done in user-mode. */
790 BOOL
791 STDCALL
792 NtGdiMoveToEx(HDC hDC,
793 int X,
794 int Y,
795 LPPOINT Point);
796
797 /* Needs to be done in user-mode. */
798 BOOL
799 STDCALL
800 NtGdiOffsetViewportOrgEx (
801 HDC hDC,
802 int XOffset,
803 int YOffset,
804 LPPOINT Point
805 );
806
807 /* Needs to be done in user-mode. */
808 BOOL
809 STDCALL
810 NtGdiOffsetWindowOrgEx (
811 HDC hDC,
812 int XOffset,
813 int YOffset,
814 LPPOINT Point
815 );
816
817 /* Use NtGdiFillRgn. Add 0 at the end. */
818 BOOL
819 STDCALL
820 NtGdiPaintRgn(HDC hDC,
821 HRGN hRgn);
822
823 /* Use NtGdiArcInternal with GdiTypePie. */
824 BOOL
825 STDCALL
826 NtGdiPie(HDC hDC,
827 int LeftRect,
828 int TopRect,
829 int RightRect,
830 int BottomRect,
831 int XRadial1,
832 int YRadial1,
833 int XRadial2,
834 int YRadial2);
835
836 /* Metafiles are user-mode. */
837 BOOL
838 STDCALL
839 NtGdiPlayEnhMetaFile (
840 HDC hDC,
841 HENHMETAFILE hemf,
842 CONST PRECT Rect
843 );
844
845 /* Metafiles are user-mode. */
846 BOOL
847 STDCALL
848 NtGdiPlayEnhMetaFileRecord (
849 HDC hDC,
850 LPHANDLETABLE Handletable,
851 CONST ENHMETARECORD * EnhMetaRecord,
852 UINT Handles
853 );
854
855 /* Metafiles are user-mode. */
856 BOOL
857 STDCALL
858 NtGdiPlayMetaFile (
859 HDC hDC,
860 HMETAFILE hmf
861 );
862
863 /* Metafiles are user-mode. */
864 BOOL
865 STDCALL
866 NtGdiPlayMetaFileRecord (
867 HDC hDC,
868 LPHANDLETABLE Handletable,
869 LPMETARECORD MetaRecord,
870 UINT Handles
871 );
872
873 /* Use NtGdiPolyPolyDraw with GdiPolyBezier. */
874 BOOL
875 STDCALL
876 NtGdiPolyBezier(HDC hDC,
877 CONST LPPOINT pt,
878 DWORD Count);
879
880 /* Use NtGdiPolyPolyDraw with GdiPolyBezierTo. */
881 BOOL
882 STDCALL
883 NtGdiPolyBezierTo(HDC hDC,
884 CONST LPPOINT pt,
885 DWORD Count);
886
887 /* Use NtGdiPolyPolyDraw with GdiPolyPolyLine. */
888 BOOL
889 STDCALL
890 NtGdiPolyline(HDC hDC,
891 CONST LPPOINT pt,
892 int Count);
893
894 /* Use NtGdiPolyPolyDraw with GdiPolyLineTo. */
895 BOOL
896 STDCALL
897 NtGdiPolylineTo(HDC hDC,
898 CONST LPPOINT pt,
899 DWORD Count);
900
901 /* Use NtGdiPolyPolyDraw with GdiPolyPolyLine. */
902 BOOL
903 STDCALL
904 NtGdiPolyPolyline(HDC hDC,
905 CONST LPPOINT pt,
906 CONST LPDWORD PolyPoints,
907 DWORD Count);
908
909 /* Use NtGdiPolyTextOutW with 0 at the end. */
910 BOOL
911 STDCALL
912 NtGdiPolyTextOut(HDC hDC,
913 CONST LPPOLYTEXTW txt,
914 int Count);
915
916 /* Use NtGdiPolyPolyDraw with GdiPolyPolygon. */
917 BOOL
918 STDCALL
919 NtGdiPolygon(HDC hDC,
920 CONST PPOINT Points,
921 int Count);
922
923 /* Use NtGdiPolyPolyDraw with GdiPolyPolygon. */
924 BOOL
925 STDCALL
926 NtGdiPolyPolygon(HDC hDC,
927 CONST LPPOINT Points,
928 CONST LPINT PolyCounts,
929 int Count);
930
931 /* Call UserRealizePalette. */
932 UINT
933 STDCALL
934 NtGdiRealizePalette (
935 HDC hDC
936 );
937
938 /* Should be done in user-mode. */
939 BOOL
940 STDCALL
941 NtGdiRemoveFontResource(LPCWSTR FileName);
942
943 /* Use NtGdiExtSelectClipRgn with RGN_COPY. */
944 int
945 STDCALL
946 NtGdiSelectClipRgn (
947 HDC hDC,
948 HRGN hrgn
949 );
950
951 /* Should be done in user-mode. */
952 HGDIOBJ STDCALL NtGdiSelectObject(HDC hDC, HGDIOBJ hGDIObj);
953
954 /* Use NtUserSelectPalette. */
955 HPALETTE
956 STDCALL
957 NtGdiSelectPalette (
958 HDC hDC,
959 HPALETTE hpal,
960 BOOL ForceBackground
961 );
962
963 /* Should be done in user-mode. */
964 INT
965 STDCALL
966 NtGdiSetAbortProc(HDC hDC,
967 ABORTPROC AbortProc);
968
969 /* Use NtGdiGetAndSetDCDword with GdiGetSetArcDirection. */
970 int
971 STDCALL
972 NtGdiSetArcDirection(HDC hDC,
973 int ArcDirection);
974
975 /* Use NtGdiSetBitmapDimension. */
976 BOOL
977 STDCALL
978 NtGdiSetBitmapDimensionEx (
979 HBITMAP hBitmap,
980 INT Width,
981 INT Height,
982 LPSIZE Size
983 );
984
985 /* Needs to be done in user-mode, using shared GDI Object Attributes. */
986 COLORREF STDCALL NtGdiSetBkColor (HDC hDC, COLORREF Color);
987
988 /* Needs to be done in user-mode, using shared GDI Object Attributes. */
989 INT STDCALL NtGdiSetBkMode(HDC hDC, INT backgroundMode);
990
991 /* Use NtGdiSetBrushOrg. */
992 BOOL STDCALL
993 NtGdiSetBrushOrgEx(
994 HDC hDC,
995 INT XOrg,
996 INT YOrg,
997 LPPOINT Point);
998
999 /* Use NtGdiDoPalette with GdiPalSetColorTable, TRUE. */
1000 UINT
1001 STDCALL
1002 NtGdiSetDIBColorTable (
1003 HDC hDC,
1004 UINT StartIndex,
1005 UINT Entries,
1006 CONST RGBQUAD * Colors
1007 );
1008
1009 /* Use SetDIBitsToDevice in gdi32. */
1010 INT
1011 STDCALL
1012 NtGdiSetDIBits (
1013 HDC hDC,
1014 HBITMAP hBitmap,
1015 UINT StartScan,
1016 UINT ScanLines,
1017 CONST VOID * Bits,
1018 CONST BITMAPINFO * bmi,
1019 UINT ColorUse
1020 );
1021
1022 /* Use NtGdiSetDIBitsToDeviceInternal. */
1023 INT
1024 STDCALL
1025 NtGdiSetDIBitsToDevice (
1026 HDC hDC,
1027 INT XDest,
1028 INT YDest,
1029 DWORD Width,
1030 DWORD Height,
1031 INT XSrc,
1032 INT YSrc,
1033 UINT StartScan,
1034 UINT ScanLines,
1035 CONST VOID * Bits,
1036 CONST BITMAPINFO * bmi,
1037 UINT ColorUse
1038 );
1039
1040 /* Metafiles are user-mode. */
1041 HENHMETAFILE
1042 STDCALL
1043 NtGdiSetEnhMetaFileBits (
1044 UINT BufSize,
1045 CONST PBYTE Data
1046 );
1047
1048 /* Needs to be done in user-mode, using shared GDI Object Attributes. */
1049 int
1050 STDCALL
1051 NtGdiSetGraphicsMode (
1052 HDC hDC,
1053 int Mode
1054 );
1055
1056 /* Use NtGdiSetIcmMode. */
1057 INT
1058 STDCALL
1059 NtGdiSetICMMode(HDC hDC,
1060 INT EnableICM);
1061
1062 /* Should be done in user-mode. */
1063 BOOL
1064 STDCALL
1065 NtGdiSetICMProfile(HDC hDC,
1066 LPWSTR Filename);
1067
1068 /* Needs to be done in user-mode, using shared GDI Object Attributes. */
1069 int
1070 STDCALL
1071 NtGdiSetMapMode (
1072 HDC hDC,
1073 int MapMode
1074 );
1075
1076 /* Needs to be done in user-mode, using shared GDI Object Attributes. */
1077 DWORD
1078 STDCALL
1079 NtGdiSetMapperFlags(HDC hDC,
1080 DWORD Flag);
1081
1082 /* Metafiles are user-mode. */
1083 HMETAFILE
1084 STDCALL
1085 NtGdiSetMetaFileBitsEx (
1086 UINT Size,
1087 CONST PBYTE Data
1088 );
1089
1090 /* Use NtGdiDoPalette with GdiPalSetEntries, TRUE. */
1091 UINT
1092 STDCALL
1093 NtGdiSetPaletteEntries (
1094 HPALETTE hpal,
1095 UINT Start,
1096 UINT Entries,
1097 CONST LPPALETTEENTRY pe
1098 );
1099
1100 /* Use NtGdiSetPixel(hdc, x, y, color) != CLR_INVALID; */
1101 BOOL
1102 STDCALL
1103 NtGdiSetPixelV (
1104 HDC hDC,
1105 INT X,
1106 INT Y,
1107 COLORREF Color
1108 );
1109
1110 /* Needs to be done in user-mode, using shared GDI Object Attributes. */
1111 INT STDCALL NtGdiSetPolyFillMode(HDC hDC, INT polyFillMode);
1112
1113 /* Needs to be done in user-mode, using shared GDI Object Attributes. */
1114 INT STDCALL NtGdiSetROP2(HDC hDC, INT ROPmode);
1115
1116 /* Needs to be done in user-mode, using shared GDI Object Attributes. */
1117 INT STDCALL NtGdiSetStretchBltMode(HDC hDC, INT stretchBltMode);
1118
1119 /* Needs to be done in user-mode, using shared GDI Object Attributes. */
1120 UINT
1121 STDCALL
1122 NtGdiSetTextAlign(HDC hDC,
1123 UINT Mode);
1124
1125 /* Needs to be done in user-mode, using shared GDI Object Attributes. */
1126 COLORREF STDCALL NtGdiSetTextColor(HDC hDC, COLORREF color);
1127
1128 /* Needs to be done in user-mode. */
1129 BOOL
1130 STDCALL
1131 NtGdiSetWindowExtEx (
1132 HDC hDC,
1133 int XExtent,
1134 int YExtent,
1135 LPSIZE Size
1136 );
1137
1138 /* Needs to be done in user-mode. */
1139 BOOL
1140 STDCALL
1141 NtGdiSetViewportOrgEx (
1142 HDC hDC,
1143 int X,
1144 int Y,
1145 LPPOINT Point
1146 );
1147
1148 /* Needs to be done in user-mode. */
1149 BOOL
1150 STDCALL
1151 NtGdiSetViewportExtEx (
1152 HDC hDC,
1153 int XExtent,
1154 int YExtent,
1155 LPSIZE Size
1156 );
1157
1158 /* Needs to be done in user-mode. */
1159 BOOL
1160 STDCALL
1161 NtGdiSetWindowOrgEx (
1162 HDC hDC,
1163 int X,
1164 int Y,
1165 LPPOINT Point
1166 );
1167
1168 /* Use NtGdiModifyWorldTransform with MWT_MAX + 1; */
1169 BOOL
1170 STDCALL
1171 NtGdiSetWorldTransform (
1172 HDC hDC,
1173 CONST LPXFORM Xform
1174 );
1175
1176 /* Use NtGdiStretchDIBitsInternal. */
1177 INT
1178 STDCALL
1179 NtGdiStretchDIBits (
1180 HDC hDC,
1181 INT XDest,
1182 INT YDest,
1183 INT DestWidth,
1184 INT DestHeight,
1185 INT XSrc,
1186 INT YSrc,
1187 INT SrcWidth,
1188 INT SrcHeight,
1189 CONST VOID * Bits,
1190 CONST BITMAPINFO * BitsInfo,
1191 UINT Usage,
1192 DWORD ROP
1193 );
1194
1195 /* Use NtGdiExtTextOutW with 0, 0 at the end. */
1196 BOOL
1197 STDCALL
1198 NtGdiTextOut(HDC hDC,
1199 int XStart,
1200 int YStart,
1201 LPCWSTR String,
1202 int Count);
1203
1204 /* Needs to be done in user-mode. */
1205 BOOL
1206 STDCALL
1207 NtGdiUpdateICMRegKey(DWORD Reserved,
1208 LPWSTR CMID,
1209 LPWSTR Filename,
1210 UINT Command);
1211
1212 /* These shouldn't even be called NtGdi */
1213 HDC STDCALL NtGdiGetDCState(HDC hDC);
1214 WORD STDCALL NtGdiSetHookFlags(HDC hDC, WORD Flags);
1215 INT
1216 STDCALL
1217 NtGdiSelectVisRgn(HDC hdc,
1218 HRGN hrgn);
1219 VOID STDCALL NtGdiSetDCState ( HDC hDC, HDC hDCSave );
1220
1221 /* All this Should be in user-mode, not NtUser calls. Especially not in GDI! */
1222 DWORD
1223 NTAPI
1224 NtUserCallTwoParam(
1225 DWORD Param1,
1226 DWORD Param2,
1227 DWORD Routine);
1228
1229 #define TWOPARAM_ROUTINE_SETDCPENCOLOR 0x45
1230 #define TWOPARAM_ROUTINE_SETDCBRUSHCOLOR 0x46
1231 #define TWOPARAM_ROUTINE_GETDCCOLOR 0x47
1232
1233 #define NtUserGetDCBrushColor(hbr) \
1234 (COLORREF)NtUserCallTwoParam((DWORD)(hbr), OBJ_BRUSH, TWOPARAM_ROUTINE_GETDCCOLOR)
1235
1236 #define NtUserGetDCPenColor(hbr) \
1237 (COLORREF)NtUserCallTwoParam((DWORD)(hbr), OBJ_PEN, TWOPARAM_ROUTINE_GETDCCOLOR)
1238
1239 #define NtUserSetDCBrushColor(hbr, crColor) \
1240 (COLORREF)NtUserCallTwoParam((DWORD)(hbr), (DWORD)crColor, TWOPARAM_ROUTINE_SETDCBRUSHCOLOR)
1241
1242 #define NtUserSetDCPenColor(hbr, crColor) \
1243 (COLORREF)NtUserCallTwoParam((DWORD)(hbr), (DWORD)crColor, TWOPARAM_ROUTINE_SETDCPENCOLOR)
1244
1245 #endif /* WIN32K_NTGDI_BAD_INCLUDED */