Jump to content

Recommended Posts

Posted

#include <GUIConstants.au3>
AutoItSetOption("GUIResizeMode",802)
Global $oldwidth = 500, $oldheight = 100, $ontop = 1

GUICreate("Transparent Test",500,100,-1,-1,$WS_POPUP + $WS_SIZEBOX)
    GUICtrlCreateLabel("",28,28,32,20,$SS_BLACKFRAME)
    $trans = GUICtrlCreateSlider(60,37,73,18,$TBS_NOTICKS)
    GUICtrlSetLimit(-1,255,80)
    GUICtrlSetData(-1,220)
    GUICtrlCreateLabel("Transparency:",70,25,100,12)
    GUICtrlSetFont(-1,7)
    $top = GUICtrlCreateCheckbox('"Always On Top"',28,50)
    GUICtrlSetState(-1,1)
GUISetState()
WinSetTrans("Transparent Test","",220)
WinSetOnTop("Transparent Test","",1)

do
$msg = GUIGetMsg()
    If $msg = $trans then WinSetTrans("Transparent Test","",GUICtrlRead($trans))

Alright why isn't this working? :R

[center]Cookyx.com :: Simple LAN Chat[/center]

Posted

So

#include <GUIConstants.au3>

AutoItSetOption("GUIResizeMode",802)

Global $oldwidth = 500, $oldheight = 100, $ontop = 1

GUICreate("Transparent Test",500,100,-1,-1,$WS_POPUP + $WS_SIZEBOX)

GUICtrlCreateLabel("",28,28,32,20,$SS_BLACKFRAME)

$trans = GUICtrlCreateSlider(60,37,73,18,$TBS_NOTICKS)

GUICtrlSetLimit(-1,255,80)

GUICtrlSetData(-1,220)

GUICtrlCreateLabel("Transparency:",70,25,100,12)

GUICtrlSetFont(-1,7)

$top = GUICtrlCreateCheckbox('"Always On Top"',28,50)

GUICtrlSetState(-1,1)

GUISetState()

WinSetTrans("Transparent Test","",220)

WinSetOnTop("Transparent Test","",1)

do

$msg = GUIGetMsg()

If $msg = $trans then WinSetTrans("Transparent Test","",GUICtrlRead($trans))

works fine? :P

[center]Cookyx.com :: Simple LAN Chat[/center]

Posted (edited)

well i got it but theres one problem i couldn't fix don't have time to mess around, but here ya go

#include <GUIConstants.au3>
$Form1 = GUICreate("Transparent Test", 269, 58, 194, 125)
$Slider1 = GUICtrlCreateSlider(0, 8, 265, 49)
GUICtrlSetLimit(-1,255)
GUICtrlSetData(-1,220)
GUISetState()
While 1
WinSetTrans("Transparent Test","", GUICtrlRead($Slider1))
$msg = GuiGetMsg()
    Select
    Case $msg = $GUI_EVENT_CLOSE
        ExitLoop
     EndSelect
WEnd
Edited by Vicks
[s]Autoit[/s]
Posted

So

#include <GUIConstants.au3>

AutoItSetOption("GUIResizeMode",802)

Global $oldwidth = 500, $oldheight = 100, $ontop = 1

GUICreate("Transparent Test",500,100,-1,-1,$WS_POPUP + $WS_SIZEBOX)

GUICtrlCreateLabel("",28,28,32,20,$SS_BLACKFRAME)

$trans = GUICtrlCreateSlider(60,37,73,18,$TBS_NOTICKS)

GUICtrlSetLimit(-1,255,80)

GUICtrlSetData(-1,220)

GUICtrlCreateLabel("Transparency:",70,25,100,12)

GUICtrlSetFont(-1,7)

$top = GUICtrlCreateCheckbox('"Always On Top"',28,50)

GUICtrlSetState(-1,1)

GUISetState()

WinSetTrans("Transparent Test","",220)

WinSetOnTop("Transparent Test","",1)

do

$msg = GUIGetMsg()

If $msg = $trans then WinSetTrans("Transparent Test","",GUICtrlRead($trans))

works fine? :P

obviously an "Until" is needed

Until $msg = $GUI_EVENT_CLOSE

8)

NEWHeader1.png

Posted

Transparency is not cheap. Think about it, it takes two images (background, foreground) and blends them together.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...