WindowlessControls.WindowlessRectangle.OnPaint C# (CSharp) Method

OnPaint() protected method

protected OnPaint ( WindowlessPaintEventArgs e ) : void
e WindowlessPaintEventArgs
return void
        protected override void OnPaint(WindowlessPaintEventArgs e)
        {
            if (myColor != Color.Transparent)
            {
                if (myFilled.Value)
                    e.Graphics.FillRectangle(myBrush, e.Origin.X, e.Origin.Y, ClientWidth, ClientHeight);
                else
                    e.Graphics.DrawRectangle(myPen, e.Origin.X, e.Origin.Y, ClientWidth - 1, ClientHeight - 1);
            }
        }