Clear Graphics Object to Black or other RGB
I am a rank beginner in C#. I am currently using this code:
objGraphics.Clear(SystemColors.Control);
What I want to do is Clear this object to black (or some other RGB color), and I'm stumped as to how to replace the SystemColors.Control with, preferably, an RGB color spec. I'd probably want to clear to bla开发者_如何学Gock most of the time. Any help will be much appreciated!
objGraphics.Clear(Color.Black);
or
objGraphics.Clear(Color.FromArgb(r, g, b));
Color black = Color.FromName("Black");
objGraphics.Clear(black);
精彩评论