93 references to NativeMethods
System.Drawing (93)
commonui\System\Drawing\Advanced\Font.cs (10)
410
IntPtr screenDC = UnsafeNativeMethods.GetDC(
NativeMethods
.NullHandleRef);
415
UnsafeNativeMethods.ReleaseDC(
NativeMethods
.NullHandleRef, new HandleRef(null, screenDC));
429
IntPtr screenDC = UnsafeNativeMethods.GetDC(
NativeMethods
.NullHandleRef);
435
UnsafeNativeMethods.ReleaseDC(
NativeMethods
.NullHandleRef, new HandleRef(null, screenDC));
803
IntPtr screenDC = UnsafeNativeMethods.GetDC(
NativeMethods
.NullHandleRef);
815
UnsafeNativeMethods.ReleaseDC(
NativeMethods
.NullHandleRef, new HandleRef(null, screenDC));
932
IntPtr screenDC = UnsafeNativeMethods.GetDC(
NativeMethods
.NullHandleRef);
940
UnsafeNativeMethods.ReleaseDC(
NativeMethods
.NullHandleRef, new HandleRef(null, screenDC));
1001
IntPtr screenDC = UnsafeNativeMethods.GetDC(
NativeMethods
.NullHandleRef);
1013
UnsafeNativeMethods.ReleaseDC(
NativeMethods
.NullHandleRef, new HandleRef(null, screenDC));
commonui\System\Drawing\Advanced\Gdiplus.cs (3)
3966
public static extern int GetDIBits(HandleRef hdc, HandleRef hbm, int arg1, int arg2, IntPtr arg3, ref
NativeMethods
.BITMAPINFO_FLAT bmi, int arg5);
3982
public static extern IntPtr IntCreateDIBSection(HandleRef hdc, ref
NativeMethods
.BITMAPINFO_FLAT bmi, int iUsage, ref IntPtr ppvBits, IntPtr hSection, int dwOffset);
3983
public static IntPtr CreateDIBSection(HandleRef hdc, ref
NativeMethods
.BITMAPINFO_FLAT bmi, int iUsage, ref IntPtr ppvBits, IntPtr hSection, int dwOffset) {
commonui\System\Drawing\Advanced\ImageAttributes.cs (1)
665
NativeMethods
.NullHandleRef);
commonui\System\Drawing\Advanced\Metafile.cs (6)
174
NativeMethods
.NullHandleRef,
305
NativeMethods
.NullHandleRef,
365
NativeMethods
.NullHandleRef,
527
NativeMethods
.NullHandleRef,
589
NativeMethods
.NullHandleRef,
727
NativeMethods
.NullHandleRef,
commonui\System\Drawing\Bitmap.cs (1)
264
int status = SafeNativeMethods.Gdip.GdipCreateBitmapFromScan0(width, height, 0, unchecked((int) format),
NativeMethods
.NullHandleRef, out bitmap);
commonui\System\Drawing\BufferedGraphicsContext.cs (20)
244
private bool bFillBitmapInfo(IntPtr hdc, IntPtr hpal, ref
NativeMethods
.BITMAPINFO_FLAT pbmi) {
259
pbmi.bmiHeader_biSize = Marshal.SizeOf(typeof(
NativeMethods
.BITMAPINFOHEADER));
260
pbmi.bmiColors = new byte[
NativeMethods
.BITMAPINFO_MAX_COLORSIZE*4];
271
NativeMethods
.DIB_RGB_COLORS);
277
if ( pbmi.bmiHeader_biCompression ==
NativeMethods
.BI_BITFIELDS ) {
289
NativeMethods
.DIB_RGB_COLORS);
323
private unsafe bool bFillColorTable(IntPtr hdc, IntPtr hpal, ref
NativeMethods
.BITMAPINFO_FLAT pbmi) {
325
byte[] aj = new byte[sizeof(
NativeMethods
.PALETTEENTRY) * 256];
330
NativeMethods
.RGBQUAD* prgb = (
NativeMethods
.RGBQUAD*)pcolors;
331
NativeMethods
.PALETTEENTRY* lppe = (
NativeMethods
.PALETTEENTRY*)ppal;
445
NativeMethods
.BITMAPINFO_FLAT pbmi = new
NativeMethods
.BITMAPINFO_FLAT();
453
case
NativeMethods
.OBJ_DC:
454
case
NativeMethods
.OBJ_METADC:
455
case
NativeMethods
.OBJ_MEMDC:
456
case
NativeMethods
.OBJ_ENHMETADC:
470
if (pbmi.bmiHeader_biCompression ==
NativeMethods
.BI_RGB) {
489
hbmRet = SafeNativeMethods.CreateDIBSection(new HandleRef(null, hdc), ref pbmi,
NativeMethods
.DIB_RGB_COLORS, ref ppvBits, IntPtr.Zero, 0);
commonui\System\Drawing\Graphics.cs (7)
3063
NativeMethods
.NullHandleRef,
3065
NativeMethods
.NullHandleRef
3097
NativeMethods
.NullHandleRef,
3099
NativeMethods
.NullHandleRef);
3135
NativeMethods
.NullHandleRef,
3137
NativeMethods
.NullHandleRef);
4623
(((UnsafeNativeMethods.GetSystemMetrics(
NativeMethods
.SM_REMOTESESSION) & 0x00000001) != 0) && (error == 0))) {
commonui\System\Drawing\Icon.cs (5)
278
StringBuilder sb = new StringBuilder(
NativeMethods
.MAX_PATH);
281
IntPtr hIcon = SafeNativeMethods.ExtractAssociatedIcon(
NativeMethods
.NullHandleRef, sb, ref index);
483
NativeMethods
.NullHandleRef,
628
IntPtr dc = UnsafeNativeMethods.GetDC(
NativeMethods
.NullHandleRef);
631
UnsafeNativeMethods.ReleaseDC(
NativeMethods
.NullHandleRef, new HandleRef(null, dc));
commonui\System\Drawing\Printing\PageSettings.cs (2)
419
int retCode = SafeNativeMethods.DocumentProperties(
NativeMethods
.NullHandleRef,
NativeMethods
.NullHandleRef, printerSettings.PrinterName, modePointer, modePointer, SafeNativeMethods.DM_IN_BUFFER | SafeNativeMethods.DM_OUT_BUFFER);
commonui\System\Drawing\Printing\PrinterSettings.cs (8)
1006
int modeSize = SafeNativeMethods.DocumentProperties(
NativeMethods
.NullHandleRef,
NativeMethods
.NullHandleRef, printer, IntPtr.Zero,
NativeMethods
.NullHandleRef, 0);
1018
int returnCode = SafeNativeMethods.DocumentProperties(
NativeMethods
.NullHandleRef,
NativeMethods
.NullHandleRef, printer, pointer,
NativeMethods
.NullHandleRef, SafeNativeMethods.DM_OUT_BUFFER);
1053
int retCode = SafeNativeMethods.DocumentProperties(
NativeMethods
.NullHandleRef,
NativeMethods
.NullHandleRef, printer, pointer, pointer, SafeNativeMethods.DM_IN_BUFFER | SafeNativeMethods.DM_OUT_BUFFER);
commonui\System\Drawing\SystemFonts.cs (17)
38
NativeMethods
.NONCLIENTMETRICS data = new
NativeMethods
.NONCLIENTMETRICS();
39
bool result = UnsafeNativeMethods.SystemParametersInfo(
NativeMethods
.SPI_GETNONCLIENTMETRICS, data.cbSize, data, 0);
80
NativeMethods
.NONCLIENTMETRICS data = new
NativeMethods
.NONCLIENTMETRICS();
81
bool result = UnsafeNativeMethods.SystemParametersInfo(
NativeMethods
.SPI_GETNONCLIENTMETRICS, data.cbSize, data, 0);
121
NativeMethods
.NONCLIENTMETRICS data = new
NativeMethods
.NONCLIENTMETRICS();
122
bool result = UnsafeNativeMethods.SystemParametersInfo(
NativeMethods
.SPI_GETNONCLIENTMETRICS, data.cbSize, data, 0);
162
NativeMethods
.NONCLIENTMETRICS data = new
NativeMethods
.NONCLIENTMETRICS();
163
bool result = UnsafeNativeMethods.SystemParametersInfo(
NativeMethods
.SPI_GETNONCLIENTMETRICS, data.cbSize, data, 0);
203
NativeMethods
.NONCLIENTMETRICS data = new
NativeMethods
.NONCLIENTMETRICS();
204
bool result = UnsafeNativeMethods.SystemParametersInfo(
NativeMethods
.SPI_GETNONCLIENTMETRICS, data.cbSize, data, 0);
259
bool result = UnsafeNativeMethods.SystemParametersInfo(
NativeMethods
.SPI_GETICONTITLELOGFONT, Marshal.SizeOf(itfont), itfont, 0);
355
IntPtr handle = UnsafeNativeMethods.GetStockObject(
NativeMethods
.DEFAULT_GUI_FONT);
commonui\System\Drawing\SystemIcons.cs (10)
46
_application = new Icon( SafeNativeMethods.LoadIcon(
NativeMethods
.NullHandleRef, SafeNativeMethods.IDI_APPLICATION ));
60
_asterisk = new Icon( SafeNativeMethods.LoadIcon(
NativeMethods
.NullHandleRef, SafeNativeMethods.IDI_ASTERISK ));
74
_error = new Icon( SafeNativeMethods.LoadIcon(
NativeMethods
.NullHandleRef, SafeNativeMethods.IDI_ERROR ));
88
_exclamation = new Icon( SafeNativeMethods.LoadIcon(
NativeMethods
.NullHandleRef, SafeNativeMethods.IDI_EXCLAMATION ));
102
_hand = new Icon( SafeNativeMethods.LoadIcon(
NativeMethods
.NullHandleRef, SafeNativeMethods.IDI_HAND ));
116
_information = new Icon( SafeNativeMethods.LoadIcon(
NativeMethods
.NullHandleRef, SafeNativeMethods.IDI_INFORMATION ));
130
_question = new Icon( SafeNativeMethods.LoadIcon(
NativeMethods
.NullHandleRef, SafeNativeMethods.IDI_QUESTION ));
144
_warning = new Icon( SafeNativeMethods.LoadIcon(
NativeMethods
.NullHandleRef, SafeNativeMethods.IDI_WARNING ));
158
_winlogo = new Icon( SafeNativeMethods.LoadIcon(
NativeMethods
.NullHandleRef, SafeNativeMethods.IDI_WINLOGO ));
178
int result = SafeNativeMethods.LoadIconWithScaleDown(
NativeMethods
.NullHandleRef, SafeNativeMethods.IDI_SHIELD, 32, 32, ref hIcon );
commonui\System\Drawing\UnsafeNativeMethods.cs (1)
115
public static extern bool SystemParametersInfo(int uiAction, int uiParam, [In, Out]
NativeMethods
.NONCLIENTMETRICS pvParam, int fWinIni);
misc\DpiHelper.cs (2)
108
IntPtr hDC = UnsafeNativeMethods.GetDC(
NativeMethods
.NullHandleRef);
113
UnsafeNativeMethods.ReleaseDC(
NativeMethods
.NullHandleRef, new HandleRef(null, hDC));