ARCed.Controls.GraphicsDeviceControl.PaintUsingSystemDrawing C# (CSharp) Метод

PaintUsingSystemDrawing() защищенный Метод

If we do not have a valid graphics device (for instance if the device is lost, or if we are running inside the Form designer), we must use regular System.Drawing method to display a status message.
protected PaintUsingSystemDrawing ( Graphics graphics, string text ) : void
graphics System.Drawing.Graphics
text string
Результат void
        protected virtual void PaintUsingSystemDrawing(Graphics graphics, string text)
        {
            graphics.Clear(Color.CornflowerBlue);

            using (Brush brush = new SolidBrush(Color.Black))
            {
                using (var format = new StringFormat())
                {
                    format.Alignment = StringAlignment.Center;
                    format.LineAlignment = StringAlignment.Center;

                    graphics.DrawString(text, Font, brush, ClientRectangle, format);
                }
            }
        }