-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTransSplashText.ahk
More file actions
executable file
·68 lines (65 loc) · 2.97 KB
/
Copy pathTransSplashText.ahk
File metadata and controls
executable file
·68 lines (65 loc) · 2.97 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; Splash Text with a transparent background. ;;;
;;; This is accomplished by using a gui window with a transcolor set. The parameters to pass to;;;
;;; the function are as follows. A demonstration script is included at the bottom of this page. ;;;
;;; ;;;
;;; Usage: TransSplashText_On(Text) TransSplashText_Off() ;;;
;;; ;;;
;;; You may also pass the following parameters to the On command. ;;;
;;; ;;;
;;; TransSplashText_On(Text,Font,TC,SC,TS,xPos,yPos,TimeOut) ;;;
;;; ;;;
;;; Text = Text to display, Font = Example "Arial", TC = Color ;;;
;;; SC = Shadow Color, use "0" for no shadow, TS = Font Size ;;;
;;; xPos and yPos = The screen position to display the text. ;;;
;;; TimeOut = Milliseconds to display the text, "0" is infinite, Meaning splashtext stays ;;;
;;; until TransSplashText_Off() is used. ;;;
;;; ;;;
;;; Only the parameters to change need to be used as long as the other parameters are empty ;;;
;;; strings. Example, the following would only change the shadow color, other parameters ;;;
;;; still retain their default values. ;;;
;;; TransSplashText_On(Text,"","","Red","","","","") ;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
TransSplashText_On(Text="",Font="",TC="",SC="",TS="",xPos="",yPos="",TimeOut="")
{
If Text =
Text = TransSplashText
If Font =
Font = Tahoma
If TC =
TC = Black
If SC =
SC = White
If TS =
TS = 20
If xPos =
xPos = Center
If yPos =
yPos = Center
If TimeOut =
TimeOut = 0
If SC != 0
{
Gui, 99:Font, S%TS% C%SC%, %Font%
Gui, 99:Add, Text, x12 y12, %Text%
}
Gui, 99:Font, S%TS% C%TC%, %Font%
Gui, 99:Add, Text, x10 y10 BackgroundTrans, %Text%
Gui, 99:Color, EEAA99
Gui, 99:+LastFound -Caption +AlwaysOnTop +ToolWindow
WinSet, TransColor, EEAA99
Gui, 99:Show, x%xPos% y%yPos% AutoSize NoActivate, TransSplashTextWindow
If TimeOut != 0
{
SetTimer, TextOff, %TimeOut%
Return
TextOff:
TransSplashText_Off()
Return
}
}
TransSplashText_Off()
{
Gui, 99:Destroy
SetTimer, TextOff, Off
}