private void DrawText(byte opacity, ImageWithDeviceContext destImage) { Rectangle textBounds = this.TextBounds; TitleRenderer.DrawText(Text, destImage, textBounds.Location, textBounds.Size, opacity, TextColorBrush, StringFormat, Font); }
protected override void DrawBackground(ImageWithDeviceContext destImage) { base.DrawBackground(destImage); if (Text.Length > 0) { Rectangle textBounds = Bounds; TitleRenderer.DrawText(Text, destImage, new Point(RealX, RealY), textBounds.Size, Opacity, TextColorBrush, StringFormat, Font); } }