Sign in to follow this  
Followers 0
robertcollier4

Monolog Modeless Transparent Message Box Auto Fade Out - any UDFs?

8 posts in this topic

#1 ·  Posted (edited)

Does anyone know of any existing pieces of code or UDFs that could achieve the following without me having to rewrite this from scratch? I'm looking for a way to display transparent overlay messages on the screen that would automatically fade out after 5 seconds or after any keyboard-mouse activity. Further, it would be nice if I could click on a tray and see a window with a log of all previously displayed messages (in case I was away from the computer and want to check if any messages popped up which I might have missed).

 

The design and user interface experience comes from:

http://www.azarask.in/blog/post/monolog_boxes_and_transparent_messages/

http://humanized.com/weblog/2006/09/11/monolog_boxes_and_transparent_messages/

 

 

It’s simply a large and translucent message that’s displayed over the contents of your screen. They fade away when the user takes any action (like typing or moving the mouse). In practice, the message is both noticeable yet unobtrusive. And because the message is transparent, you can see what’s beneath...

 

60236944.gif

Edited by robertcollier4

Share this post


Link to post
Share on other sites



It's feasible. If no one link an existing UDF I can make it for you. (yes I said make it as I'm friendly atm)


 

OS : Win XP SP2 (32 bits) / Win 7 SP1 (64 bits) / Win 8 (64 bits) | Autoit version: latest stable / beta.
Hardware : Intel(R) Core(TM) i5-2400 CPU @ 3.10Ghz / 8 GiB RAM DDR3.

My UDFs : Skype UDF | TrayIconEx UDF | GUI Panel UDF | Excel XML UDF | Is_Pressed_UDF

My Projects : YouTube Multi-downloader | FTP Easy-UP | Lock'n | WinKill | AVICapture | Skype TM | Tap Maker | ShellNew | Scriptner | Const Replacer | FT_Pocket | Chrome theme maker

My Examples : Capture toolIP Camera | Crosshair | Draw Captured Region | Picture Screensaver | Jscreenfix | Drivetemp | Picture viewer

My Snippets : Basic TCP | Systray_GetIconIndex | Intercept End task | Winpcap various | Advanced HotKeySet | Transparent Edit control

 

Share this post


Link to post
Share on other sites

I wasn't able to find anything like this existing from searching. What would be the best way, GDI?

Share this post


Link to post
Share on other sites

Not necessarily. I will check it out.


 

OS : Win XP SP2 (32 bits) / Win 7 SP1 (64 bits) / Win 8 (64 bits) | Autoit version: latest stable / beta.
Hardware : Intel(R) Core(TM) i5-2400 CPU @ 3.10Ghz / 8 GiB RAM DDR3.

My UDFs : Skype UDF | TrayIconEx UDF | GUI Panel UDF | Excel XML UDF | Is_Pressed_UDF

My Projects : YouTube Multi-downloader | FTP Easy-UP | Lock'n | WinKill | AVICapture | Skype TM | Tap Maker | ShellNew | Scriptner | Const Replacer | FT_Pocket | Chrome theme maker

My Examples : Capture toolIP Camera | Crosshair | Draw Captured Region | Picture Screensaver | Jscreenfix | Drivetemp | Picture viewer

My Snippets : Basic TCP | Systray_GetIconIndex | Intercept End task | Winpcap various | Advanced HotKeySet | Transparent Edit control

 

Share this post


Link to post
Share on other sites

robertcollier4,

While FireFox is busy, have you seen my Notify UDF? Although not exactly what you are looking for it might be suitable with a bit of modification - and I am also feeling friendly and ready to do it! ;)

M23


Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

Here you go :

 

#include <WindowsConstants.au3>
#include <StaticConstants.au3>

#region GUI
Global $hGUI_Main = GUICreate("")

Global $hGUI_Child = GUICreate("MyGUI", 400, 70, -1, -1, $WS_POPUP, $WS_EX_TOPMOST, $hGUI_Main)
GUISetBkColor(0x000000, $hGUI_Child)

Local $iMyLabel = GUICtrlCreateLabel("Good news Dave, I can do that.", 0, 0, 400, 70, BitOR($SS_CENTER, $SS_CENTERIMAGE))
GUICtrlSetColor($iMyLabel, 0xFFFFFF)
GUICtrlSetFont($iMyLabel, 17)

