SqLasticSoftware

[ Tema ] Royal Teması

Jan 7th, 2017
141
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VB.NET 41.04 KB | None | 0 0
  1. Imports System.Drawing
  2. Imports System.Drawing.Drawing2D
  3. Imports System.ComponentModel
  4. Imports System.Text
  5. Imports System.Drawing.Text
  6.  
  7. ''' <summary>
  8. ''' Loyal Theme
  9. ''' Created by Earn
  10. ''' From HackForums.net
  11. ''' </summary>
  12. ''' <remarks></remarks>
  13.  
  14. Enum MouseState
  15.     None = 0
  16.     Over = 1
  17.     Down = 2
  18. End Enum
  19.  
  20. Class LoyalTheme
  21.     Inherits ContainerControl
  22.  
  23. #Region " Back End "
  24.  
  25. #Region " Enums "
  26.  
  27.     Enum ControlsAlign
  28.         Left = 0
  29.         Right = 2
  30.     End Enum
  31.  
  32.     Enum TextAlign
  33.         Left = 0
  34.         Center = 1
  35.         Right = 2
  36.     End Enum
  37.  
  38. #End Region
  39.  
  40. #Region " Declarations "
  41.     Private _Down As Boolean = False
  42.     Private _Header As Integer = 47
  43.     Private _MousePoint As Point
  44.     Private _ControlsFormat As New StringFormat With {.LineAlignment = StringAlignment.Center}
  45. #End Region
  46.  
  47. #Region " Properties "
  48.  
  49.     Private _HeaderColor As Color = Color.Aqua
  50.     <Category("Header Settings")> _
  51.     Public Property HeaderColor() As Color
  52.         Get
  53.             Return _HeaderColor
  54.         End Get
  55.         Set(ByVal value As Color)
  56.             _HeaderColor = value
  57.             Invalidate()
  58.         End Set
  59.     End Property
  60.  
  61.     'Alignments
  62.     Private _ControlsAlignment As ControlsAlign = ControlsAlign.Right
  63.     <Category("Header Settings")> _
  64.     Public Property ControlsAlignment() As ControlsAlign
  65.         Get
  66.             Return _ControlsAlignment
  67.         End Get
  68.         Set(ByVal value As ControlsAlign)
  69.             _ControlsAlignment = value
  70.             Invalidate()
  71.         End Set
  72.     End Property
  73.  
  74.     Private _TextAlignment As TextAlign = TextAlign.Center
  75.     <Category("Header Settings")> _
  76.     Public Property TextAlignment() As TextAlign
  77.         Get
  78.             Return _TextAlignment
  79.         End Get
  80.         Set(ByVal value As TextAlign)
  81.             _TextAlignment = value
  82.             Invalidate()
  83.         End Set
  84.     End Property
  85.  
  86.     'Header Size
  87.     Private _HeaderSize As Integer = 30
  88.     <Category("Header Settings")> _
  89.     Public Property HeaderSize() As Integer
  90.         Get
  91.             Return _HeaderSize
  92.         End Get
  93.         Set(ByVal value As Integer)
  94.             _HeaderSize = value
  95.             Invalidate()
  96.         End Set
  97.     End Property
  98.  
  99.  
  100.     'Show Controls
  101.     Private _ShowClose As Boolean
  102.     <Category("Header Settings")> _
  103.     Public Property ShowClose() As Boolean
  104.         Get
  105.             Return _ShowClose
  106.         End Get
  107.         Set(ByVal value As Boolean)
  108.             _ShowClose = value
  109.             Invalidate()
  110.         End Set
  111.     End Property
  112.  
  113.     Private _ShowMinimize As Boolean
  114.     <Category("Header Settings")> _
  115.     Public Property ShowMinimize() As Boolean
  116.         Get
  117.             Return _ShowMinimize
  118.         End Get
  119.         Set(ByVal value As Boolean)
  120.             _ShowMinimize = value
  121.             Invalidate()
  122.         End Set
  123.     End Property
  124.  
  125.     Private _ShowMaximize As Boolean
  126.     <Category("Header Settings")> _
  127.     Public Property ShowMaximize() As Boolean
  128.         Get
  129.             Return _ShowMaximize
  130.         End Get
  131.         Set(ByVal value As Boolean)
  132.             _ShowMaximize = value
  133.             Invalidate()
  134.         End Set
  135.     End Property
  136.  
  137. #End Region
  138.  
  139. #Region " Mouse States "
  140.  
  141.     Protected Overrides Sub OnMouseDown(e As MouseEventArgs)
  142.         MyBase.OnMouseDown(e)
  143.  
  144.         Select Case ControlsAlignment
  145.             Case ControlsAlign.Right
  146.                 '_ShowClose
  147.                 If _ShowClose = True Then
  148.                     If New Rectangle(Width - 23, (((_HeaderSize + 2) - 18) / 2), 18, 18).Contains(e.Location) Then
  149.                         Application.Exit()
  150.                     End If
  151.                 End If
  152.  
  153.                 '_ShowMinimize
  154.                 If _ShowMinimize = True Then
  155.                     If _ShowMaximize = True Then
  156.                         If _ShowClose = True Then
  157.  
  158.                             If New Rectangle(Width - 58, (((_HeaderSize + 2) - 18) / 2), 17, 18).Contains(e.Location) Then
  159.                                 FindForm.WindowState = FormWindowState.Minimized
  160.                                 Exit Sub
  161.                             End If
  162.  
  163.                         Else
  164.                             If New Rectangle(Width - 41, (((_HeaderSize + 2) - 18) / 2), 18, 18).Contains(e.Location) Then
  165.                                 FindForm.WindowState = FormWindowState.Minimized
  166.                                 Exit Sub
  167.                             End If
  168.                         End If
  169.                     Else
  170.                         If _ShowClose = True Then
  171.                             If New Rectangle(Width - 41, (((_HeaderSize + 2) - 18) / 2), 18, 18).Contains(e.Location) Then
  172.                                 FindForm.WindowState = FormWindowState.Minimized
  173.                                 Exit Sub
  174.                             End If
  175.                         Else
  176.                             If New Rectangle(Width - 23, (((_HeaderSize + 2) - 18) / 2), 18, 18).Contains(e.Location) Then
  177.                                 FindForm.WindowState = FormWindowState.Minimized
  178.                                 Exit Sub
  179.                             End If
  180.                         End If
  181.                     End If
  182.                 End If
  183.  
  184.                 '_ShowMaximize
  185.                 If _ShowMaximize = True Then
  186.                     If _ShowClose = True Then
  187.  
  188.                         If New Rectangle(Width - 41, (((_HeaderSize + 2) - 18) / 2), 18, 18).Contains(e.Location) Then
  189.                             If FindForm.WindowState = FormWindowState.Maximized Then
  190.                                 FindForm.WindowState = FormWindowState.Normal
  191.                                 Refresh()
  192.                             ElseIf FindForm.WindowState = FormWindowState.Normal Then
  193.                                 FindForm.WindowState = FormWindowState.Maximized
  194.                                 Refresh()
  195.                             End If
  196.                             Exit Sub
  197.                         End If
  198.  
  199.                     Else
  200.                         If New Rectangle(Width - 23, (((_HeaderSize + 2) - 18) / 2), 18, 18).Contains(e.Location) Then
  201.                             If FindForm.WindowState = FormWindowState.Maximized Then
  202.                                 FindForm.WindowState = FormWindowState.Normal
  203.                                 Refresh()
  204.                             ElseIf FindForm.WindowState = FormWindowState.Normal Then
  205.                                 FindForm.WindowState = FormWindowState.Maximized
  206.                                 Refresh()
  207.                             End If
  208.                             Exit Sub
  209.                         End If
  210.                     End If
  211.                 End If
  212.  
  213.             Case ControlsAlign.Left
  214.                 '_ShowClose
  215.                 If _ShowClose = True Then
  216.                     If New Rectangle(4, (((_HeaderSize + 2) - 18) / 2), 18, 18).Contains(e.Location) Then
  217.                         Application.Exit()
  218.                     End If
  219.                 End If
  220.  
  221.                 '_ShowMinimize
  222.                 If _ShowMinimize = True Then
  223.                     If _ShowMaximize = True Then
  224.                         If _ShowClose = True Then
  225.  
  226.                             If New Rectangle(40, (((_HeaderSize + 2) - 18) / 2), 17, 18).Contains(e.Location) Then
  227.                                 FindForm.WindowState = FormWindowState.Minimized
  228.                                 Exit Sub
  229.                             End If
  230.  
  231.                         Else
  232.                             If New Rectangle(22, (((_HeaderSize + 2) - 18) / 2), 18, 18).Contains(e.Location) Then
  233.                                 FindForm.WindowState = FormWindowState.Minimized
  234.                                 Exit Sub
  235.                             End If
  236.                         End If
  237.                     Else
  238.                         If _ShowClose = True Then
  239.                             If New Rectangle(22, (((_HeaderSize + 2) - 18) / 2), 18, 18).Contains(e.Location) Then
  240.                                 FindForm.WindowState = FormWindowState.Minimized
  241.                                 Exit Sub
  242.                             End If
  243.                         Else
  244.                             If New Rectangle(4, (((_HeaderSize + 2) - 18) / 2), 18, 18).Contains(e.Location) Then
  245.                                 FindForm.WindowState = FormWindowState.Minimized
  246.                                 Exit Sub
  247.                             End If
  248.                         End If
  249.                     End If
  250.                 End If
  251.  
  252.                 '_ShowMaximize
  253.                 If _ShowMaximize = True Then
  254.                     If _ShowClose = True Then
  255.  
  256.                         If New Rectangle(22, (((_HeaderSize + 2) - 18) / 2), 18, 18).Contains(e.Location) Then
  257.                             If FindForm.WindowState = FormWindowState.Maximized Then
  258.                                 FindForm.WindowState = FormWindowState.Normal
  259.                                 Refresh()
  260.                             ElseIf FindForm.WindowState = FormWindowState.Normal Then
  261.                                 FindForm.WindowState = FormWindowState.Maximized
  262.                                 Refresh()
  263.                             End If
  264.                             Exit Sub
  265.                         End If
  266.  
  267.                     Else
  268.                         If New Rectangle(4, (((_HeaderSize + 2) - 18) / 2), 18, 18).Contains(e.Location) Then
  269.                             If FindForm.WindowState = FormWindowState.Maximized Then
  270.                                 FindForm.WindowState = FormWindowState.Normal
  271.                                 Refresh()
  272.                             ElseIf FindForm.WindowState = FormWindowState.Normal Then
  273.                                 FindForm.WindowState = FormWindowState.Maximized
  274.                                 Refresh()
  275.                             End If
  276.                             Exit Sub
  277.                         End If
  278.                     End If
  279.                 End If
  280.         End Select
  281.  
  282.         If e.Y < _Header AndAlso e.Button = Windows.Forms.MouseButtons.Left Then
  283.             _Down = True
  284.             _MousePoint = New Point(e.Location)
  285.         End If
  286.     End Sub
  287.  
  288.     Protected Overrides Sub OnMouseUp(e As MouseEventArgs)
  289.         MyBase.OnMouseUp(e)
  290.         _Down = False
  291.     End Sub
  292.  
  293.     Protected Overrides Sub OnMouseMove(e As MouseEventArgs)
  294.         MyBase.OnMouseMove(e)
  295.         If _Down = True Then
  296.             ParentForm.Location = MousePosition - _MousePoint
  297.         End If
  298.     End Sub
  299.  
  300. #End Region
  301.  
  302. #Region " Misc "
  303.     Protected Overrides Sub OnCreateControl()
  304.         MyBase.OnCreateControl()
  305.         Dock = DockStyle.Fill
  306.         ParentForm.TransparencyKey = Color.Fuchsia
  307.         ParentForm.FormBorderStyle = FormBorderStyle.None
  308.         BackColor = Color.FromArgb(31, 31, 31)
  309.         Invalidate()
  310.     End Sub
  311.  
  312. #End Region
  313.  
  314. #End Region
  315.  
  316.     Protected Overrides Sub OnPaint(e As PaintEventArgs)
  317.         MyBase.OnPaint(e)
  318.         Dim G = e.Graphics
  319.         With G
  320.             Dim _StringF As New StringFormat With {.LineAlignment = StringAlignment.Center}
  321.             .Clear(Color.FromArgb(31, 31, 31))
  322.             .FillRectangle(New SolidBrush(_HeaderColor), New Rectangle(0, 0, Width, 5))
  323.             .FillRectangle(New SolidBrush(Color.FromArgb(34, 34, 34)), New Rectangle(0, 5, Width, _HeaderSize))
  324.             .DrawLine(New Pen(Color.FromArgb(38, 38, 38)), New Point(0, _HeaderSize + 5), New Point(Width, _HeaderSize + 5))
  325.             .DrawLine(New Pen(Color.FromArgb(24, 24, 24)), New Point(0, _HeaderSize + 6), New Point(Width, _HeaderSize + 6))
  326.             .DrawLine(Pens.Fuchsia, New Point(0, 0), New Point(0, 2))
  327.             .DrawLine(Pens.Fuchsia, New Point(0, 0), New Point(2, 0))
  328.             .DrawLine(Pens.Fuchsia, New Point(Width - 1, 0), New Point(Width - 1, 2))
  329.             .DrawLine(Pens.Fuchsia, New Point(Width - 1, 0), New Point(Width - 3, 0))
  330.             If _ControlsAlignment = ControlsAlign.Right Then
  331.                 If _ShowClose = True Then
  332.                     .DrawString("r", New Font("Marlett", 11), Brushes.White, New RectangleF(Width - 23, 5, 23, _HeaderSize + 3), _ControlsFormat)
  333.                 End If
  334.                 If _ShowMinimize = True Then
  335.                     If _ShowMaximize = True Then
  336.                         If _ShowClose = True Then
  337.                             G.DrawString("0", New Font("Marlett", 11), Brushes.White, New RectangleF(Width - 57, 5, 23, _HeaderSize + 3), _ControlsFormat)
  338.                         Else
  339.                             G.DrawString("0", New Font("Marlett", 11), Brushes.White, New RectangleF(Width - 41, 5, 23, _HeaderSize + 3), _ControlsFormat)
  340.                         End If
  341.                     Else
  342.                         If _ShowClose = True Then
  343.                             G.DrawString("0", New Font("Marlett", 11), Brushes.White, New RectangleF(Width - 41, 5, 23, _HeaderSize + 3), _ControlsFormat)
  344.                         Else
  345.                             G.DrawString("0", New Font("Marlett", 11), Brushes.White, New RectangleF(Width - 23, 5, 23, _HeaderSize + 3), _ControlsFormat)
  346.                         End If
  347.                     End If
  348.                 End If
  349.                 If _ShowMaximize = True Then
  350.                     If _ShowClose = True Then
  351.                         If FindForm.WindowState = FormWindowState.Maximized Then
  352.                             .DrawString("1", New Font("Marlett", 11), Brushes.White, New RectangleF(Width - 41, 5, 23, _HeaderSize + 3), _ControlsFormat)
  353.                         ElseIf FindForm.WindowState = FormWindowState.Normal Then
  354.                             .DrawString("2", New Font("Marlett", 11), Brushes.White, New RectangleF(Width - 41, 5, 23, _HeaderSize + 3), _ControlsFormat)
  355.                         End If
  356.                     Else
  357.                         If FindForm.WindowState = FormWindowState.Maximized Then
  358.                             .DrawString("1", New Font("Marlett", 11), Brushes.White, New RectangleF(Width - 23, 5, 23, _HeaderSize + 3), _ControlsFormat)
  359.                         ElseIf FindForm.WindowState = FormWindowState.Normal Then
  360.                             .DrawString("2", New Font("Marlett", 11), Brushes.White, New RectangleF(Width - 23, 5, 23, _HeaderSize + 3), _ControlsFormat)
  361.                         End If
  362.                     End If
  363.                 End If
  364.             End If
  365.             If _ControlsAlignment = ControlsAlign.Left Then
  366.                 If _ShowClose = True Then
  367.                     .DrawString("r", New Font("Marlett", 11), Brushes.White, New RectangleF(5, 5, 23, _HeaderSize + 3), _ControlsFormat)
  368.                 End If
  369.                 If _ShowMinimize = True Then
  370.                     If _ShowMaximize = True Then
  371.                         If _ShowClose = True Then
  372.                             G.DrawString("0", New Font("Marlett", 11), Brushes.White, New RectangleF(41, 5, 23, _HeaderSize + 3), _ControlsFormat)
  373.                         Else
  374.                             G.DrawString("0", New Font("Marlett", 11), Brushes.White, New RectangleF(23, 5, 23, _HeaderSize + 3), _ControlsFormat)
  375.                         End If
  376.                     Else
  377.                         If _ShowClose = True Then
  378.                             G.DrawString("0", New Font("Marlett", 11), Brushes.White, New RectangleF(23, 5, 23, _HeaderSize + 3), _ControlsFormat)
  379.                         Else
  380.                             G.DrawString("0", New Font("Marlett", 11), Brushes.White, New RectangleF(5, 5, 23, _HeaderSize + 3), _ControlsFormat)
  381.                         End If
  382.                     End If
  383.                 End If
  384.                 If _ShowMaximize = True Then
  385.                     If _ShowClose = True Then
  386.                         If FindForm.WindowState = FormWindowState.Maximized Then
  387.                             .DrawString("1", New Font("Marlett", 11), Brushes.White, New RectangleF(23, 5, 23, _HeaderSize + 3), _ControlsFormat)
  388.                         ElseIf FindForm.WindowState = FormWindowState.Normal Then
  389.                             .DrawString("2", New Font("Marlett", 11), Brushes.White, New RectangleF(23, 5, 23, _HeaderSize + 3), _ControlsFormat)
  390.                         End If
  391.                     Else
  392.                         If FindForm.WindowState = FormWindowState.Maximized Then
  393.                             .DrawString("1", New Font("Marlett", 11), Brushes.White, New RectangleF(5, 5, 23, _HeaderSize + 3), _ControlsFormat)
  394.                         ElseIf FindForm.WindowState = FormWindowState.Normal Then
  395.                             .DrawString("2", New Font("Marlett", 11), Brushes.White, New RectangleF(5, 5, 23, _HeaderSize + 3), _ControlsFormat)
  396.                         End If
  397.                     End If
  398.                 End If
  399.             End If
  400.             Select Case _TextAlignment
  401.                 Case TextAlign.Center
  402.                     _StringF.Alignment = StringAlignment.Center
  403.                     .DrawString(Text, New Font("Arial", 9), Brushes.White, New RectangleF(0, 5, Width, _HeaderSize), _StringF)
  404.  
  405.                 Case TextAlign.Left
  406.                     .DrawString(Text, New Font("Arial", 9), Brushes.White, New RectangleF(10, 5, Width, _HeaderSize), _StringF)
  407.  
  408.                 Case TextAlign.Right
  409.                     Dim _TextLength As Integer = TextRenderer.MeasureText(Text, New Font("Arial", 9)).Width + 10
  410.                     .DrawString(Text, New Font("Arial", 9), Brushes.White, New RectangleF(Width - _TextLength, 5, Width, _HeaderSize), _StringF)
  411.             End Select
  412.         End With
  413.     End Sub
  414. End Class
  415.  
  416. Class LoyalButton
  417.     Inherits Control
  418.  
  419. #Region " Back End "
  420.  
  421. #Region " Enums "
  422.     Enum Alignment
  423.         Left = 0
  424.         Center = 1
  425.         Right = 2
  426.     End Enum
  427. #End Region
  428.  
  429. #Region " Declarations "
  430.     Private _State As MouseState = MouseState.None
  431. #End Region
  432.  
  433. #Region " Mouse States "
  434.  
  435.     Protected Overrides Sub OnMouseEnter(e As EventArgs)
  436.         MyBase.OnMouseEnter(e)
  437.         _State = MouseState.Over
  438.         Invalidate()
  439.     End Sub
  440.  
  441.     Protected Overrides Sub OnMouseLeave(e As EventArgs)
  442.         MyBase.OnMouseLeave(e)
  443.         _State = MouseState.None
  444.         Invalidate()
  445.     End Sub
  446.  
  447.     Protected Overrides Sub OnMouseDown(e As MouseEventArgs)
  448.         MyBase.OnMouseDown(e)
  449.         _State = MouseState.Down
  450.         Invalidate()
  451.     End Sub
  452.  
  453.     Protected Overrides Sub OnMouseUp(e As MouseEventArgs)
  454.         MyBase.OnMouseUp(e)
  455.         _State = MouseState.Over
  456.         Invalidate()
  457.     End Sub
  458.  
  459. #End Region
  460.  
  461. #Region " Properties "
  462.  
  463.     Private _TextAlignment As Alignment = Alignment.Center
  464.     <Category("Button Settings")> _
  465.     Public Property TextAlignment() As Alignment
  466.         Get
  467.             Return _TextAlignment
  468.         End Get
  469.         Set(ByVal value As Alignment)
  470.             _TextAlignment = value
  471.             Invalidate()
  472.         End Set
  473.     End Property
  474.  
  475.     Private _OutlineColor As Color = Color.FromArgb(102, 51, 153)
  476.     <Category("Button Settings")> _
  477.     Public Property OutlineColor() As Color
  478.         Get
  479.             Return _OutlineColor
  480.         End Get
  481.         Set(ByVal value As Color)
  482.             _OutlineColor = value
  483.             Invalidate()
  484.         End Set
  485.     End Property
  486.  
  487. #End Region
  488.  
  489.     Sub New()
  490.         Size = New Size(75, 25)
  491.     End Sub
  492. #End Region
  493.  
  494.     Protected Overrides Sub OnPaint(e As PaintEventArgs)
  495.         MyBase.OnPaint(e)
  496.         Dim G = e.Graphics
  497.         With G
  498.             .Clear(Color.FromArgb(40, 40, 40))
  499.             Select Case _State
  500.                 Case MouseState.None
  501.                     .DrawRectangle(New Pen(Color.FromArgb(24, 24, 24)), New Rectangle(0, 0, Width - 1, Height - 1))
  502.                 Case MouseState.Over
  503.                     .DrawRectangle(New Pen(_OutlineColor), New Rectangle(0, 0, Width - 1, Height - 1))
  504.  
  505.                 Case MouseState.Down
  506.                     .FillRectangle(New SolidBrush(Color.FromArgb(30, 30, 30)), New Rectangle(0, 0, Width - 1, Height - 1))
  507.                     .DrawRectangle(New Pen(_OutlineColor), New Rectangle(0, 0, Width - 1, Height - 1))
  508.             End Select
  509.             .DrawRectangle(New Pen(Color.FromArgb(48, 48, 48)), New Rectangle(1, 1, Width - 3, Height - 3))
  510.             .FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(0, 0, 1, 1))
  511.             .FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(0, Height - 1, 1, 1))
  512.             .FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(Width - 1, 0, 1, 1))
  513.             .FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(Width - 1, Height - 1, 1, 1))
  514.             Dim _StringF As New StringFormat With {.LineAlignment = StringAlignment.Center}
  515.             Select Case _TextAlignment
  516.                 Case Alignment.Center
  517.                     _StringF.Alignment = StringAlignment.Center
  518.                     .DrawString(Text, New Font("Arial", 9), Brushes.White, New RectangleF(0, 0, Width - 1, Height - 1), _StringF)
  519.                 Case Alignment.Left
  520.                     .DrawString(Text, New Font("Arial", 9), Brushes.White, New RectangleF(7, 0, Width - 11, Height - 1), _StringF)
  521.                 Case Alignment.Right
  522.                     Dim _StringLength As Integer = TextRenderer.MeasureText(Text, New Font("Arial", 9)).Width + 8
  523.                     .DrawString(Text, New Font("Arial", 9), Brushes.White, New Rectangle(Width - _StringLength, 0, Width - _StringLength, Height - 1), _StringF)
  524.             End Select
  525.         End With
  526.     End Sub
  527. End Class
  528.  
  529. Class LoyalGroupBox
  530.     Inherits ContainerControl
  531.  
  532. #Region " Back End "
  533.  
  534. #Region " Enums "
  535.  
  536.     Enum TextAlign
  537.         Left = 0
  538.         Center = 1
  539.         Right = 2
  540.     End Enum
  541.  
  542. #End Region
  543.  
  544. #Region " Properties "
  545.  
  546.     Private _HeaderSize As Integer = 35
  547.     <Category("Header Properties")> _
  548.     Public Property HeaderSize() As Integer
  549.         Get
  550.             Return _HeaderSize
  551.         End Get
  552.         Set(ByVal value As Integer)
  553.             _HeaderSize = value
  554.             Invalidate()
  555.         End Set
  556.     End Property
  557.  
  558.     Private _HeaderColor As Color = Color.FromArgb(102, 51, 153)
  559.     <Category("Header Properties")> _
  560.     Public Property HeaderColor() As Color
  561.         Get
  562.             Return _HeaderColor
  563.         End Get
  564.         Set(ByVal value As Color)
  565.             _HeaderColor = value
  566.             Invalidate()
  567.         End Set
  568.     End Property
  569.  
  570.     Private _TextAlignment As TextAlign = TextAlign.Left
  571.     Public Property TextAlignment() As TextAlign
  572.         Get
  573.             Return _TextAlignment
  574.         End Get
  575.         Set(ByVal value As TextAlign)
  576.             _TextAlignment = value
  577.         End Set
  578.     End Property
  579.  
  580. #End Region
  581.  
  582.     Protected Overrides Sub OnCreateControl()
  583.         MyBase.OnCreateControl()
  584.         BackColor = Color.FromArgb(40, 40, 40)
  585.     End Sub
  586.  
  587.     Sub New()
  588.         Size = New Size(200, 100)
  589.     End Sub
  590.  
  591. #End Region
  592.  
  593.     Protected Overrides Sub OnPaint(e As PaintEventArgs)
  594.         MyBase.OnPaint(e)
  595.         Dim G = e.Graphics
  596.         With G
  597.             .Clear(Color.FromArgb(40, 40, 40))
  598.             .FillRectangle(New SolidBrush(_HeaderColor), New Rectangle(5, 5, Width - 10, _HeaderSize - 5))
  599.             .DrawLine(New Pen(Color.FromArgb(30, Color.White)), New Point(6, 5), New Point(Width - 6, 5))
  600.             .FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(0, 0, 1, 1))
  601.             .FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(Width - 1, 0, 1, 1))
  602.             .DrawLine(New Pen(Color.FromArgb(70, Color.Black)), New Point(5, _HeaderSize), New Point(Width - 6, _HeaderSize))
  603.             .DrawRectangle(New Pen(Color.FromArgb(18, 18, 18)), New Rectangle(0, 0, Width - 1, Height - 1))
  604.             .FillRectangle(New SolidBrush(Color.FromArgb(40, 40, 40)), New Rectangle(5, 5, 1, 1))
  605.             .FillRectangle(New SolidBrush(Color.FromArgb(40, 40, 40)), New Rectangle(Width - 6, 5, 1, 1))
  606.             .FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(0, 0, 1, 1))
  607.             .FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(0, Height - 1, 1, 1))
  608.             .FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(Width - 1, 0, 1, 1))
  609.             .FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(Width - 1, Height - 1, 1, 1))
  610.             Dim _StringF As New StringFormat With {.LineAlignment = StringAlignment.Center}
  611.             Select Case _TextAlignment
  612.                 Case TextAlign.Center
  613.                     _StringF.Alignment = StringAlignment.Center
  614.                     .DrawString(Text, New Font("Arial", 9), Brushes.White, New RectangleF(5, 5, Width - 10, _HeaderSize - 5), _StringF)
  615.                 Case TextAlign.Left
  616.                     .DrawString(Text, New Font("Arial", 9), Brushes.White, New RectangleF(12, 5, Width - 10, _HeaderSize - 5), _StringF)
  617.                 Case TextAlign.Right
  618.                     Dim _StringLength As Integer = TextRenderer.MeasureText(Text, New Font("Arial", 9)).Width + 8
  619.                     .DrawString(Text, New Font("Arial", 9), Brushes.White, New Rectangle(Width - _StringLength, 5, Width - _StringLength, _HeaderSize - 5), _StringF)
  620.             End Select
  621.         End With
  622.     End Sub
  623. End Class
  624.  
  625. <DefaultEvent("CheckedChanged")>
  626. Class LoyalRadioButton
  627.     Inherits Control
  628.  
  629. #Region " Back End "
  630.  
  631. #Region " Declarations "
  632.     Private _State As MouseState = MouseState.None
  633.     Private _Checked As Boolean
  634. #End Region
  635.  
  636. #Region " Properties "
  637.     Property Checked() As Boolean
  638.         Get
  639.             Return _Checked
  640.         End Get
  641.         Set(value As Boolean)
  642.             _Checked = value
  643.             InvalidateControls()
  644.             RaiseEvent CheckedChanged(Me)
  645.             Invalidate()
  646.         End Set
  647.     End Property
  648.     Event CheckedChanged(ByVal sender As Object)
  649.     Protected Overrides Sub OnClick(e As EventArgs)
  650.         If Not _Checked Then Checked = True
  651.         MyBase.OnClick(e)
  652.     End Sub
  653.     Private Sub InvalidateControls()
  654.         If Not IsHandleCreated OrElse Not _Checked Then Return
  655.         For Each C As Control In Parent.Controls
  656.             If C IsNot Me AndAlso TypeOf C Is LoyalRadioButton Then
  657.                 DirectCast(C, LoyalRadioButton).Checked = False
  658.                 Invalidate()
  659.             End If
  660.         Next
  661.     End Sub
  662.  
  663.     Private _CheckedColor As Color = Color.FromArgb(102, 51, 153)
  664.     <Category("Colors Settings")> _
  665.     Public Property CheckedColor() As Color
  666.         Get
  667.             Return _CheckedColor
  668.         End Get
  669.         Set(ByVal value As Color)
  670.             _CheckedColor = value
  671.             Invalidate()
  672.         End Set
  673.     End Property
  674.     Protected Overrides Sub OnCreateControl()
  675.         MyBase.OnCreateControl()
  676.         InvalidateControls()
  677.     End Sub
  678.  
  679.  
  680.     Protected Overrides Sub OnResize(e As EventArgs)
  681.         MyBase.OnResize(e)
  682.         Height = 16
  683.     End Sub
  684.  
  685. #Region " Mouse States "
  686.  
  687.     Protected Overrides Sub OnMouseDown(e As MouseEventArgs)
  688.         MyBase.OnMouseDown(e)
  689.         _State = MouseState.Down
  690.         Invalidate()
  691.     End Sub
  692.     Protected Overrides Sub OnMouseUp(e As MouseEventArgs)
  693.         MyBase.OnMouseUp(e)
  694.         _State = MouseState.Over
  695.         Invalidate()
  696.     End Sub
  697.     Protected Overrides Sub OnMouseEnter(e As EventArgs)
  698.         MyBase.OnMouseEnter(e)
  699.         _State = MouseState.Over
  700.         Invalidate()
  701.     End Sub
  702.     Protected Overrides Sub OnMouseLeave(e As EventArgs)
  703.         MyBase.OnMouseLeave(e)
  704.         _State = MouseState.None
  705.         Invalidate()
  706.     End Sub
  707.  
  708. #End Region
  709.  
  710. #End Region
  711.  
  712. #End Region
  713.  
  714.     Protected Overrides Sub OnPaint(e As PaintEventArgs)
  715.         MyBase.OnPaint(e)
  716.         Dim G = e.Graphics
  717.         G.SmoothingMode = SmoothingMode.AntiAlias
  718.         G.Clear(Parent.BackColor)
  719.         If Parent.BackColor = Color.FromArgb(40, 40, 40) Then
  720.             G.FillEllipse(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(0, 0, 13, 13))
  721.         Else
  722.             G.FillEllipse(New SolidBrush(Color.FromArgb(40, 40, 40)), New Rectangle(0, 0, 13, 13))
  723.         End If
  724.         G.DrawEllipse(New Pen(Color.FromArgb(18, 18, 18)), New Rectangle(0, 0, 13, 13))
  725.  
  726.         If Checked Then
  727.             G.FillEllipse(New SolidBrush(_CheckedColor), New Rectangle(3, 3, 7, 7))
  728.         End If
  729.         G.DrawString(Text, New Font("Arial", 9), Brushes.White, New Point(18, 0))
  730.     End Sub
  731. End Class
  732.  
  733. <DefaultEvent("CheckedChanged")>
  734. Class LoyalCheckBox
  735.     Inherits Control
  736.  
  737. #Region " Back End "
  738.  
  739. #Region " Declarations "
  740.     Private _State As MouseState = MouseState.None
  741.     Private _Checked As Boolean
  742. #End Region
  743.  
  744. #Region " Properties "
  745.     Property Checked() As Boolean
  746.         Get
  747.             Return _Checked
  748.         End Get
  749.         Set(value As Boolean)
  750.             _Checked = value
  751.             RaiseEvent CheckedChanged(Me)
  752.             Invalidate()
  753.         End Set
  754.     End Property
  755.     Event CheckedChanged(ByVal sender As Object)
  756.     Protected Overrides Sub OnClick(e As EventArgs)
  757.         If Not _Checked Then
  758.             Checked = True
  759.         Else
  760.             Checked = False
  761.         End If
  762.         MyBase.OnClick(e)
  763.     End Sub
  764.  
  765.     Private _CheckedColor As Color = Color.FromArgb(102, 51, 153)
  766.     <Category("Colors Settings")> _
  767.     Public Property CheckedColor() As Color
  768.         Get
  769.             Return _CheckedColor
  770.         End Get
  771.         Set(ByVal value As Color)
  772.             _CheckedColor = value
  773.             Invalidate()
  774.         End Set
  775.     End Property
  776.  
  777.     Protected Overrides Sub OnResize(e As EventArgs)
  778.         MyBase.OnResize(e)
  779.         Height = 16
  780.     End Sub
  781.  
  782. #Region " Mouse States "
  783.  
  784.     Protected Overrides Sub OnMouseDown(e As MouseEventArgs)
  785.         MyBase.OnMouseDown(e)
  786.         _State = MouseState.Down
  787.         Invalidate()
  788.     End Sub
  789.     Protected Overrides Sub OnMouseUp(e As MouseEventArgs)
  790.         MyBase.OnMouseUp(e)
  791.         _State = MouseState.Over
  792.         Invalidate()
  793.     End Sub
  794.     Protected Overrides Sub OnMouseEnter(e As EventArgs)
  795.         MyBase.OnMouseEnter(e)
  796.         _State = MouseState.Over
  797.         Invalidate()
  798.     End Sub
  799.     Protected Overrides Sub OnMouseLeave(e As EventArgs)
  800.         MyBase.OnMouseLeave(e)
  801.         _State = MouseState.None
  802.         Invalidate()
  803.     End Sub
  804.  
  805. #End Region
  806.  
  807. #End Region
  808.  
  809. #End Region
  810.  
  811.     Protected Overrides Sub OnPaint(e As PaintEventArgs)
  812.         MyBase.OnPaint(e)
  813.         Dim G = e.Graphics
  814.         G.Clear(Parent.BackColor)
  815.         If Parent.BackColor = Color.FromArgb(40, 40, 40) Then
  816.             G.FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(0, 0, 13, 13))
  817.         Else
  818.             G.FillRectangle(New SolidBrush(Color.FromArgb(40, 40, 40)), New Rectangle(0, 0, 13, 13))
  819.         End If
  820.         G.DrawRectangle(New Pen(Color.FromArgb(18, 18, 18)), New Rectangle(0, 0, 13, 13))
  821.  
  822.         If Checked Then
  823.             G.FillRectangle(New SolidBrush(_CheckedColor), New Rectangle(3, 3, 8, 8))
  824.         End If
  825.         G.DrawString(Text, New Font("Arial", 9), Brushes.White, New Point(18, 0))
  826.     End Sub
  827. End Class
  828.  
  829. Class LoyalProgressBar
  830.     Inherits Control
  831.  
  832. #Region " Back End "
  833.  
  834. #Region " Variables "
  835.     Private _Value As Integer = 0
  836.     Private _Maximum As Integer = 100
  837. #End Region
  838.  
  839. #Region " Control "
  840.     <Category("Control")>
  841.     Public Property Maximum() As Integer
  842.         Get
  843.             Return _Maximum
  844.         End Get
  845.         Set(V As Integer)
  846.             Select Case V
  847.                 Case Is < _Value
  848.                     _Value = V
  849.             End Select
  850.             _Maximum = V
  851.             Invalidate()
  852.         End Set
  853.     End Property
  854.  
  855.     <Category("Control")>
  856.     Public Property Value() As Integer
  857.         Get
  858.             Select Case _Value
  859.                 Case 0
  860.                     Return 0
  861.                     Invalidate()
  862.                 Case Else
  863.                     Return _Value
  864.                     Invalidate()
  865.             End Select
  866.         End Get
  867.         Set(V As Integer)
  868.             Select Case V
  869.                 Case Is > _Maximum
  870.                     V = _Maximum
  871.                     Invalidate()
  872.             End Select
  873.             _Value = V
  874.             Invalidate()
  875.         End Set
  876.     End Property
  877. #End Region
  878.  
  879. #Region " Events "
  880.     Protected Overrides Sub OnResize(e As EventArgs)
  881.         MyBase.OnResize(e)
  882.         Height = 25
  883.     End Sub
  884.  
  885.     Protected Overrides Sub CreateHandle()
  886.         MyBase.CreateHandle()
  887.         Height = 25
  888.     End Sub
  889.  
  890.     Public Sub Increment(ByVal Amount As Integer)
  891.         Value += Amount
  892.     End Sub
  893. #End Region
  894.  
  895. #Region " Properties "
  896.     Private _ProgressColor As Color = Color.FromArgb(102, 51, 153)
  897.     <Category("Header Properties")> _
  898.     Public Property ProgressColor() As Color
  899.         Get
  900.             Return _ProgressColor
  901.         End Get
  902.         Set(ByVal value As Color)
  903.             _ProgressColor = value
  904.             Invalidate()
  905.         End Set
  906.     End Property
  907. #End Region
  908.  
  909.     Sub New()
  910.         SetStyle(ControlStyles.AllPaintingInWmPaint Or ControlStyles.UserPaint Or _
  911.                  ControlStyles.ResizeRedraw Or ControlStyles.OptimizedDoubleBuffer, True)
  912.         DoubleBuffered = True
  913.     End Sub
  914. #End Region
  915.  
  916.     Protected Overrides Sub OnPaint(e As PaintEventArgs)
  917.         MyBase.OnPaint(e)
  918.         Dim G = e.Graphics
  919.         G.TextRenderingHint = TextRenderingHint.ClearTypeGridFit
  920.         G.SmoothingMode = SmoothingMode.HighQuality
  921.         G.PixelOffsetMode = PixelOffsetMode.HighQuality
  922.         If Parent.BackColor = Color.FromArgb(40, 40, 40) Then
  923.             G.Clear(Color.FromArgb(35, 35, 35))
  924.         Else
  925.             G.Clear(Color.FromArgb(40, 40, 40))
  926.         End If
  927.         Dim _Progress As Integer = CInt(_Value / _Maximum * Width)
  928.         G.DrawRectangle(New Pen(Color.FromArgb(18, 18, 18)), 0, 0, Width, Height)
  929.         G.FillRectangle(New SolidBrush(_ProgressColor), New Rectangle(0, 0, _Progress - 1, Height))
  930.         G.DrawLine(New Pen(Color.FromArgb(30, Color.White)), New Point(0, 0), New Point(_Progress - 1, 0))
  931.         G.FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(0, 0, 1, 1))
  932.         G.FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(Width - 1, 0, 1, 1))
  933.         G.DrawLine(New Pen(Color.FromArgb(70, Color.Black)), New Point(0, Height), New Point(_Progress - 1, Height))
  934.         G.InterpolationMode = CType(7, InterpolationMode)
  935.     End Sub
  936. End Class
  937.  
  938. <DefaultEvent("TextChanged")>
  939. Class LoyalTextBox
  940.     Inherits Control
  941.  
  942. #Region " Back End "
  943.  
  944. #Region " Variables "
  945.     Private _State As MouseState = MouseState.None
  946.     Private WithEvents TB As Windows.Forms.TextBox
  947. #End Region
  948.  
  949. #Region " Properties "
  950.  
  951. #Region " TextBox Properties "
  952.  
  953.     Private _TextAlign As HorizontalAlignment = HorizontalAlignment.Left
  954.     <Category("Options")> _
  955.     Property TextAlign() As HorizontalAlignment
  956.         Get
  957.             Return _TextAlign
  958.         End Get
  959.         Set(ByVal value As HorizontalAlignment)
  960.             _TextAlign = value
  961.             If TB IsNot Nothing Then
  962.                 TB.TextAlign = value
  963.             End If
  964.         End Set
  965.     End Property
  966.     Private _MaxLength As Integer = 32767
  967.     <Category("Options")> _
  968.     Property MaxLength() As Integer
  969.         Get
  970.             Return _MaxLength
  971.         End Get
  972.         Set(ByVal value As Integer)
  973.             _MaxLength = value
  974.             If TB IsNot Nothing Then
  975.                 TB.MaxLength = value
  976.             End If
  977.         End Set
  978.     End Property
  979.     Private _ReadOnly As Boolean
  980.     <Category("Options")> _
  981.     Property [ReadOnly]() As Boolean
  982.         Get
  983.             Return _ReadOnly
  984.         End Get
  985.         Set(ByVal value As Boolean)
  986.             _ReadOnly = value
  987.             If TB IsNot Nothing Then
  988.                 TB.ReadOnly = value
  989.             End If
  990.         End Set
  991.     End Property
  992.     Private _UseSystemPasswordChar As Boolean
  993.     <Category("Options")> _
  994.     Property UseSystemPasswordChar() As Boolean
  995.         Get
  996.             Return _UseSystemPasswordChar
  997.         End Get
  998.         Set(ByVal value As Boolean)
  999.             _UseSystemPasswordChar = value
  1000.             If TB IsNot Nothing Then
  1001.                 TB.UseSystemPasswordChar = value
  1002.             End If
  1003.         End Set
  1004.     End Property
  1005.     Private _Multiline As Boolean
  1006.     <Category("Options")> _
  1007.     Property Multiline() As Boolean
  1008.         Get
  1009.             Return _Multiline
  1010.         End Get
  1011.         Set(ByVal value As Boolean)
  1012.             _Multiline = value
  1013.             If TB IsNot Nothing Then
  1014.                 TB.Multiline = value
  1015.  
  1016.                 If value Then
  1017.                     TB.Height = Height - 11
  1018.                 Else
  1019.                     Height = TB.Height + 11
  1020.                 End If
  1021.  
  1022.             End If
  1023.         End Set
  1024.     End Property
  1025.     <Category("Options")> _
  1026.     Overrides Property Text As String
  1027.         Get
  1028.             Return MyBase.Text
  1029.         End Get
  1030.         Set(ByVal value As String)
  1031.             MyBase.Text = value
  1032.             If TB IsNot Nothing Then
  1033.                 TB.Text = value
  1034.             End If
  1035.         End Set
  1036.     End Property
  1037.     <Category("Options")> _
  1038.     Overrides Property Font As Font
  1039.         Get
  1040.             Return MyBase.Font
  1041.         End Get
  1042.         Set(ByVal value As Font)
  1043.             MyBase.Font = value
  1044.             If TB IsNot Nothing Then
  1045.                 TB.Font = value
  1046.                 TB.Location = New Point(3, 5)
  1047.                 TB.Width = Width - 6
  1048.  
  1049.                 If Not _Multiline Then
  1050.                     Height = TB.Height + 11
  1051.                 End If
  1052.             End If
  1053.         End Set
  1054.     End Property
  1055.  
  1056.     Protected Overrides Sub OnCreateControl()
  1057.         MyBase.OnCreateControl()
  1058.         If Not Controls.Contains(TB) Then
  1059.             Controls.Add(TB)
  1060.         End If
  1061.     End Sub
  1062.     Private Sub OnBaseTextChanged(ByVal s As Object, ByVal e As EventArgs)
  1063.         Text = TB.Text
  1064.     End Sub
  1065.     Private Sub OnBaseKeyDown(ByVal s As Object, ByVal e As KeyEventArgs)
  1066.         If e.Control AndAlso e.KeyCode = Keys.A Then
  1067.             TB.SelectAll()
  1068.             e.SuppressKeyPress = True
  1069.         End If
  1070.         If e.Control AndAlso e.KeyCode = Keys.C Then
  1071.             TB.Copy()
  1072.             e.SuppressKeyPress = True
  1073.         End If
  1074.     End Sub
  1075.     Protected Overrides Sub OnResize(ByVal e As EventArgs)
  1076.         TB.Location = New Point(5, 5)
  1077.         TB.Width = Width - 10
  1078.  
  1079.         If _Multiline Then
  1080.             TB.Height = Height - 11
  1081.         Else
  1082.             Height = TB.Height + 11
  1083.         End If
  1084.  
  1085.         MyBase.OnResize(e)
  1086.     End Sub
  1087.  
  1088. #End Region
  1089.  
  1090. #Region " Mouse States "
  1091.  
  1092.     Protected Overrides Sub OnMouseDown(e As MouseEventArgs)
  1093.         MyBase.OnMouseDown(e)
  1094.         _State = MouseState.Down
  1095.         Invalidate()
  1096.     End Sub
  1097.     Protected Overrides Sub OnMouseUp(e As MouseEventArgs)
  1098.         MyBase.OnMouseUp(e)
  1099.         _State = MouseState.Over
  1100.         TB.Focus()
  1101.         Invalidate()
  1102.     End Sub
  1103.     Protected Overrides Sub OnMouseEnter(e As EventArgs)
  1104.         MyBase.OnMouseEnter(e)
  1105.         _State = MouseState.Over
  1106.         TB.Focus()
  1107.         Invalidate()
  1108.     End Sub
  1109.     Protected Overrides Sub OnMouseLeave(e As EventArgs)
  1110.         MyBase.OnMouseLeave(e)
  1111.         _State = MouseState.None
  1112.         Invalidate()
  1113.     End Sub
  1114.  
  1115. #End Region
  1116.  
  1117. #End Region
  1118.  
  1119.     Sub New()
  1120.         SetStyle(ControlStyles.AllPaintingInWmPaint Or ControlStyles.UserPaint Or _
  1121.                  ControlStyles.ResizeRedraw Or ControlStyles.OptimizedDoubleBuffer Or _
  1122.                  ControlStyles.SupportsTransparentBackColor, True)
  1123.         DoubleBuffered = True
  1124.         BackColor = Color.Transparent
  1125.         TB = New Windows.Forms.TextBox
  1126.         TB.Font = New Font("Arial", 9)
  1127.         TB.Text = Text
  1128.         TB.BackColor = Color.FromArgb(40, 40, 40)
  1129.         TB.ForeColor = Color.White
  1130.         TB.MaxLength = _MaxLength
  1131.         TB.Multiline = _Multiline
  1132.         TB.ReadOnly = _ReadOnly
  1133.         TB.UseSystemPasswordChar = _UseSystemPasswordChar
  1134.         TB.BorderStyle = BorderStyle.None
  1135.         TB.Location = New Point(5, 5)
  1136.         TB.Width = Width - 10
  1137.  
  1138.         TB.Cursor = Cursors.IBeam
  1139.  
  1140.         If _Multiline Then
  1141.             TB.Height = Height - 11
  1142.         Else
  1143.             Height = TB.Height + 11
  1144.         End If
  1145.  
  1146.         AddHandler TB.TextChanged, AddressOf OnBaseTextChanged
  1147.         AddHandler TB.KeyDown, AddressOf OnBaseKeyDown
  1148.     End Sub
  1149. #End Region
  1150.  
  1151.     Protected Overrides Sub OnPaint(e As PaintEventArgs)
  1152.         MyBase.OnPaint(e)
  1153.         Dim G = e.Graphics
  1154.         G.Clear(Color.FromArgb(40, 40, 40))
  1155.         G.DrawRectangle(New Pen(Color.FromArgb(24, 24, 24)), New Rectangle(0, 0, Width - 1, Height - 1))
  1156.         G.DrawRectangle(New Pen(Color.FromArgb(48, 48, 48)), New Rectangle(1, 1, Width - 3, Height - 3))
  1157.         G.FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(0, 0, 1, 1))
  1158.         G.FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(0, Height - 1, 1, 1))
  1159.         G.FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(Width - 1, 0, 1, 1))
  1160.         G.FillRectangle(New SolidBrush(Color.FromArgb(35, 35, 35)), New Rectangle(Width - 1, Height - 1, 1, 1))
  1161.     End Sub
  1162. End Class
Add Comment
Please, Sign In to add comment