|
-
Feb 8th, 2011, 01:12 PM
#1
Thread Starter
Member
PictureBox and transparency
Folks,
This sort of question comes up once in a while. I've seen similar topics.
I want to make a portion of PictureBox transparent. The intent is to put a few of these PictureBoxes on a form which is itself transparent. Images aren't overlapping. The disjointed partially transparent PictureBoxes will look as if they were "flying" in formation.
My images are drawn with only a few colors, so I can use fuchsia as key color for transparency. I was really excited when I found out about Form.TransparencyKey . Thinking wishfully, I've looked for something similar in the PictureBox control. May be it's there under a different name, but I couldn't find it yet.
I know that I can write a fairly straightforward function that will generate a region, provided a bitmap and a color key. Then this region can be assigned to Control.Region property. But is there a standard picture-box-type control that has a built-in feature like Form.TransparencyKey ?
Color.Transparent constant does exist. Is there a way of somehow selecting Color.Transparent and drawing with it?
Any suggestion, insight or reference is really appreciated!
Cheers,
- Nick
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|