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