This article provides an approach to a Transparent Control that draws an ellipse with real transparent background and a brush that supports transparent colors.
Below sample project is included in the ZIP file. In addition, you will find a file that contains the control TranspControl.ddl. It was made and based on technique presented in this article.To make a transparent control you may create a default control and proceed with the following steps:
1. Add the transparent style to the control window.
Protected override CreateParams CreateParams{get{CreateParams cp = base.CreateParams;cp.ExStyle |= 0x20;return cp;}}
Protected override void OnPaintBackground(PaintEventArgs e){// do nothing}
Protected override void OnMove(EventArgs e){RecriateHandle();}
You need to be a premium member to use this feature. To access it, you'll have to upgrade your membership.
Become a sharper developer and jumpstart your career.
$0
$
. 00
monthly
For Basic members:
$20
For Premium members:
$45
For Elite members: