[win32] - how make the form transparent?
Jul 17, 2014 at 12:55pm UTC
i have 1 function for make the form transparent:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
void settransparency(HWND handlewindow,color backcolor, std::uint8_t Transperancy=255)
{
long wAttr = GetWindowLong(handlewindow, GWL_EXSTYLE);
if (backcolor==-1)
{
SetWindowLong(handlewindow, GWL_EXSTYLE, wAttr | WS_EX_LAYERED);
SetLayeredWindowAttributes(handlewindow, NULL, Transperancy, 0x02);
}
else
{
SetWindowLong(handlewindow, GWL_EXSTYLE, wAttr | WS_EX_LAYERED);
SetLayeredWindowAttributes(handlewindow, backcolor, Transperancy, 0x02 | 0X01);
}
}
the form stays transparent, but i lose some actions :(
is there another way for make the form transparent?(just hide the backcolor)
Jul 19, 2014 at 9:00am UTC
what a diference between transparent form and shaped form?
the transparent form is only for see(and not click) what is on back? and the shaped form can let us click on back?
Topic archived. No new replies allowed.