Date: 02-16-2022
Return to Index
'Compilable Example: (Jose Includes)
created by gbSnippets
#Compiler PBWin 9, PBWin 10
#Compile Exe
#Dim All
%Unicode=1
#Include "Win32API.inc"
Global hDlg As Dword
Function PBMain() As Long
Dialog New Pixels, 0, "Layered Window",300,50,200,100, %WS_OverlappedWindow, %WS_Ex_Layered To hDlg
Dialog Set Color hDlg, %Black, %White '-2
Control Add Graphic, hDlg, 500, "World", 10,10,50,50
Graphic Attach hDlg, 500
Graphic Color %Black, %White
Graphic Clear
Graphic Print "Hello"
Dialog Show Modal hDlg Call DlgProc
End Function
CallBack Function DlgProc() As Long
Local PS As PaintStruct, hDC As Dword
Select Case Cb.Msg
Case %WM_InitDialog
SetLayeredWindowAttributes(hDlg, %White, 255, %LWA_ALPHA Or %LWA_Colorkey)
End Select
End Function
'gbs_01292
'Date: 05-11-2013
http://www.garybeene.com/sw/gbsnippets.htm