Making windows form curvy

dotnetman

Newcomer
Joined
Jan 4, 2005
Messages
19
Friends,
We have created a media player and now we would want to add graphics (skins) to it. Our graphics artist has created images for the same. However, the corners of the player need to be curvy and the images he has supplied have curved edges. So, is there a way to make our form corners curved? I am trying AddClosedCurve but I did not find a lot of documentation on its usage. Pls let me know if you know how to do this :)

Thank you,
Praveen
 
Forms support a transparency key. Any color on the form that matches Form.TransparencyKey will be drawn transparently. This makes skinning real quick and easy. Just pick a color, say magenta, and in the background image, draw transparent areas as magenta. In the form's property, set the TransparencyKey to magenta. Pow! Nifty skins.
 
I have a picture that I have placed on the form. It is taking the picture's back color and showing its square edges. Is there a way to make the picture transparent?
 
Well, transparencykey works only on the form and not for the controls that you place on the form. For that, I will have to set the image(skin) as the form's background image. However, the image that I would want represents just a small part of the entire form (title bar), which is why I added it within a picturebox and placed the picturebox on the form. Now, there is no way that the picturebox would become transparent, even if I use the transparencykey color on the picturebox. phew. this is so complicated to explain!!!
 
I certainly did not have the same problem. I took a form, added a picture box, assigned it an image that contained large portions of white, set the transparency key to white, and the white regions became transparent at runtime. Make sure that you have the transparency key set to exactly the right color, and of course, use a lossless image format for you skin.

If you are assigning the image at runtime, try to set the transparency key after you assign the image.
 
I don't remember where I found this but it is quite possibly the sweetest thing I have ever seen. I also haven't had a chance to play with it much, but perhaps it will help you with some of your problems..
 

Attachments

Last edited by a moderator:
Back
Top