Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Can I get BMP picture for under Form region?
Message
From
24/01/2001 05:33:38
 
 
To
23/01/2001 06:08:25
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Miscellaneous
Thread ID:
00467180
Message ID:
00467789
Views:
12
I have not used Larrys Millers formtrans class but if it uses the new Windows 2000 layered windows functions (SetLayeredWindowAttributes etc.) then you can specify colour keying (in dwFlags parameter) instead of alpha blending. This has the effect of treating certain colours as totally transparent instead of working out the percentage to blend.

The other technique is to use Windows Regions to create a non-rectangular window. The following skeleton code shows you how to turn the Visual FoxPro client into an ellipse.
LOCAL lhWnd
LOCAL lhRgn

DECLARE LONG FindWindowA IN WIN32API STRING class, STRING title
DECLARE LONG CreateEllipticRgn in WIN32API INTEGER left, INTEGER top, INTEGER right, INTEGER bottom
DECLARE INTEGER SetWindowRgn in WIN32API LONG hWnd, LONG hRgn, INTEGER redraw

lhWnd = FindWindowA(0, _VFP.Caption)
lhRgn = CreateEllipticRgn(1, 1, _VFP.Width, _VFP.Height)

? SetWindowRgn(lhWnd, lhRgn, 1)
Windows regions can be combined throught the CombineRgn() function to create more complex regions.

HTH
Neil
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform