Please enable JavaScript to view this site.

thinBasic Help Manual

Navigation: ThinBASIC Modules > UI (User Interface) > Windows API

Win_SetLayeredWindowAttributes

Scroll Prev Top Next More

* * HELP & MANUAL PREMIUM PACK 4 DEMO VERSION * *

This documentation was styled with a demo skin from the Premium Pack 4 add-on for Help & Manual. The contents of the skin are encrypted and not configurable. You can only publish HM projects with this skin. You cannot edit it or change it.

This version is copyright and may only be used for local testing purposes. It may not be distributed.

Please purchase the full version of the Premium Pack to get the configurable skins and remove this notice. The package will also include the Toolbox configuration utility for Premium Pack skins.

 

Description

 

Sets the opacity and transparency color key of a layered window.

 

Syntax

 

n = Win_SetLayeredWindowAttributes(hWnd, crKey, bAlpha, dwFlags)

 

Returns

 

Number.

 

Parameters

 

Name

Type

Optional

Meaning

hWnd

Number

No

Handle to the layered window.

A layered window is created by specifying %WS_EX_LAYERED when creating the window or by setting %WS_EX_LAYERED via WIN_SetWindowLong after the window has been created.

crKey

Number

No

Specifies the transparency color key to be used when composing the layered window. Use RGB function to compose requested color

All pixels painted by the window in this color will be transparent.

bAlpha

Number

No

Alpha value used to describe the opacity of the layered window.

When bAlpha is 0, the window is completely transparent.

When bAlpha is 255, the window is opaque.

dwFlags

Number

No

Specifies an action to take. This parameter can be one or more of the following values:

 

%LWA_COLORKEY

Use crKey as the transparency color.

%LWA_ALPHA

Use bAlpha to determine the opacity of the layered window.

 

 

Remarks

 

For additional info, please refer to MS documentation at: http://msdn.microsoft.com/en-us/library/ms633540(VS.85).aspx

 

Restrictions

 

See also

 

Examples

 

Created with Help+Manual 8 and styled with Premium Pack Version 4 © by EC Software