Draw a Fill Rectangle with low opacity
问题 I a have a PictureBox with a picture in a Windows Form application in C# language.I want draw a FillRectangle in some location of picturebox.but i also need to see picture of picture box.how can i draw this rectangle with low opacity to see image of picturebox ? 回答1: Do you mean: using (Graphics g = Graphics.FromImage(pb.Image)) { using(Brush brush = new SolidBrush(your_color)) { g.FillRectangle(brush , x, y, width, height); } } or you can use Brush brush = new SolidBrush(Color.FromArgb(alpha