_GuiRoundCorners($hGUI_Child, 0, 0, 7, 7)

WinSetTrans($hGUI_Child, "", 0)
GUISetState(@SW_SHOW, $hGUI_Child)
#endregion

For $i = 0 To 150 Step 8
    WinSetTrans($hGUI_Child, "", $i)
    Sleep(10)
Next

AdlibRegister("_Exit", 5000)

While 1
    Sleep(1000)
WEnd

Func _GuiRoundCorners($hWnd, $iLeftRect, $iTopRect, $iWidthEllipse, $iHeightEllipse)
    Local $aPos = 0, $aRet = 0

    $aPos = WinGetPos($hWnd)

    $aRet = DllCall("gdi32.dll", "long", "CreateRoundRectRgn", "long", $iLeftRect, "long", $iTopRect, "long", $aPos[2], "long", $aPos[3], "long", $iWidthEllipse, "long", $iHeightEllipse)
    If Not @error And $aRet[0] Then
        $aRet = DllCall("user32.dll", "long", "SetWindowRgn", "hwnd", $hWnd, "long", $aRet[0], "int", 1)
        If Not @error And $aRet[0] Then Return 1
    EndIf

    Return 0
EndFunc   ;==>_GuiRoundCorners

Func _Exit()
    AdlibUnRegister("_Exit")

    For $i = 150 To 0 Step -4
        WinSetTrans($hGUI_Child, "", $i)
        Sleep(10)
    Next

    GUIDelete($hGUI_Main)

    Exit
EndFunc
Edit: Added indents.

Note: Don't forget to take a look at Melba's UDF, you should find some good inspirations ;)

Br, FireFox.

Edited by FireFox
2 people like this

 

OS : Win XP SP2 (32 bits) / Win 7 SP1 (64 bits) / Win 8 (64 bits) | Autoit version: latest stable / beta.
Hardware : Intel(R) Core(TM) i5-2400 CPU @ 3.10Ghz / 8 GiB RAM DDR3.

My UDFs : Skype UDF | TrayIconEx UDF | GUI Panel UDF | Excel XML UDF | Is_Pressed_UDF

My Projects : YouTube Multi-downloader | FTP Easy-UP | Lock'n | WinKill | AVICapture | Skype TM | Tap Maker | ShellNew | Scriptner | Const Replacer | FT_Pocket | Chrome theme maker

My Examples : Capture toolIP Camera | Crosshair | Draw Captured Region | Picture Screensaver | Jscreenfix | Drivetemp | Picture viewer

My Snippets : Basic TCP | Systray_GetIconIndex | Intercept End task | Winpcap various | Advanced HotKeySet | Transparent Edit control

 

Share this post


Link to post
Share on other sites

#7 ·  Posted (edited)

Fantastic, thanks guys!!

Melba's UDF seems exactly the kind of thing I was looking for except that it does not allow for a transparent background, the notification seems to have a small border around the edge, and the notification box cannot be rounded.

With Firefox's code, it looks exactly the way I wanted (and as described in Aza Raskin's article). Thanks!

Edited by robertcollier4

Share this post


Link to post
Share on other sites

You are welcome :)


 

OS : Win XP SP2 (32 bits) / Win 7 SP1 (64 bits) / Win 8 (64 bits) | Autoit version: latest stable / beta.
Hardware : Intel(R) Core(TM) i5-2400 CPU @ 3.10Ghz / 8 GiB RAM DDR3.

My UDFs : Skype UDF | TrayIconEx UDF | GUI Panel UDF | Excel XML UDF | Is_Pressed_UDF

My Projects : YouTube Multi-downloader | FTP Easy-UP | Lock'n | WinKill | AVICapture | Skype TM | Tap Maker | ShellNew | Scriptner | Const Replacer | FT_Pocket | Chrome theme maker

My Examples : Capture toolIP Camera | Crosshair | Draw Captured Region | Picture Screensaver | Jscreenfix | Drivetemp | Picture viewer

My Snippets : Basic TCP | Systray_GetIconIndex | Intercept End task | Winpcap various | Advanced HotKeySet | Transparent Edit control

 

Share this post


Link to post
Share on other sites

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
Sign in to follow this  
Followers 0