Created
September 4, 2013 21:24
-
-
Save anonymous/6443058 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#SingleInstance force | |
; Example: On-screen display (OSD) via transparent window: | |
CustomColor = FF8080 ; The transparent background color of the window, set this to something close to your text colour to avoid white highlighting | |
Gui +LastFound +AlwaysOnTop -Caption +ToolWindow +E0x20 ; +ToolWindow avoids a taskbar button and an alt-tab menu item. | |
Gui, Color, %CustomColor% | |
Gui, Font, s50 ; Set a large font size (12-point). | |
errorTail := "hello" | |
Gui, Add, Text, vMyText cRed , %errorTail% ; add it, colour is Red, R5 sets 5 rows | |
; choose one of these lines, first one show just the text, second one has a background for readability | |
WinSet, TransColor, %CustomColor% 200 ; Make all pixels of this color transparent and make the text itself translucent (250) | |
;Winset, Transparent, 150 | |
SetTimer, UpdateOSD, 1000 ; 1 second timer set here | |
Gui, Show, x0 y0 NoActivate ; Set the x and y position. NoActivate avoids deactivating the currently active window. | |
return | |
UpdateOSD: ; the repeated timer routine | |
GuiControl,, MyText, %errorTail% | |
return | |
esc:: | |
gui,destroy | |
exitapp |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment