GRADIENT_RECT.cs 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. using System.Runtime.InteropServices;
  2. namespace Microsoft.Win32
  3. {
  4. /// <summary>
  5. /// GRADIENT_RECT定义
  6. /// </summary>
  7. public static partial class NativeMethods
  8. {
  9. /// <summary>
  10. /// The GRADIENT_RECT structure specifies the index of two vertices in the pVertex array in the GradientFill function. These two vertices form the upper-left and lower-right boundaries of a rectangle.
  11. /// </summary>
  12. [StructLayout(LayoutKind.Sequential)]
  13. public struct GRADIENT_RECT
  14. {
  15. /// <summary>
  16. /// The upper-left corner of a rectangle.
  17. /// </summary>
  18. public uint UpperLeft;
  19. /// <summary>
  20. /// The lower-right corner of a rectangle.
  21. /// </summary>
  22. public uint LowerRight;
  23. /// <summary>
  24. /// 构造函数
  25. /// </summary>
  26. /// <param name="upperLeft">左上角</param>
  27. /// <param name="lowerRight">右上角</param>
  28. public GRADIENT_RECT(uint upperLeft, uint lowerRight)
  29. {
  30. this.UpperLeft = upperLeft;
  31. this.LowerRight = lowerRight;
  32. }
  33. }
  34. }
  35. }