protected void DrawText(Graphics g)
{
if (this.Enabled)
{
using (SolidBrush brush = new SolidBrush(this.FocusLinkColor))
{
g.DrawString(this.Text, this.Font, brush, this.TextRect, this.StringFormat);
}
}
else
{
// draw disable text the same way as a Label
ControlPaint.DrawStringDisabled(g, this.Text, this.Font, this.DisabledColor, (RectangleF) this.TextRect, this.StringFormat);
}
}