Bitmap bitmap = new Bitmap(250, 110);
Graphics graphics = Graphics.FromImage(bitmap);
SolidBrush b = new SolidBrush(System.Drawing.Color.Red);
graphics.FillRectangle(b, 0f, 0f, 100, 100);
graphics.D…...Drawing for .NET APIs and it works fine. Please...tested in a project with .NET Framework 4.0 on Windows8. e.g. Sample...