...obtain a transparent Form without coding (Delphi6)?
|
Autor:
JodeQa |
[ Print tip
] | | |
{
this is very simple, actually .. you don't need to coding any single line :)
practically, you just have to set 3 TForm properties
1. Color
2. TransparentColorValue
3. TransparentColor
For example, just put 1 TButton on the form, then set the form properties :
1. Color := clBlue
2. TransparentColorValue := clBlue
3. TransparentColor := True
better set the TForm.BorderStyle to bsNone
RUN .. you'll see only TButton
logically, you must set TForm.Color same with TForm.TransparentColorValue
Next Example, let s create 2 TShape
+-----------+
| clWhite
| |
| +----------+
| | clBlue |
+-----| |
| |
| |
+----------+
then set the form properties :
1. Color := clBlue
2. TransparentColorValue := clBlue
3. TransparentColor := True
+-----------+
| clWhite
| |
| +-----+
| |
+-----+
you can also use Bitmap/picture, but it a litte bit tricky, you need a color picker / eye dropper tool,
to find out the color value for the color i wish to 'remove'
i use CorelPhotoPaint EyeDropper tool
after you find the RGB color value, repeat the steps
tips : if you don't know how to set the RGB value into your TForm Properties
double click on the "white space" in TForm.Color / TForm.TransparentColorValue property value
it will bring you Windows color Picker Dialog,
then, just RUN your program :)
}
|