Ejemplo n.º 1
0
 protected override void OnPaint(PaintEventArgs e)
 {
     if (!Enabled)
     {
         PaintHelper.DrawDisabledFilter(e.Graphics, this);
     }
 }
Ejemplo n.º 2
0
        protected override void OnPaint(PaintEventArgs e)
        {
            using (Pen borderPen = new Pen(BorderColor, BorderWidth))
                e.Graphics.DrawRectangle(borderPen, GeometryHelper.ApplyPadding(ClientRectangle, new Padding(BorderWidth / 2)));

            DrawAndMeasureText(e.Graphics);

            if (caretVisible)
            {
                DrawCaret(e.Graphics);
            }

            if (!Enabled)
            {
                PaintHelper.DrawDisabledFilter(e.Graphics, this);
            }
        }
Ejemplo n.º 3
0
 protected override void OnPaintBackground(PaintEventArgs e)
 {
     PaintHelper.FillWithParentBackground(e.Graphics, this);
 }