You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
69 lines
2.1 KiB
69 lines
2.1 KiB
using System;
|
|
using System.Runtime.InteropServices;
|
|
|
|
namespace Apewer.Internals.Interop
|
|
{
|
|
|
|
[System.Security.SecuritySafeCritical]
|
|
internal class Gdi32
|
|
{
|
|
|
|
/// <summary>
|
|
///
|
|
/// </summary>
|
|
/// <param name="hdc"></param>
|
|
/// <returns></returns>
|
|
[DllImport("gdi32.dll", ExactSpelling = true, SetLastError = true)]
|
|
public static extern IntPtr CreateCompatibleDC(IntPtr hdc);
|
|
|
|
/// <summary>
|
|
///
|
|
/// </summary>
|
|
/// <param name="x1"></param>
|
|
/// <param name="y1"></param>
|
|
/// <param name="x2"></param>
|
|
/// <param name="y2"></param>
|
|
/// <param name="x3"></param>
|
|
/// <param name="y3"></param>
|
|
/// <returns></returns>
|
|
[DllImport("gdi32.dll")]
|
|
public static extern int CreateRoundRectRgn(int x1, int y1, int x2, int y2, int x3, int y3);
|
|
|
|
/// <summary>
|
|
///
|
|
/// </summary>
|
|
/// <param name="hdc"></param>
|
|
/// <returns></returns>
|
|
[DllImport("gdi32.dll", ExactSpelling = true, SetLastError = true)]
|
|
public static extern int DeleteDC(IntPtr hdc);
|
|
|
|
/// <summary>
|
|
///
|
|
/// </summary>
|
|
/// <param name="hobj"></param>
|
|
/// <returns></returns>
|
|
[DllImport("gdi32.dll", ExactSpelling = true, SetLastError = true)]
|
|
public static extern int DeleteObject(IntPtr hobj);
|
|
|
|
/// <summary>
|
|
///
|
|
/// </summary>
|
|
/// <param name="lpxform"></param>
|
|
/// <param name="ncount"></param>
|
|
/// <param name="rgndata"></param>
|
|
/// <returns></returns>
|
|
[DllImport("gdi32.dll", ExactSpelling = true, SetLastError = true)]
|
|
public static extern IntPtr ExtCreateRegion(IntPtr lpxform, uint ncount, IntPtr rgndata);
|
|
|
|
/// <summary>
|
|
///
|
|
/// </summary>
|
|
/// <param name="hdc"></param>
|
|
/// <param name="hobj"></param>
|
|
/// <returns></returns>
|
|
[DllImport("gdi32.dll", ExactSpelling = true)]
|
|
public static extern IntPtr SelectObject(IntPtr hdc, IntPtr hobj);
|
|
|
|
}
|
|
|
|
}
|
|
|