private void updateText() { if (texture == null) { return; } texture.Clear(backgroundColor); if (shadow) { texture.DrawString(text, font, new SolidBrush(Color.Black), new PointF(1, 1)); } TextSize = texture.DrawString(text, font, new SolidBrush(textColor), PointF.Empty); }