Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <StringSize.au3>
- Func _GUIToolTip($text,$Width,$height,$GuiBkColor,$textColor,$timeout=1)
- Local $x = ($Width-StringLen($text)*4.5-StringLen($text)*4.5/2)/2-0.5
- If $x < 2 Then $x = 2
- Local $y = $height/2 - _StringSize($text)[3]/2
- Local $guitooltip = GUICreate("",$Width,$height,-1,5,BitOR(0x00800000,0x80000000), BitOR(0x00000008,0x00000080))
- GUISetBkColor($GuiBkColor,$guitooltip)
- GUICtrlCreateLabel($text, $x, $y , $Width, $height)
- GUICtrlSetFont(-1, 10, 700,0, "Tahoma")
- GUICtrlSetColor(-1,$textColor)
- GUISetState(@SW_SHOW)
- Sleep($timeout&"000")
- GUIDelete($guitooltip)
- EndFunc
- _GUIToolTip("Gui Tooltip Created By TrunghieuTH10",250,18,0xFFFFFF,0x0000FF,3)
- _GUIToolTip("TrunghieuTH10",250,18,0xFFFFFF,0x0000FF,3)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement