This program from Eddie which makes any window gradually disappear works with standard 32 bit FTN95 but needs something with LOC in /64 case. How to make it working in 64 bits FTN95?
use clrwin
integer, external :: SetWindowOpacity
integer (7) ihw1, iop
i = winio@('%sv%ww&')
I = winio@('%ca[Finished] %ff %ff&')
I = winio@('%cn Task finished OK %ff&')
I = winio@('%cn %ff&')
i = winio@('%hw%lw', ihw1, ilw1)
do i=0,155,2; call temporary_yield@;
iOp=255*exp(-(i**2/255.**2));ii=SetWindowOpacity(ihw1,iop);
call sleep1@(0.03);
enddo
ilw1 = 0; call WINDOW_UPDATE@(ilw1)
END
!------------------------------------------------------------------
integer function SetWindowOpacity(hWnd, alpha)
! Set opacity level for a window (call after window creation) -
! automatically sets appropriate extended style and sets opacity
! from 0 (transparent) to 255 (no transparency).
use mswin
integer, parameter:: WS_EX_LAYERED = Z'00080000'
integer, parameter:: LWA_COLORKEY = Z'00000001'
integer, parameter:: LWA_ALPHA = Z'00000002'
STDCALL SetLayeredWindowAttributes 'SetLayeredWindowAttributes' &
& (VAL, VAL, VAL, VAL) : LOGICAL*4
integer (7), intent(in) :: hWnd
integer (KIND=7), intent(in):: alpha
integer:: attrib, i
logical aaaaaa
! Get current window attributes to ensure WS_EX_LAYERED extended style is set
attrib = GetWindowLong(hWnd, GWL_EXSTYLE)
if (IAND(attrib,WS_EX_LAYERED) /= WS_EX_LAYERED) then
i = SetWindowLong(hWnd, GWL_EXSTYLE, IOR(attrib,WS_EX_LAYERED))
end if
! Set layered window alpha value
aaaaaa = SetLayeredWindowAttributes &
& (hWnd, 0, CORE1(LOC(alpha)), LWA_ALPHA)
SetWindowOpacity = 1
end function SetWindowOpacity