Thanks. I hope you're able to use the style and exstyle words to make "GUI Stealer" even better. Here is a working example that might help (you probably already planned this):
Code:
#Persistent
SetTimer, WatchCursor, 100
return
WatchCursor:
MouseGetPos,,, MouseWin, MouseControl
ControlGet, Style, Style,, %MouseControl%, ahk_id %MouseWin%
ControlGet, ExStyle, ExStyle,, %MouseControl%, ahk_id %MouseWin%
ButtonType = ; Set default to be blank.
IfInString, MouseControl, Button
{
Transform, ButtonType, BitAnd, %style%, 0xF ; Get the last four bits.
if ButtonType in 2,3,5,6 ; check, autocheck, 3state, auto3state (respectively)
ButtonType = Checkbox
else if ButtonType in 4,9 ; radio, autoradio (respectively)
ButtonType = Radio
else if ButtonType = 7 ; GroupBox
ButtonType = GroupBox
else ; Normal button, default button, picture button, etc.
ButtonType = Pushbutton
}
ToolTip %MouseControl%`nStyle:`t`t%Style%`nExStyle:`t%ExStyle%`nButton Type:`t%ButtonType%
return