How?
copyraw
	
Now this results in a tiny GUI that displays the link in black and works (somewhat).  If you copy the above code into an AutoHotkey file, you'll find this is remarkably temperamental.  If the user is too quick with their mouseovers and mouseouts, then the GUI will sometimes leave the link as blue despite the mouse cursor not being anywhere near it.#NoEnv
SendMode Input
SetWorkingDir %A_ScriptDir%
#SingleInstance Force
; ******************************************************************************
; CREATE GUI
Gui, Color, FFFFFF
Gui, +OwnDialogs +SysMenu +Caption +0x800000
Gui, Add, Text, gOpenDocumentation, Open the documentation
Gui, Show, w600 h700, %ThisProgramName%
WinSet, AlwaysOnTop, On, %ThisProgramName%
OnMessage(0x200, "WM_MOUSEMOVE")
Return
OpenDocumentation:
   MsgBox, Oh no you clicked on me!
Return
; ******************************************************************************
; MOUSE MOVEMENT (Tooltips)
WM_MOUSEMOVE()
{
    static CurrControl, PrevControl
    CurrControl := A_GuiControl
	If (CurrControl"" OR PrevControl"") {
		If (CurrControl  PrevControl)
		{
			Gui, Font, cBlue underline
			GuiControl, Font, %CurrControl%
			PrevControl:=CurrControl
		} else {
			Gui, Font, cBlack norm
			GuiControl, Font, %CurrControl%
			PrevControl:=""
		}
	}
}
; ******************************************************************************
	GuiClose:
	close:
		Gui, Destroy
		ExitApp
	- #NoEnv
- SendMode Input
- SetWorkingDir %A_ScriptDir%
- #SingleInstance Force
- ; ******************************************************************************
- ; CREATE GUI
- Gui, Color, FFFFFF
- Gui, +OwnDialogs +SysMenu +Caption +0x800000
- Gui, Add, Text, gOpenDocumentation, Open the documentation
- Gui, Show, w600 h700, %ThisProgramName%
- WinSet, AlwaysOnTop, On, %ThisProgramName%
- OnMessage(0x200, "WM_MOUSEMOVE")
- Return
- OpenDocumentation:
- MsgBox, Oh no you clicked on me!
- Return
- ; ******************************************************************************
- ; MOUSE MOVEMENT (Tooltips)
- WM_MOUSEMOVE()
- {
- static CurrControl, PrevControl
- CurrControl := A_GuiControl
- If (CurrControl"" OR PrevControl"") {
- If (CurrControl PrevControl)
- {
- Gui, Font, cBlue underline
- GuiControl, Font, %CurrControl%
- PrevControl:=CurrControl
- } else {
- Gui, Font, cBlack norm
- GuiControl, Font, %CurrControl%
- PrevControl:=""
- }
- }
- }
- ; ******************************************************************************
- GuiClose:
- close:
- Gui, Destroy
- ExitApp
Proper HTML mouseovers:
When I have a more stable solution. I would however recommend cwebpage.dll at as a minimum for internal HTML pages for use in an AutoHotkey GUI.
Category: AutoHotkey :: Article: 369
	

 
						  
                 
						  
                 
						  
                 
						  
                 
						  
                 
 
 

 
 
Add comment