From 691efb4538df9b6254eee3ea0207c222596bdf3d Mon Sep 17 00:00:00 2001 From: Mar Alegre Date: Sat, 16 Apr 2022 14:32:20 -0400 Subject: [PATCH] added a bunch of stuff --- lib/Wrapper.ahk | 2 +- src/AutorunAutoclick.ahk | 5 +- src/Deep Rock Galactic.ahk | 27 + src/Outer Wilds.ahk | 8 +- thirdparty/WinSpy/Constants/Messages.ini | 1915 ++++++++++++ thirdparty/WinSpy/Constants/Styles.ini | 468 +++ thirdparty/WinSpy/Resources/CrossHair.cur | Bin 0 -> 326 bytes thirdparty/WinSpy/Resources/FindTool1.bmp | Bin 0 -> 634 bytes thirdparty/WinSpy/Resources/FindTool2.bmp | Bin 0 -> 634 bytes thirdparty/WinSpy/Resources/Search.ico | Bin 0 -> 1150 bytes thirdparty/WinSpy/Resources/Settings.ico | Bin 0 -> 1150 bytes thirdparty/WinSpy/Resources/TreeIcons.icl | Bin 0 -> 38912 bytes thirdparty/WinSpy/Resources/WinSpy.ico | Bin 0 -> 4406 bytes thirdparty/WinSpy/WinSpy.ahk | 3278 +++++++++++++++++++++ 14 files changed, 5694 insertions(+), 9 deletions(-) create mode 100644 src/Deep Rock Galactic.ahk create mode 100644 thirdparty/WinSpy/Constants/Messages.ini create mode 100644 thirdparty/WinSpy/Constants/Styles.ini create mode 100644 thirdparty/WinSpy/Resources/CrossHair.cur create mode 100644 thirdparty/WinSpy/Resources/FindTool1.bmp create mode 100644 thirdparty/WinSpy/Resources/FindTool2.bmp create mode 100644 thirdparty/WinSpy/Resources/Search.ico create mode 100644 thirdparty/WinSpy/Resources/Settings.ico create mode 100644 thirdparty/WinSpy/Resources/TreeIcons.icl create mode 100644 thirdparty/WinSpy/Resources/WinSpy.ico create mode 100644 thirdparty/WinSpy/WinSpy.ahk diff --git a/lib/Wrapper.ahk b/lib/Wrapper.ahk index 457f47a..75a6815 100644 --- a/lib/Wrapper.ahk +++ b/lib/Wrapper.ahk @@ -10,7 +10,7 @@ CheckWinExist(Window) { Run %WrapperPath% SetTitleMatchMode 3 -WinWait %WrapperWindow% +WinWait %WrapperWindow%,,30 ; Check if window exists once per second WrapperFunc := Func("CheckWinExist").bind(WrapperWindow) diff --git a/src/AutorunAutoclick.ahk b/src/AutorunAutoclick.ahk index a2393b8..9bd4f76 100644 --- a/src/AutorunAutoclick.ahk +++ b/src/AutorunAutoclick.ahk @@ -18,8 +18,11 @@ *!LButton UP::HoldOrRepeat("LButton",[]) *!RButton UP::HoldOrRepeat("RButton",[]) +; Hold/Repeat spacebar +*!Space UP::HoldOrRepeat("Space",[]) + ; Autorun *!w UP::Hold("w",["s"]) *!s UP::Hold("s",["w"]) *!a UP::Hold("a",["d","w","s"]) -*!d UP::Hold("d",["a","w","s"]) +*!d UP::Hold("d",["a","w","s"]) \ No newline at end of file diff --git a/src/Deep Rock Galactic.ahk b/src/Deep Rock Galactic.ahk new file mode 100644 index 0000000..c05fcf7 --- /dev/null +++ b/src/Deep Rock Galactic.ahk @@ -0,0 +1,27 @@ +; Script can be directly run by or compiled into an .exe by the open-source software AutoHotkey +; https://www.autohotkey.com + +; +; Front Matter +; + +; Include relevant libraries +#Include ../lib/Prelude.ahk + +; Make this a wrapper script +WrapperPath:="steam://rungameid/548430" +WrapperWindow:="Deep Rock Galactic " +#Include ../lib/Wrapper.ahk + +; +; Hotkeys +; + +; When Caps lock is on, every gun is full auto +#If GetKeyState("CapsLock","T") +~*LButton:: +While GetKeyState("LButton","P") { + SendInput, {LButton down} + Sleep 20 +} +Return \ No newline at end of file diff --git a/src/Outer Wilds.ahk b/src/Outer Wilds.ahk index 1d615e8..5447048 100644 --- a/src/Outer Wilds.ahk +++ b/src/Outer Wilds.ahk @@ -32,12 +32,6 @@ Gui, Show, NoActivate x0 y0, StopwatchGui WinSet, TransColor, Black 100, StopwatchGui StopwatchHide() -; Send an F4 to activate fullscreen -Sleep 1000 -Send {F4 down} -Sleep 100 -Send {F4 up} - ; ; Hotkeys ; @@ -49,7 +43,7 @@ Send {F4 up} ; Alt+F1: Show/Hide stopwatch !F1::StopwatchToggleHidden() -#If StopwatchHidden +#If not StopwatchHidden ; F1: Reset stopwatch F1::StopwatchReset() diff --git a/thirdparty/WinSpy/Constants/Messages.ini b/thirdparty/WinSpy/Constants/Messages.ini new file mode 100644 index 0000000..bf828a4 --- /dev/null +++ b/thirdparty/WinSpy/Constants/Messages.ini @@ -0,0 +1,1915 @@ +[Window] +WM_SETTEXT=0x000C +WM_GETTEXT=0x000D +WM_GETTEXTLENGTH=0x000E +WM_SETFONT=0x0030 +WM_GETFONT=0x0031 +WM_GETICON=0x007F +WM_SETICON=0x0080 +WM_ACTIVATE=0x0006 +WM_ACTIVATEAPP=0x001C +WM_CANCELMODE=0x001F +WM_CHILDACTIVATE=0x0022 +WM_CLOSE=0x0010 +WM_CREATE=0x0001 +WM_DESTROY=0x0002 +WM_DROPFILES=0x0233 +WM_ENABLE=0x000A +WM_ENTERSIZEMOVE=0x0231 +WM_EXITSIZEMOVE=0x0232 +WM_MOVE=0x0003 +WM_MOVING=0x0216 +WM_NCCREATE=0x0081 +WM_NCDESTROY=0x0082 +WM_NCCALCSIZE=0x0083 +WM_NCACTIVATE=0x0086 +WM_QUERYOPEN=0x0013 +WM_QUIT=0x0012 +WM_SHOWWINDOW=0x0018 +WM_SIZE=0x0005 +WM_SIZING=0x0214 +WM_STYLECHANGING=0x007C +WM_STYLECHANGED=0x007D +WM_WINDOWPOSCHANGING=0x0046 +WM_WINDOWPOSCHANGED=0x0047 +WM_CUT=0x0300 +WM_COPY=0x0301 +WM_PASTE=0x0302 +WM_CLEAR=0x0303 +WM_UNDO=0x0304 +WM_RENDERFORMAT=0x0305 +WM_RENDERALLFORMATS=0x0306 +WM_DESTROYCLIPBOARD=0x0307 +WM_DRAWCLIPBOARD=0x0308 +WM_PAINTCLIPBOARD=0x0309 +WM_VSCROLLCLIPBOARD=0x030A +WM_SIZECLIPBOARD=0x030B +WM_ASKCBFORMATNAME=0x030C +WM_CHANGECBCHAIN=0x030D +WM_HSCROLLCLIPBOARD=0x030E +WM_CLIPBOARDUPDATE=0x031D +WM_DDE_INITIATE=0x03E0 +WM_DDE_TERMINATE=0x03E1 +WM_DDE_ADVISE=0x03E2 +WM_DDE_UNADVISE=0x03E3 +WM_DDE_ACK=0x03E4 +WM_DDE_DATA=0x03E5 +WM_DDE_REQUEST=0x03E6 +WM_DDE_POKE=0x03E7 +WM_DDE_EXECUTE=0x03E8 +WM_NEXTDLGCTL=0x0028 +WM_CTLCOLORDLG=0x0136 +WM_GETDLGCODE=0x0087 +WM_INITDIALOG=0x0110 +WM_ENTERIDLE=0x0121 +WM_DWMCOMPOSITIONCHANGED=0x031E +WM_DWMNCRENDERINGCHANGED=0x031F +WM_DWMCOLORIZATIONCOLORCHANGED=0x0320 +WM_DWMWINDOWMAXIMIZEDCHANGE=0x0321 +WM_DWMSENDICONICTHUMBNAIL=0x0323 +WM_DWMSENDICONICLIVEPREVIEWBITMAP=0x0326 +WM_IME_STARTCOMPOSITION=0x010D +WM_IME_ENDCOMPOSITION=0x010E +WM_IME_COMPOSITION=0x010F +WM_IME_KEYLAST=0x010F +WM_IME_SETCONTEXT=0x0281 +WM_IME_NOTIFY=0x0282 +WM_IME_CONTROL=0x0283 +WM_IME_COMPOSITIONFULL=0x0284 +WM_IME_SELECT=0x0285 +WM_IME_CHAR=0x0286 +WM_IME_REQUEST=0x0288 +WM_IME_KEYDOWN=0x0290 +WM_IME_KEYUP=0x0291 +WM_SETFOCUS=0x0007 +WM_KILLFOCUS=0x0008 +WM_APPCOMMAND=0x0319 +WM_KEYDOWN=0x0100 +WM_KEYUP=0x0101 +WM_CHAR=0x0102 +WM_DEADCHAR=0x0103 +WM_SYSKEYDOWN=0x0104 +WM_SYSKEYUP=0x0105 +WM_SYSCHAR=0x0106 +WM_SYSDEADCHAR=0x0107 +WM_HOTKEY=0x0312 +WM_KEYLAST=0x0109 +WM_UNICHAR=0x0109 +WM_SETHOTKEY=0x0032 +WM_GETHOTKEY=0x0033 +WM_MDICREATE=0x0220 +WM_MDIDESTROY=0x0221 +WM_MDIACTIVATE=0x0222 +WM_MDIRESTORE=0x0223 +WM_MDINEXT=0x0224 +WM_MDIMAXIMIZE=0x0225 +WM_MDITILE=0x0226 +WM_MDICASCADE=0x0227 +WM_MDIICONARRANGE=0x0228 +WM_MDIGETACTIVE=0x0229 +WM_MDISETMENU=0x0230 +WM_MDIREFRESHMENU=0x0234 +WM_COMMAND=0x0111 +WM_SYSCOMMAND=0x0112 +WM_INITMENU=0x0116 +WM_INITMENUPOPUP=0x0117 +WM_ENTERMENULOOP=0x0211 +WM_EXITMENULOOP=0x0212 +WM_NEXTMENU=0x0213 +WM_CONTEXTMENU=0x007B +WM_MENUSELECT=0x011F +WM_MENUCHAR=0x0120 +WM_MENURBUTTONUP=0x0122 +WM_MENUDRAG=0x0123 +WM_MENUGETOBJECT=0x0124 +WM_UNINITMENUPOPUP=0x0125 +WM_MENUCOMMAND=0x0126 +WM_MOUSEACTIVATE=0x0021 +WM_MOUSEMOVE=0x0200 +WM_MOUSELEAVE=0x02A3 +WM_MOUSEHOVER=0x02A1 +WM_LBUTTONDOWN=0x0201 +WM_LBUTTONUP=0x0202 +WM_LBUTTONDBLCLK=0x0203 +WM_RBUTTONDOWN=0x0204 +WM_RBUTTONUP=0x0205 +WM_RBUTTONDBLCLK=0x0206 +WM_MBUTTONDOWN=0x0207 +WM_MBUTTONUP=0x0208 +WM_MBUTTONDBLCLK=0x0209 +WM_XBUTTONDOWN=0x020B +WM_XBUTTONUP=0x020C +WM_XBUTTONDBLCLK=0x020D +WM_MOUSEWHEEL=0x020A +WM_MOUSEHWHEEL=0x020E +WM_CAPTURECHANGED=0x0215 +WM_NCHITTEST=0x0084 +WM_NCMOUSEMOVE=0x00A0 +WM_NCMOUSELEAVE=0x02A2 +WM_NCMOUSEHOVER=0x02A0 +WM_NCLBUTTONDOWN=0x00A1 +WM_NCLBUTTONUP=0x00A2 +WM_NCLBUTTONDBLCLK=0x00A3 +WM_NCRBUTTONDOWN=0x00A4 +WM_NCRBUTTONUP=0x00A5 +WM_NCRBUTTONDBLCLK=0x00A6 +WM_NCMBUTTONDOWN=0x00A7 +WM_NCMBUTTONUP=0x00A8 +WM_NCMBUTTONDBLCLK=0x00A9 +WM_NCXBUTTONDOWN=0x00AB +WM_NCXBUTTONUP=0x00AC +WM_NCXBUTTONDBLCLK=0x00AD +WM_DISPLAYCHANGE=0x007E +WM_ERASEBKGND=0x0014 +WM_NCPAINT=0x0085 +WM_PAINT=0x000F +WM_PRINT=0x0317 +WM_PRINTCLIENT=0x0318 +WM_SETREDRAW=0x000B +WM_SYNCPAINT=0x0088 +WM_CTLCOLORMSGBOX=0x0132 +WM_CTLCOLOREDIT=0x0133 +WM_CTLCOLORLISTBOX=0x0134 +WM_CTLCOLORBTN=0x0135 +WM_CTLCOLORSTATIC=0x0138 +WM_POINTERDEVICECHANGE=0x0238 +WM_POINTERDEVICEINRANGE=0x0239 +WM_TOUCH=0x0240 +WM_POINTERDEVICEOUTOFRANGE=0x023A +WM_NCPOINTERUPDATE=0x0241 +WM_NCPOINTERDOWN=0x0242 +WM_NCPOINTERUP=0x0243 +WM_POINTERUPDATE=0x0245 +WM_POINTERDOWN=0x0246 +WM_POINTERUP=0x0247 +WM_POINTERENTER=0x0249 +WM_POINTERLEAVE=0x024A +WM_POINTERACTIVATE=0x024B +WM_POINTERCAPTURECHANGED=0x024C +WM_TOUCHHITTESTING=0x024D +WM_POINTERWHEEL=0x024E +WM_POINTERHWHEEL=0x024F +WM_CTLCOLORSCROLLBAR=0x0137 +WM_HSCROLL=0x0114 +WM_VSCROLL=0x0115 +WM_SYSCOLORCHANGE=0x0015 +WM_SETTINGCHANGE=0x001A +WM_WININICHANGE=0x001A +WM_DEVMODECHANGE=0x001B +WM_FONTCHANGE=0x001D +WM_TIMECHANGE=0x001E +WM_INPUTLANGCHANGEREQUEST=0x0050 +WM_INPUTLANGCHANGE=0x0051 +WM_USERCHANGED=0x0054 +WM_DEVICECHANGE=0x0219 +WM_WTSSESSION_CHANGE=0x02B1 +WM_DPICHANGED=0x02E0 +WM_THEMECHANGED=0x031A +WM_NULL=0x0000 +WM_QUERYENDSESSION=0x0011 +WM_ENDSESSION=0x0016 +WM_SETCURSOR=0x0020 +WM_QUEUESYNC=0x0023 +WM_GETMINMAXINFO=0x0024 +WM_PAINTICON=0x0026 +WM_ICONERASEBKGND=0x0027 +WM_SPOOLERSTATUS=0x002A +WM_DRAWITEM=0x002B +WM_MEASUREITEM=0x002C +WM_DELETEITEM=0x002D +WM_VKEYTOITEM=0x002E +WM_CHARTOITEM=0x002F +WM_QUERYDRAGICON=0x0037 +WM_COMPAREITEM=0x0039 +WM_GETOBJECT=0x003D +WM_COMPACTING=0x0041 +WM_COMMNOTIFY=0x0044 +WM_POWER=0x0048 +WM_COPYDATA=0x004A +WM_CANCELJOURNAL=0x004B +WM_NOTIFY=0x004E +WM_TCARD=0x0052 +WM_HELP=0x0053 +WM_NOTIFYFORMAT=0x0055 +WM_INPUT_DEVICE_CHANGE=0x00FE +WM_INPUT=0x00FF +WM_TIMER=0x0113 +WM_GESTURE=0x0119 +WM_GESTURENOTIFY=0x011A +WM_CHANGEUISTATE=0x0127 +WM_UPDATEUISTATE=0x0128 +WM_QUERYUISTATE=0x0129 +WM_PARENTNOTIFY=0x0210 +WM_POWERBROADCAST=0x0218 +WM_QUERYNEWPALETTE=0x030F +WM_PALETTEISCHANGING=0x0310 +WM_PALETTECHANGED=0x0311 +WM_GETTITLEBARINFOEX=0x033F +WM_USER=0x0400 +WM_APP=0x8000 + +[Button] +BM_GETCHECK=0x00F0 +BM_SETCHECK=0x00F1 +BM_GETSTATE=0x00F2 +BM_SETSTATE=0x00F3 +BM_SETSTYLE=0x00F4 +BM_CLICK=0x00F5 +BM_GETIMAGE=0x00F6 +BM_SETIMAGE=0x00F7 +BM_SETDONTCLICK=0x00F8 +BCM_GETIDEALSIZE=0x1601 +BCM_SETIMAGELIST=0x1602 +BCM_GETIMAGELIST=0x1603 +BCM_SETTEXTMARGIN=0x1604 +BCM_GETTEXTMARGIN=0x1605 +BCM_SETDROPDOWNSTATE=0x1606 +BCM_SETSPLITINFO=0x1607 +BCM_GETSPLITINFO=0x1608 +BCM_SETNOTE=0x1609 +BCM_GETNOTE=0x160A +BCM_GETNOTELENGTH=0x160B +BCM_SETSHIELD=0x160C + +[ComboBox] +CB_GETEDITSEL=0x0140 +CB_LIMITTEXT=0x0141 +CB_SETEDITSEL=0x0142 +CB_ADDSTRING=0x0143 +CB_DELETESTRING=0x0144 +CB_DIR=0x0145 +CB_GETCOUNT=0x0146 +CB_GETCURSEL=0x0147 +CB_GETLBTEXT=0x0148 +CB_GETLBTEXTLEN=0x0149 +CB_INSERTSTRING=0x014A +CB_RESETCONTENT=0x014B +CB_FINDSTRING=0x014C +CB_SELECTSTRING=0x014D +CB_SETCURSEL=0x014E +CB_SHOWDROPDOWN=0x014F +CB_GETITEMDATA=0x0150 +CB_SETITEMDATA=0x0151 +CB_GETDROPPEDCONTROLRECT=0x0152 +CB_SETITEMHEIGHT=0x0153 +CB_GETITEMHEIGHT=0x0154 +CB_SETEXTENDEDUI=0x0155 +CB_GETEXTENDEDUI=0x0156 +CB_GETDROPPEDSTATE=0x0157 +CB_FINDSTRINGEXACT=0x0158 +CB_SETLOCALE=0x0159 +CB_GETLOCALE=0x015A +CB_GETTOPINDEX=0x015B +CB_SETTOPINDEX=0x015C +CB_GETHORIZONTALEXTENT=0x015D +CB_SETHORIZONTALEXTENT=0x015E +CB_GETDROPPEDWIDTH=0x015F +CB_SETDROPPEDWIDTH=0x0160 +CB_INITSTORAGE=0x0161 +CB_MULTIPLEADDSTRING=0x0163 +CB_GETCOMBOBOXINFO=0x0164 +CB_SETMINVISIBLE=0x1701 +CB_GETMINVISIBLE=0x1702 +CB_SETCUEBANNER=0x1703 +CB_GETCUEBANNER=0x1704 + +[SysDateTimePick32] +DTM_GETSYSTEMTIME=0x1001 +DTM_SETSYSTEMTIME=0x1002 +DTM_GETRANGE=0x1003 +DTM_SETRANGE=0x1004 +DTM_SETFORMATA=0x1005 +DTM_SETMCCOLOR=0x1006 +DTM_GETMCCOLOR=0x1007 +DTM_GETMONTHCAL=0x1008 +DTM_SETMCFONT=0x1009 +DTM_GETMCFONT=0x100A +DTM_SETMCSTYLE=0x100B +DTM_GETMCSTYLE=0x100C +DTM_CLOSEMONTHCAL=0x100D +DTM_GETDATETIMEPICKERINFO=0x100E +DTM_GETIDEALSIZE=0x100F +DTM_SETFORMATW=0x1032 + +[Edit] +EM_GETSEL=0x00B0 +EM_SETSEL=0x00B1 +EM_GETRECT=0x00B2 +EM_SETRECT=0x00B3 +EM_SETRECTNP=0x00B4 +EM_SCROLL=0x00B5 +EM_LINESCROLL=0x00B6 +EM_SCROLLCARET=0x00B7 +EM_GETMODIFY=0x00B8 +EM_SETMODIFY=0x00B9 +EM_GETLINECOUNT=0x00BA +EM_LINEINDEX=0x00BB +EM_SETHANDLE=0x00BC +EM_GETHANDLE=0x00BD +EM_GETTHUMB=0x00BE +EM_LINELENGTH=0x00C1 +EM_REPLACESEL=0x00C2 +EM_GETLINE=0x00C4 +EM_LIMITTEXT=0x00C5 +EM_SETLIMITTEXT=0x00C5 +EM_CANUNDO=0x00C6 +EM_UNDO=0x00C7 +EM_FMTLINES=0x00C8 +EM_LINEFROMCHAR=0x00C9 +EM_SETTABSTOPS=0x00CB +EM_SETPASSWORDCHAR=0x00CC +EM_EMPTYUNDOBUFFER=0x00CD +EM_GETFIRSTVISIBLELINE=0x00CE +EM_SETREADONLY=0x00CF +EM_SETWORDBREAKPROC=0x00D0 +EM_GETWORDBREAKPROC=0x00D1 +EM_GETPASSWORDCHAR=0x00D2 +EM_SETMARGINS=0x00D3 +EM_GETMARGINS=0x00D4 +EM_GETLIMITTEXT=0x00D5 +EM_POSFROMCHAR=0x00D6 +EM_CHARFROMPOS=0x00D7 +EM_SETIMESTATUS=0x00D8 +EM_GETIMESTATUS=0x00D9 +EM_SETCUEBANNER=0x1501 +EM_GETCUEBANNER=0x1502 +EM_SHOWBALLOONTIP=0x1503 +EM_HIDEBALLOONTIP=0x1504 +EM_SETHILITE=0x1505 +EM_GETHILITE=0x1506 + +[msctls_hotkey32] +HKM_SETHOTKEY=0x0401 +HKM_GETHOTKEY=0x0402 +HKM_SETRULES=0x0403 + +[SysLink] +LM_HITTEST=0x0700 +LM_GETIDEALHEIGHT=0x0701 +LM_GETIDEALSIZE=0x0701 +LM_SETITEM=0x0702 +LM_GETITEM=0x0703 + +[ListBox] +LB_ADDSTRING=0x0180 +LB_INSERTSTRING=0x0181 +LB_DELETESTRING=0x0182 +LB_SELITEMRANGEEX=0x0183 +LB_RESETCONTENT=0x0184 +LB_SETSEL=0x0185 +LB_SETCURSEL=0x0186 +LB_GETSEL=0x0187 +LB_GETCURSEL=0x0188 +LB_GETTEXT=0x0189 +LB_GETTEXTLEN=0x018A +LB_GETCOUNT=0x018B +LB_SELECTSTRING=0x018C +LB_DIR=0x018D +LB_GETTOPINDEX=0x018E +LB_FINDSTRING=0x018F +LB_GETSELCOUNT=0x0190 +LB_GETSELITEMS=0x0191 +LB_SETTABSTOPS=0x0192 +LB_GETHORIZONTALEXTENT=0x0193 +LB_SETHORIZONTALEXTENT=0x0194 +LB_SETCOLUMNWIDTH=0x0195 +LB_ADDFILE=0x0196 +LB_SETTOPINDEX=0x0197 +LB_GETITEMRECT=0x0198 +LB_GETITEMDATA=0x0199 +LB_SETITEMDATA=0x019A +LB_SELITEMRANGE=0x019B +LB_SETANCHORINDEX=0x019C +LB_GETANCHORINDEX=0x019D +LB_SETCARETINDEX=0x019E +LB_GETCARETINDEX=0x019F +LB_SETITEMHEIGHT=0x01A0 +LB_GETITEMHEIGHT=0x01A1 +LB_FINDSTRINGEXACT=0x01A2 +LB_SETLOCALE=0x01A5 +LB_GETLOCALE=0x01A6 +LB_SETCOUNT=0x01A7 +LB_INITSTORAGE=0x01A8 +LB_ITEMFROMPOINT=0x01A9 +LB_MULTIPLEADDSTRING=0x01B1 +LB_GETLISTBOXINFO=0x01B2 + +[SysListView32] +LVM_GETBKCOLOR=0x1000 +LVM_SETBKCOLOR=0x1001 +LVM_GETIMAGELIST=0x1002 +LVM_SETIMAGELIST=0x1003 +LVM_GETITEMCOUNT=0x1004 +LVM_GETITEMA=0x1005 +LVM_SETITEMA=0x1006 +LVM_INSERTITEMA=0x1007 +LVM_DELETEITEM=0x1008 +LVM_DELETEALLITEMS=0x1009 +LVM_GETCALLBACKMASK=0x100A +LVM_SETCALLBACKMASK=0x100B +LVM_GETNEXTITEM=0x100C +LVM_FINDITEMA=0x100D +LVM_GETITEMRECT=0x100E +LVM_SETITEMPOSITION=0x100F +LVM_GETITEMPOSITION=0x1010 +LVM_GETSTRINGWIDTHA=0x1011 +LVM_HITTEST=0x1012 +LVM_ENSUREVISIBLE=0x1013 +LVM_SCROLL=0x1014 +LVM_REDRAWITEMS=0x1015 +LVM_ARRANGE=0x1016 +LVM_EDITLABELA=0x1017 +LVM_GETEDITCONTROL=0x1018 +LVM_GETCOLUMNA=0x1019 +LVM_INSERTCOLUMNA=0x1019 +LVM_SETCOLUMNA=0x101A +LVM_DELETECOLUMN=0x101C +LVM_GETCOLUMNWIDTH=0x101D +LVM_SETCOLUMNWIDTH=0x101E +LVM_GETHEADER=0x101F +LVM_CREATEDRAGIMAGE=0x1021 +LVM_GETVIEWRECT=0x1022 +LVM_GETTEXTCOLOR=0x1023 +LVM_SETTEXTCOLOR=0x1024 +LVM_GETTEXTBKCOLOR=0x1025 +LVM_SETTEXTBKCOLOR=0x1026 +LVM_GETTOPINDEX=0x1027 +LVM_GETCOUNTPERPAGE=0x1028 +LVM_GETORIGIN=0x1029 +LVM_UPDATE=0x102A +LVM_SETITEMSTATE=0x102B +LVM_GETITEMSTATE=0x102C +LVM_GETITEMTEXTA=0x102D +LVM_SETITEMTEXTA=0x102E +LVM_SETITEMCOUNT=0x102F +LVM_SORTITEMS=0x1030 +LVM_SETITEMPOSITION32=0x1031 +LVM_GETSELECTEDCOUNT=0x1032 +LVM_GETITEMSPACING=0x1033 +LVM_GETISEARCHSTRINGA=0x1034 +LVM_SETICONSPACING=0x1035 +LVM_SETEXTENDEDLISTVIEWSTYLE=0x1036 +LVM_GETEXTENDEDLISTVIEWSTYLE=0x1037 +LVM_GETSUBITEMRECT=0x1038 +LVM_SUBITEMHITTEST=0x1039 +LVM_SETCOLUMNORDERARRAY=0x103A +LVM_GETCOLUMNORDERARRAY=0x103B +LVM_SETHOTITEM=0x103C +LVM_GETHOTITEM=0x103D +LVM_SETHOTCURSOR=0x103E +LVM_GETHOTCURSOR=0x103F +LVM_APPROXIMATEVIEWRECT=0x1040 +LVM_SETWORKAREAS=0x1041 +LVM_GETSELECTIONMARK=0x1042 +LVM_SETSELECTIONMARK=0x1043 +LVM_SETBKIMAGEA=0x1044 +LVM_GETBKIMAGEA=0x1045 +LVM_GETWORKAREAS=0x1046 +LVM_SETHOVERTIME=0x1047 +LVM_GETHOVERTIME=0x1048 +LVM_GETNUMBEROFWORKAREAS=0x1049 +LVM_SETTOOLTIPS=0x104A +LVM_GETITEMW=0x104B +LVM_SETITEMW=0x104C +LVM_INSERTITEMW=0x104D +LVM_GETTOOLTIPS=0x104E +LVM_SORTITEMSEX=0x1051 +LVM_FINDITEMW=0x1053 +LVM_GETSTRINGWIDTHW=0x1057 +LVM_GETGROUPSTATE=0x105C +LVM_GETFOCUSEDGROUP=0x105D +LVM_GETCOLUMNW=0x105F +LVM_SETCOLUMNW=0x1060 +LVM_INSERTCOLUMNW=0x1061 +LVM_GETGROUPRECT=0x1062 +LVM_GETITEMTEXTW=0x1073 +LVM_SETITEMTEXTW=0x1074 +LVM_GETISEARCHSTRINGW=0x1075 +LVM_EDITLABELW=0x1076 +LVM_SETBKIMAGEW=0x108A +LVM_GETBKIMAGEW=0x108B +LVM_SETVIEW=0x108E +LVM_GETVIEW=0x108F +LVM_INSERTGROUP=0x1091 +LVM_SETGROUPINFO=0x1093 +LVM_GETGROUPINFO=0x1095 +LVM_REMOVEGROUP=0x1096 +LVM_MOVEGROUP=0x1097 +LVM_GETGROUPCOUNT=0x1098 +LVM_GETGROUPINFOBYINDEX=0x1099 +LVM_MOVEITEMTOGROUP=0x109A +LVM_SETGROUPMETRICS=0x109B +LVM_GETGROUPMETRICS=0x109C +LVM_ENABLEGROUPVIEW=0x109D +LVM_SORTGROUPS=0x109E +LVM_INSERTGROUPSORTED=0x109F +LVM_REMOVEALLGROUPS=0x10A0 +LVM_HASGROUP=0x10A1 +LVM_SETTILEVIEWINFO=0x10A2 +LVM_GETTILEVIEWINFO=0x10A3 +LVM_SETTILEINFO=0x10A4 +LVM_GETTILEINFO=0x10A5 +LVM_SETINSERTMARK=0x10A6 +LVM_GETINSERTMARK=0x10A7 +LVM_INSERTMARKHITTEST=0x10A8 +LVM_GETINSERTMARKRECT=0x10A9 +LVM_SETINSERTMARKCOLOR=0x10AA +LVM_GETINSERTMARKCOLOR=0x10AB +LVM_SETINFOTIP=0x10AD +LVM_GETSELECTEDCOLUMN=0x10AE +LVM_ISGROUPVIEWENABLED=0x10AF +LVM_GETOUTLINECOLOR=0x10B0 +LVM_SETOUTLINECOLOR=0x10B1 +LVM_CANCELEDITLABEL=0x10B3 +LVM_MAPINDEXTOID=0x10B4 +LVM_MAPIDTOINDEX=0x10B5 +LVM_ISITEMVISIBLE=0x10B6 +LVM_GETEMPTYTEXT=0x10CC +LVM_GETFOOTERRECT=0x10CD +LVM_GETFOOTERINFO=0x10CE +LVM_GETFOOTERITEMRECT=0x10CF +LVM_GETFOOTERITEM=0x10D0 +LVM_GETITEMINDEXRECT=0x10D1 +LVM_SETITEMINDEXSTATE=0x10D2 +LVM_GETNEXTITEMINDEX=0x10D3 +LVM_SETUNICODEFORMAT=0x2005 +LVM_GETUNICODEFORMAT=0x2006 + +[SysHeader32] +HDM_GETITEMCOUNT=0x1200 +HDM_INSERTITEMA=0x1201 +HDM_DELETEITEM=0x1202 +HDM_GETITEMA=0x1203 +HDM_SETITEMA=0x1204 +HDM_LAYOUT=0x1205 +HDM_HITTEST=0x1206 +HDM_GETITEMRECT=0x1207 +HDM_SETIMAGELIST=0x1208 +HDM_GETIMAGELIST=0x1209 +HDM_INSERTITEMW=0x120A +HDM_GETITEMW=0x120B +HDM_SETITEMW=0x120C +HDM_ORDERTOINDEX=0x120F +HDM_CREATEDRAGIMAGE=0x1210 +HDM_GETORDERARRAY=0x1211 +HDM_SETORDERARRAY=0x1212 +HDM_SETHOTDIVIDER=0x1213 +HDM_SETBITMAPMARGIN=0x1214 +HDM_GETBITMAPMARGIN=0x1215 +HDM_SETFILTERCHANGETIMEOUT=0x1216 +HDM_EDITFILTER=0x1217 +HDM_CLEARFILTER=0x1218 +HDM_GETITEMDROPDOWNRECT=0x1219 +HDM_GETOVERFLOWRECT=0x121A +HDM_GETFOCUSEDITEM=0x121B +HDM_SETFOCUSEDITEM=0x121C +HDM_SETUNICODEFORMAT=0x2004 +HDM_GETUNICODEFORMAT=0x2005 +HDM_TRANSLATEACCELERATOR=0x200A + +[SysMonthCal32] +MCM_GETCURSEL=0x1001 +MCM_SETCURSEL=0x1002 +MCM_GETMAXSELCOUNT=0x1003 +MCM_SETMAXSELCOUNT=0x1004 +MCM_GETSELRANGE=0x1005 +MCM_SETSELRANGE=0x1006 +MCM_GETMONTHRANGE=0x1007 +MCM_SETDAYSTATE=0x1008 +MCM_GETMINREQRECT=0x1009 +MCM_SETCOLOR=0x100A +MCM_GETCOLOR=0x100B +MCM_SETTODAY=0x100C +MCM_GETTODAY=0x100D +MCM_HITTEST=0x100E +MCM_SETFIRSTDAYOFWEEK=0x100F +MCM_GETFIRSTDAYOFWEEK=0x1010 +MCM_GETRANGE=0x1011 +MCM_SETRANGE=0x1012 +MCM_GETMONTHDELTA=0x1013 +MCM_SETMONTHDELTA=0x1014 +MCM_GETCURRENTVIEW=0x1016 +MCM_GETCALENDARCOUNT=0x1017 +MCM_GETCALENDARGRIDINFO=0x1018 +MCM_GETCALID=0x101B +MCM_SETCALID=0x101C +MCM_SIZERECTTOMIN=0x101D +MCM_SETCALENDARBORDER=0x101E +MCM_GETCALENDARBORDER=0x101F +MCM_SETCURRENTVIEW=0x1020 +MCM_SETUNICODEFORMAT=0x2005 +MCM_GETUNICODEFORMAT=0x2006 + +[msctls_progress32] +PBM_SETRANGE=0x0401 +PBM_SETPOS=0x0402 +PBM_DELTAPOS=0x0403 +PBM_SETSTEP=0x0404 +PBM_STEPIT=0x0405 +PBM_SETRANGE32=0x0406 +PBM_GETRANGE=0x0407 +PBM_GETPOS=0x0408 +PBM_SETBARCOLOR=0x0409 +PBM_SETMARQUEE=0x040A +PBM_GETSTEP=0x040D +PBM_GETBKCOLOR=0x040E +PBM_GETBARCOLOR=0x040F +PBM_SETSTATE=0x0410 +PBM_GETSTATE=0x0411 +PBM_SETBKCOLOR=0x2001 + +[ReBarWindow32] +RB_INSERTBANDA=0x0401 +RB_DELETEBAND=0x0402 +RB_GETBARINFO=0x0403 +RB_SETBARINFO=0x0404 +RB_GETBANDINFO=0x0405 +RB_SETBANDINFOA=0x0406 +RB_SETPARENT=0x0407 +RB_HITTEST=0x0408 +RB_GETRECT=0x0409 +RB_INSERTBANDW=0x040A +RB_SETBANDINFOW=0x040B +RB_GETBANDCOUNT=0x040C +RB_GETROWCOUNT=0x040D +RB_GETROWHEIGHT=0x040E +RB_IDTOINDEX=0x0410 +RB_GETTOOLTIPS=0x0411 +RB_SETTOOLTIPS=0x0412 +RB_SETBKCOLOR=0x0413 +RB_GETBKCOLOR=0x0414 +RB_SETTEXTCOLOR=0x0415 +RB_GETTEXTCOLOR=0x0416 +RB_SIZETORECT=0x0417 +RB_BEGINDRAG=0x0418 +RB_ENDDRAG=0x0419 +RB_DRAGMOVE=0x041A +RB_GETBARHEIGHT=0x041B +RB_GETBANDINFOW=0x041C +RB_GETBANDINFOA=0x041D +RB_MINIMIZEBAND=0x041E +RB_MAXIMIZEBAND=0x041F +RB_GETBANDBORDERS=0x0422 +RB_SHOWBAND=0x0423 +RB_SETPALETTE=0x0425 +RB_GETPALETTE=0x0426 +RB_MOVEBAND=0x0427 +RB_GETBANDMARGINS=0x0428 +RB_SETEXTENDEDSTYLE=0x0429 +RB_GETEXTENDEDSTYLE=0x042A +RB_PUSHCHEVRON=0x042B +RB_SETBANDWIDTH=0x042C +RB_SETCOLORSCHEME=0x2002 +RB_GETCOLORSCHEME=0x2003 +RB_GETDROPTARGET=0x2004 +RB_SETUNICODEFORMAT=0x2004 +RB_GETUNICODEFORMAT=0x2005 +RB_SETWINDOWTHEME=0x200B + +[msctls_trackbar32] +TBM_GETPOS=0x0400 +TBM_GETRANGEMIN=0x0401 +TBM_GETRANGEMAX=0x0402 +TBM_GETTIC=0x0403 +TBM_SETTIC=0x0404 +TBM_SETPOS=0x0405 +TBM_SETRANGE=0x0406 +TBM_SETRANGEMIN=0x0407 +TBM_SETRANGEMAX=0x0408 +TBM_CLEARTICS=0x0409 +TBM_SETSEL=0x040A +TBM_SETSELSTART=0x040B +TBM_SETSELEND=0x040C +TBM_GETPTICS=0x040E +TBM_GETTICPOS=0x040F +TBM_GETNUMTICS=0x0410 +TBM_GETSELSTART=0x0411 +TBM_GETSELEND=0x0412 +TBM_CLEARSEL=0x0413 +TBM_SETTICFREQ=0x0414 +TBM_SETPAGESIZE=0x0415 +TBM_GETPAGESIZE=0x0416 +TBM_SETLINESIZE=0x0417 +TBM_GETLINESIZE=0x0418 +TBM_GETTHUMBRECT=0x0419 +TBM_GETCHANNELRECT=0x041A +TBM_SETTHUMBLENGTH=0x041B +TBM_GETTHUMBLENGTH=0x041C +TBM_SETTOOLTIPS=0x041D +TBM_GETTOOLTIPS=0x041E +TBM_SETTIPSIDE=0x041F +TBM_SETBUDDY=0x0420 +TBM_GETBUDDY=0x0421 +TBM_SETPOSNOTIFY=0x0422 +TBM_SETUNICODEFORMAT=0x2005 +TBM_GETUNICODEFORMAT=0x2006 + +[Static] +STM_SETICON=0x0170 +STM_GETICON=0x0171 +STM_SETIMAGE=0x0172 +STM_GETIMAGE=0x0173 + +[msctls_statusbar32] +SB_SETTEXTA=0x0401 +SB_GETTEXTA=0x0402 +SB_GETTEXTLENGTHA=0x0403 +SB_SETPARTS=0x0404 +SB_GETPARTS=0x0406 +SB_GETBORDERS=0x0407 +SB_SETMINHEIGHT=0x0408 +SB_SIMPLE=0x0409 +SB_GETRECT=0x040A +SB_SETTEXTW=0x040B +SB_GETTEXTLENGTHW=0x040C +SB_GETTEXTW=0x040D +SB_ISSIMPLE=0x040E +SB_SETICON=0x040F +SB_SETTIPTEXTA=0x0410 +SB_SETTIPTEXTW=0x0411 +SB_GETTIPTEXTA=0x0412 +SB_GETTIPTEXTW=0x0413 +SB_GETICON=0x0414 +SB_SETBKCOLOR=0x2001 +SB_SETUNICODEFORMAT=0x2005 +SB_GETUNICODEFORMAT=0x2006 + +[SysTabControl32] +TCM_GETIMAGELIST=0x1302 +TCM_SETIMAGELIST=0x1303 +TCM_GETITEMCOUNT=0x1304 +TCM_GETITEMA=0x1305 +TCM_SETITEMA=0x1306 +TCM_INSERTITEMA=0x1307 +TCM_DELETEITEM=0x1308 +TCM_DELETEALLITEMS=0x1309 +TCM_GETITEMRECT=0x130A +TCM_GETCURSEL=0x130B +TCM_SETCURSEL=0x130C +TCM_HITTEST=0x130D +TCM_SETITEMEXTRA=0x130E +TCM_ADJUSTRECT=0x1328 +TCM_SETITEMSIZE=0x1329 +TCM_REMOVEIMAGE=0x132A +TCM_SETPADDING=0x132B +TCM_GETROWCOUNT=0x132C +TCM_GETTOOLTIPS=0x132D +TCM_SETTOOLTIPS=0x132E +TCM_GETCURFOCUS=0x132F +TCM_SETCURFOCUS=0x1330 +TCM_SETMINTABWIDTH=0x1331 +TCM_DESELECTALL=0x1332 +TCM_HIGHLIGHTITEM=0x1333 +TCM_SETEXTENDEDSTYLE=0x1334 +TCM_GETEXTENDEDSTYLE=0x1335 +TCM_GETITEMW=0x133C +TCM_SETITEMW=0x133D +TCM_INSERTITEMW=0x133E +TCM_SETUNICODEFORMAT=0x2005 +TCM_GETUNICODEFORMAT=0x2006 + +[ToolbarWindow32] +TB_ENABLEBUTTON=0x0401 +TB_CHECKBUTTON=0x0402 +TB_PRESSBUTTON=0x0403 +TB_HIDEBUTTON=0x0404 +TB_INDETERMINATE=0x0405 +TB_MARKBUTTON=0x0406 +TB_ISBUTTONENABLED=0x0409 +TB_ISBUTTONCHECKED=0x040A +TB_ISBUTTONPRESSED=0x040B +TB_ISBUTTONHIDDEN=0x040C +TB_ISBUTTONINDETERMINATE=0x040D +TB_ISBUTTONHIGHLIGHTED=0x040E +TB_SETSTATE=0x0411 +TB_GETSTATE=0x0412 +TB_ADDBITMAP=0x0413 +TB_ADDBUTTONSA=0x0414 +TB_INSERTBUTTONA=0x0415 +TB_DELETEBUTTON=0x0416 +TB_GETBUTTON=0x0417 +TB_BUTTONCOUNT=0x0418 +TB_COMMANDTOINDEX=0x0419 +TB_SAVERESTOREA=0x041A +TB_CUSTOMIZE=0x041B +TB_ADDSTRINGA=0x041C +TB_GETITEMRECT=0x041D +TB_BUTTONSTRUCTSIZE=0x041E +TB_SETBUTTONSIZE=0x041F +TB_SETBITMAPSIZE=0x0420 +TB_AUTOSIZE=0x0421 +TB_GETTOOLTIPS=0x0423 +TB_SETTOOLTIPS=0x0424 +TB_SETPARENT=0x0425 +TB_SETROWS=0x0427 +TB_GETROWS=0x0428 +TB_SETCMDID=0x042A +TB_CHANGEBITMAP=0x042B +TB_GETBITMAP=0x042C +TB_GETBUTTONTEXTA=0x042D +TB_REPLACEBITMAP=0x042E +TB_SETINDENT=0x042F +TB_SETIMAGELIST=0x0430 +TB_GETIMAGELIST=0x0431 +TB_LOADIMAGES=0x0432 +TB_GETRECT=0x0433 +TB_SETHOTIMAGELIST=0x0434 +TB_GETHOTIMAGELIST=0x0435 +TB_SETDISABLEDIMAGELIST=0x0436 +TB_GETDISABLEDIMAGELIST=0x0437 +TB_SETSTYLE=0x0438 +TB_GETSTYLE=0x0439 +TB_GETBUTTONSIZE=0x043A +TB_SETBUTTONWIDTH=0x043B +TB_SETMAXTEXTROWS=0x043C +TB_GETTEXTROWS=0x043D +TB_GETOBJECT=0x043E +TB_GETBUTTONINFOW=0x043F +TB_SETBUTTONINFOW=0x0440 +TB_GETBUTTONINFOA=0x0441 +TB_SETBUTTONINFOA=0x0442 +TB_INSERTBUTTONW=0x0443 +TB_ADDBUTTONSW=0x0444 +TB_HITTEST=0x0445 +TB_SETDRAWTEXTFLAGS=0x0446 +TB_GETHOTITEM=0x0447 +TB_SETHOTITEM=0x0448 +TB_SETANCHORHIGHLIGHT=0x0449 +TB_GETANCHORHIGHLIGHT=0x044A +TB_GETBUTTONTEXTW=0x044B +TB_SAVERESTOREW=0x044C +TB_ADDSTRINGW=0x044D +TB_MAPACCELERATORA=0x044E +TB_GETINSERTMARK=0x044F +TB_SETINSERTMARK=0x0450 +TB_INSERTMARKHITTEST=0x0451 +TB_MOVEBUTTON=0x0452 +TB_GETMAXSIZE=0x0453 +TB_SETEXTENDEDSTYLE=0x0454 +TB_GETEXTENDEDSTYLE=0x0455 +TB_GETPADDING=0x0456 +TB_SETPADDING=0x0457 +TB_SETINSERTMARKCOLOR=0x0458 +TB_GETINSERTMARKCOLOR=0x0459 +TB_MAPACCELERATORW=0x045A +TB_GETSTRINGW=0x045B +TB_GETSTRINGA=0x045C +TB_SETHOTITEM2=0x045E +TB_SETLISTGAP=0x0460 +TB_GETIMAGELISTCOUNT=0x0462 +TB_GETIDEALSIZE=0x0463 +TB_GETMETRICS=0x0465 +TB_SETMETRICS=0x0466 +TB_GETITEMDROPDOWNRECT=0x0467 +TB_SETPRESSEDIMAGELIST=0x0468 +TB_GETPRESSEDIMAGELIST=0x0469 +TB_SETCOLORSCHEME=0x2002 +TB_GETCOLORSCHEME=0x2003 +TB_SETUNICODEFORMAT=0x2004 +TB_GETUNICODEFORMAT=0x2005 +TB_TRANSLATEACCELERATOR=0x200A +TB_SETWINDOWTHEME=0x200B + +[tooltips_class32] +TTM_ACTIVATE=0x0401 +TTM_SETDELAYTIME=0x0403 +TTM_ADDTOOLA=0x0404 +TTM_DELTOOLA=0x0405 +TTM_NEWTOOLRECTA=0x0406 +TTM_RELAYEVENT=0x0407 +TTM_GETTOOLINFOA=0x0408 +TTM_SETTOOLINFOA=0x0409 +TTM_HITTESTA=0x040A +TTM_GETTEXTA=0x040B +TTM_UPDATETIPTEXTA=0x040C +TTM_GETTOOLCOUNT=0x040D +TTM_ENUMTOOLSA=0x040E +TTM_GETCURRENTTOOLA=0x040F +TTM_WINDOWFROMPOINT=0x0410 +TTM_TRACKACTIVATE=0x0411 +TTM_TRACKPOSITION=0x0412 +TTM_SETTIPBKCOLOR=0x0413 +TTM_SETTIPTEXTCOLOR=0x0414 +TTM_GETDELAYTIME=0x0415 +TTM_GETTIPBKCOLOR=0x0416 +TTM_GETTIPTEXTCOLOR=0x0417 +TTM_SETMAXTIPWIDTH=0x0418 +TTM_GETMAXTIPWIDTH=0x0419 +TTM_SETMARGIN=0x041A +TTM_GETMARGIN=0x041B +TTM_POP=0x041C +TTM_UPDATE=0x041D +TTM_GETBUBBLESIZE=0x041E +TTM_ADJUSTRECT=0x041F +TTM_SETTITLEA=0x0420 +TTM_SETTITLEW=0x0421 +TTM_POPUP=0x0422 +TTM_GETTITLE=0x0423 +TTM_ADDTOOLW=0x0432 +TTM_DELTOOLW=0x0433 +TTM_NEWTOOLRECTW=0x0434 +TTM_GETTOOLINFOW=0x0435 +TTM_HITTESTW=0x0437 +TTM_GETTEXTW=0x0438 +TTM_UPDATETIPTEXTW=0x0439 +TTM_ENUMTOOLSW=0x043A +TTM_GETCURRENTTOOLW=0x043B +TTM_SETTOOLINFOW=0x0636 +TTM_SETWINDOWTHEME=0x200B + +[SysTreeView32] +TVM_INSERTITEMA=0x1100 +TVM_DELETEITEM=0x1101 +TVM_EXPAND=0x1102 +TVM_GETITEMRECT=0x1104 +TVM_GETCOUNT=0x1105 +TVM_GETINDENT=0x1106 +TVM_SETINDENT=0x1107 +TVM_GETIMAGELIST=0x1108 +TVM_SETIMAGELIST=0x1109 +TVM_GETNEXTITEM=0x110A +TVM_SELECTITEM=0x110B +TVM_GETITEMA=0x110C +TVM_SETITEMA=0x110D +TVM_EDITLABELA=0x110E +TVM_GETEDITCONTROL=0x110F +TVM_GETVISIBLECOUNT=0x1110 +TVM_HITTEST=0x1111 +TVM_CREATEDRAGIMAGE=0x1112 +TVM_SORTCHILDREN=0x1113 +TVM_ENSUREVISIBLE=0x1114 +TVM_SORTCHILDRENCB=0x1115 +TVM_ENDEDITLABELNOW=0x1116 +TVM_GETISEARCHSTRINGA=0x1117 +TVM_SETTOOLTIPS=0x1118 +TVM_GETTOOLTIPS=0x1119 +TVM_SETINSERTMARK=0x111A +TVM_SETITEMHEIGHT=0x111B +TVM_GETITEMHEIGHT=0x111C +TVM_SETBKCOLOR=0x111D +TVM_SETTEXTCOLOR=0x111E +TVM_GETTEXTCOLOR=0x1120 +TVM_SETSCROLLTIME=0x1121 +TVM_GETSCROLLTIME=0x1122 +TVM_SETINSERTMARKCOLOR=0x1125 +TVM_GETINSERTMARKCOLOR=0x1126 +TVM_GETITEMSTATE=0x1127 +TVM_SETLINECOLOR=0x1128 +TVM_GETLINECOLOR=0x1129 +TVM_MAPACCIDTOHTREEITEM=0x112A +TVM_MAPHTREEITEMTOACCID=0x112B +TVM_SETEXTENDEDSTYLE=0x112C +TVM_GETEXTENDEDSTYLE=0x112D +TVM_GETBKCOLOR=0x112F +TVM_SETAUTOSCROLLINFO=0x113B +TVM_GETITEMW=0x113E +TVM_SETITEMW=0x113F +TVM_GETISEARCHSTRINGW=0x1140 +TVM_EDITLABELW=0x1141 +TVM_INSERTITEMW=0x1142 +TVM_GETSELECTEDCOUNT=0x1146 +TVM_SHOWINFOTIP=0x1147 +TVM_GETITEMPARTRECT=0x1148 +TVM_SETUNICODEFORMAT=0x2005 +TVM_GETUNICODEFORMAT=0x2006 + +[msctls_updown32] +UDM_SETRANGE=0x0465 +UDM_GETRANGE=0x0466 +UDM_SETPOS=0x0467 +UDM_GETPOS=0x0468 +UDM_SETBUDDY=0x0469 +UDM_GETBUDDY=0x046A +UDM_SETACCEL=0x046B +UDM_GETACCEL=0x046C +UDM_SETBASE=0x046D +UDM_GETBASE=0x046E +UDM_SETRANGE32=0x046F +UDM_GETRANGE32=0x0470 +UDM_SETPOS32=0x0471 +UDM_GETPOS32=0x0472 +UDM_SETUNICODEFORMAT=0x2005 +UDM_GETUNICODEFORMAT=0x2006 + +[CommonControls] +CCM_SETBKCOLOR=0x2001 +CCM_SETCOLORSCHEME=0x2002 +CCM_GETCOLORSCHEME=0x2003 +CCM_GETDROPTARGET=0x2004 +CCM_SETUNICODEFORMAT=0x2005 +CCM_GETUNICODEFORMAT=0x2006 +CCM_SETVERSION=0x2007 +CCM_GETVERSION=0x2008 +CCM_SETNOTIFYWINDOW=0x2009 +CCM_SETWINDOWTHEME=0x200B +CCM_DPISCALE=0x200C + +[ComboBoxEx] +CBEM_DELETEITEM=0x0144 +CBEM_INSERTITEMA=0x0401 +CBEM_SETIMAGELIST=0x0402 +CBEM_GETIMAGELIST=0x0403 +CBEM_GETITEMA=0x0404 +CBEM_SETITEMA=0x0405 +CBEM_GETCOMBOCONTROL=0x0406 +CBEM_GETEDITCONTROL=0x0407 +CBEM_SETEXSTYLE=0x0408 +CBEM_GETEXSTYLE=0x0409 +CBEM_GETEXTENDEDSTYLE=0x0409 +CBEM_HASEDITCHANGED=0x040A +CBEM_INSERTITEMW=0x040B +CBEM_SETITEMW=0x040C +CBEM_GETITEMW=0x040D +CBEM_SETEXTENDEDSTYLE=0x040E +CBEM_SETUNICODEFORMAT=0x2004 +CBEM_GETUNICODEFORMAT=0x2005 +CBEM_SETWINDOWTHEME=0x200B + +[#32770] +DM_GETDEFID=0x400 +DM_SETDEFID=0x401 +DM_REPOSITION=0x402 + +[ScrollBar] +SBM_SETPOS=0xE0 +SBM_GETPOS=0xE1 +SBM_SETRANGE=0xE2 +SBM_GETRANGE=0xE3 +SBM_ENABLE_ARROWS=0xE4 +SBM_SETRANGEREDRAW=0xE6 +SBM_SETSCROLLINFO=0xE9 +SBM_GETSCROLLINFO=0xEA +SBM_GETSCROLLBARINFO=0xEB + +[SysAnimate32] +ACM_OPENA=0x464 +ACM_OPENW=0x467 +ACM_PLAY=0x465 +ACM_STOP=0x466 +ACM_ISPLAYING=0x468 + +[SysIPAddress32] +IPM_CLEARADDRESS=0x464 +IPM_SETADDRESS=0x465 +IPM_GETADDRESS=0x466 +IPM_SETRANGE=0x467 +IPM_SETFOCUS=0x468 +IPM_ISBLANK=0x469 + +[SysPager] +PGM_SETCHILD=0x1401 +PGM_RECALCSIZE=0x1402 +PGM_FORWARDMOUSE=0x1403 +PGM_SETBKCOLOR=0x1404 +PGM_GETBKCOLOR=0x1405 +PGM_SETBORDER=0x1406 +PGM_GETBORDER=0x1407 +PGM_SETPOS=0x1408 +PGM_GETPOS=0x1409 +PGM_SETBUTTONSIZE=0x140A +PGM_GETBUTTONSIZE=0x140B +PGM_GETBUTTONSTATE=0x140C +PGM_GETDROPTARGET=0x2004 + +[RICHEDIT50W] +EM_GETLIMITTEXT=0xD5 +EM_POSFROMCHAR=0xD6 +EM_CHARFROMPOS=0xD7 +EM_SCROLLCARET=0xB7 +EM_CANPASTE=0x432 +EM_DISPLAYBAND=0x433 +EM_EXGETSEL=0x434 +EM_EXLIMITTEXT=0x435 +EM_EXLINEFROMCHAR=0x436 +EM_EXSETSEL=0x437 +EM_FINDTEXT=0x438 +EM_FORMATRANGE=0x439 +EM_GETCHARFORMAT=0x43A +EM_GETEVENTMASK=0x43B +EM_GETOLEINTERFACE=0x43C +EM_GETPARAFORMAT=0x43D +EM_GETSELTEXT=0x43E +EM_HIDESELECTION=0x43F +EM_PASTESPECIAL=0x440 +EM_REQUESTRESIZE=0x441 +EM_SELECTIONTYPE=0x442 +EM_SETBKGNDCOLOR=0x443 +EM_SETCHARFORMAT=0x444 +EM_SETEVENTMASK=0x445 +EM_SETOLECALLBACK=0x446 +EM_SETPARAFORMAT=0x447 +EM_SETTARGETDEVICE=0x448 +EM_STREAMIN=0x449 +EM_STREAMOUT=0x44A +EM_GETTEXTRANGE=0x44B +EM_FINDWORDBREAK=0x44C +EM_SETOPTIONS=0x44D +EM_GETOPTIONS=0x44E +EM_FINDTEXTEX=0x44F +EM_GETWORDBREAKPROCEX=0x450 +EM_SETWORDBREAKPROCEX=0x451 +EM_SETUNDOLIMIT=0x452 +EM_REDO=0x454 +EM_CANREDO=0x455 +EM_GETUNDONAME=0x456 +EM_GETREDONAME=0x457 +EM_STOPGROUPTYPING=0x458 +EM_SETTEXTMODE=0x459 +EM_GETTEXTMODE=0x45A +EM_AUTOURLDETECT=0x45B +EM_GETAUTOURLDETECT=0x45C +EM_SETPALETTE=0x45D +EM_GETTEXTEX=0x45E +EM_GETTEXTLENGTHEX=0x45F +EM_SHOWSCROLLBAR=0x460 +EM_SETTEXTEX=0x461 +EM_SETPUNCTUATION=0x464 +EM_GETPUNCTUATION=0x465 +EM_SETWORDWRAPMODE=0x466 +EM_GETWORDWRAPMODE=0x467 +EM_SETIMECOLOR=0x468 +EM_GETIMECOLOR=0x469 +EM_SETIMEOPTIONS=0x46A +EM_GETIMEOPTIONS=0x46B +EM_CONVPOSITION=0x46C +EM_SETLANGOPTIONS=0x478 +EM_GETLANGOPTIONS=0x479 +EM_GETIMECOMPMODE=0x47A +EM_FINDTEXTW=0x47B +EM_FINDTEXTEXW=0x47C +EM_RECONVERSION=0x47D +EM_SETIMEMODEBIAS=0x47E +EM_GETIMEMODEBIAS=0x47F +EM_SETBIDIOPTIONS=0x4C8 +EM_GETBIDIOPTIONS=0x4C9 +EM_SETTYPOGRAPHYOPTIONS=0x4CA +EM_GETTYPOGRAPHYOPTIONS=0x4CB +EM_SETEDITSTYLE=0x4CC +EM_GETEDITSTYLE=0x4CD +EM_OUTLINE=0x4DC +EM_GETSCROLLPOS=0x4DD +EM_SETSCROLLPOS=0x4DE +EM_SETFONTSIZE=0x4DF +EM_GETZOOM=0x4E0 +EM_SETZOOM=0x4E1 +EM_GETVIEWKIND=0x4E2 +EM_SETVIEWKIND=0x4E3 +EM_GETPAGE=0x4E4 +EM_SETPAGE=0x4E5 +EM_GETHYPHENATEINFO=0x4E6 +EM_SETHYPHENATEINFO=0x4E7 +EM_GETPAGEROTATE=0x4EB +EM_SETPAGEROTATE=0x4EC +EM_GETCTFMODEBIAS=0x4ED +EM_SETCTFMODEBIAS=0x4EE +EM_GETCTFOPENSTATUS=0x4F0 +EM_SETCTFOPENSTATUS=0x4F1 +EM_GETIMECOMPTEXT=0x4F2 +EM_ISIME=0x4F3 +EM_GETIMEPROPERTY=0x4F4 +EM_GETQUERYRTFOBJ=0x50D +EM_SETQUERYRTFOBJ=0x50E + +[Scintilla] +SCI_START=2000 +SCI_OPTIONAL_START=3000 +SCI_LEXER_START=4000 +SCI_ADDTEXT=2001 +SCI_ADDSTYLEDTEXT=2002 +SCI_INSERTTEXT=2003 +SCI_CHANGEINSERTION=2672 +SCI_CLEARALL=2004 +SCI_DELETERANGE=2645 +SCI_CLEARDOCUMENTSTYLE=2005 +SCI_GETLENGTH=2006 +SCI_GETCHARAT=2007 +SCI_GETCURRENTPOS=2008 +SCI_GETANCHOR=2009 +SCI_GETSTYLEAT=2010 +SCI_REDO=2011 +SCI_SETUNDOCOLLECTION=2012 +SCI_SELECTALL=2013 +SCI_SETSAVEPOINT=2014 +SCI_GETSTYLEDTEXT=2015 +SCI_CANREDO=2016 +SCI_MARKERLINEFROMHANDLE=2017 +SCI_MARKERDELETEHANDLE=2018 +SCI_GETUNDOCOLLECTION=2019 +SCI_GETVIEWWS=2020 +SCI_SETVIEWWS=2021 +SCI_GETTABDRAWMODE=2698 +SCI_SETTABDRAWMODE=2699 +SCI_POSITIONFROMPOINT=2022 +SCI_POSITIONFROMPOINTCLOSE=2023 +SCI_GOTOLINE=2024 +SCI_GOTOPOS=2025 +SCI_SETANCHOR=2026 +SCI_GETCURLINE=2027 +SCI_GETENDSTYLED=2028 +SCI_CONVERTEOLS=2029 +SCI_GETEOLMODE=2030 +SCI_SETEOLMODE=2031 +SCI_STARTSTYLING=2032 +SCI_SETSTYLING=2033 +SCI_GETBUFFEREDDRAW=2034 +SCI_SETBUFFEREDDRAW=2035 +SCI_SETTABWIDTH=2036 +SCI_GETTABWIDTH=2121 +SCI_CLEARTABSTOPS=2675 +SCI_ADDTABSTOP=2676 +SCI_GETNEXTTABSTOP=2677 +SCI_SETCODEPAGE=2037 +SCI_GETIMEINTERACTION=2678 +SCI_SETIMEINTERACTION=2679 +SCI_MARKERDEFINE=2040 +SCI_MARKERSETFORE=2041 +SCI_MARKERSETBACK=2042 +SCI_MARKERSETBACKSELECTED=2292 +SCI_MARKERENABLEHIGHLIGHT=2293 +SCI_MARKERADD=2043 +SCI_MARKERDELETE=2044 +SCI_MARKERDELETEALL=2045 +SCI_MARKERGET=2046 +SCI_MARKERNEXT=2047 +SCI_MARKERPREVIOUS=2048 +SCI_MARKERDEFINEPIXMAP=2049 +SCI_MARKERADDSET=2466 +SCI_MARKERSETALPHA=2476 +SCI_SETMARGINTYPEN=2240 +SCI_GETMARGINTYPEN=2241 +SCI_SETMARGINWIDTHN=2242 +SCI_GETMARGINWIDTHN=2243 +SCI_SETMARGINMASKN=2244 +SCI_GETMARGINMASKN=2245 +SCI_SETMARGINSENSITIVEN=2246 +SCI_GETMARGINSENSITIVEN=2247 +SCI_SETMARGINCURSORN=2248 +SCI_GETMARGINCURSORN=2249 +SCI_SETMARGINBACKN=2250 +SCI_GETMARGINBACKN=2251 +SCI_SETMARGINS=2252 +SCI_GETMARGINS=2253 +SCI_STYLECLEARALL=2050 +SCI_STYLESETFORE=2051 +SCI_STYLESETBACK=2052 +SCI_STYLESETBOLD=2053 +SCI_STYLESETITALIC=2054 +SCI_STYLESETSIZE=2055 +SCI_STYLESETFONT=2056 +SCI_STYLESETEOLFILLED=2057 +SCI_STYLERESETDEFAULT=2058 +SCI_STYLESETUNDERLINE=2059 +SCI_STYLEGETFORE=2481 +SCI_STYLEGETBACK=2482 +SCI_STYLEGETBOLD=2483 +SCI_STYLEGETITALIC=2484 +SCI_STYLEGETSIZE=2485 +SCI_STYLEGETFONT=2486 +SCI_STYLEGETEOLFILLED=2487 +SCI_STYLEGETUNDERLINE=2488 +SCI_STYLEGETCASE=2489 +SCI_STYLEGETCHARACTERSET=2490 +SCI_STYLEGETVISIBLE=2491 +SCI_STYLEGETCHANGEABLE=2492 +SCI_STYLEGETHOTSPOT=2493 +SCI_STYLESETCASE=2060 +SCI_STYLESETSIZEFRACTIONAL=2061 +SCI_STYLEGETSIZEFRACTIONAL=2062 +SCI_STYLESETWEIGHT=2063 +SCI_STYLEGETWEIGHT=2064 +SCI_STYLESETCHARACTERSET=2066 +SCI_STYLESETHOTSPOT=2409 +SCI_SETSELFORE=2067 +SCI_SETSELBACK=2068 +SCI_GETSELALPHA=2477 +SCI_SETSELALPHA=2478 +SCI_GETSELEOLFILLED=2479 +SCI_SETSELEOLFILLED=2480 +SCI_SETCARETFORE=2069 +SCI_ASSIGNCMDKEY=2070 +SCI_CLEARCMDKEY=2071 +SCI_CLEARALLCMDKEYS=2072 +SCI_SETSTYLINGEX=2073 +SCI_STYLESETVISIBLE=2074 +SCI_GETCARETPERIOD=2075 +SCI_SETCARETPERIOD=2076 +SCI_SETWORDCHARS=2077 +SCI_GETWORDCHARS=2646 +SCI_BEGINUNDOACTION=2078 +SCI_ENDUNDOACTION=2079 +SCI_INDICSETSTYLE=2080 +SCI_INDICGETSTYLE=2081 +SCI_INDICSETFORE=2082 +SCI_INDICGETFORE=2083 +SCI_INDICSETUNDER=2510 +SCI_INDICGETUNDER=2511 +SCI_INDICSETHOVERSTYLE=2680 +SCI_INDICGETHOVERSTYLE=2681 +SCI_INDICSETHOVERFORE=2682 +SCI_INDICGETHOVERFORE=2683 +SCI_INDICSETFLAGS=2684 +SCI_INDICGETFLAGS=2685 +SCI_SETWHITESPACEFORE=2084 +SCI_SETWHITESPACEBACK=2085 +SCI_SETWHITESPACESIZE=2086 +SCI_GETWHITESPACESIZE=2087 +SCI_SETSTYLEBITS=2090 +SCI_GETSTYLEBITS=2091 +SCI_SETLINESTATE=2092 +SCI_GETLINESTATE=2093 +SCI_GETMAXLINESTATE=2094 +SCI_GETCARETLINEVISIBLE=2095 +SCI_SETCARETLINEVISIBLE=2096 +SCI_GETCARETLINEBACK=2097 +SCI_SETCARETLINEBACK=2098 +SCI_GETCARETLINEFRAME=2704 +SCI_SETCARETLINEFRAME=2705 +SCI_STYLESETCHANGEABLE=2099 +SCI_AUTOCSHOW=2100 +SCI_AUTOCCANCEL=2101 +SCI_AUTOCACTIVE=2102 +SCI_AUTOCPOSSTART=2103 +SCI_AUTOCCOMPLETE=2104 +SCI_AUTOCSTOPS=2105 +SCI_AUTOCSETSEPARATOR=2106 +SCI_AUTOCGETSEPARATOR=2107 +SCI_AUTOCSELECT=2108 +SCI_AUTOCSETCANCELATSTART=2110 +SCI_AUTOCGETCANCELATSTART=2111 +SCI_AUTOCSETFILLUPS=2112 +SCI_AUTOCSETCHOOSESINGLE=2113 +SCI_AUTOCGETCHOOSESINGLE=2114 +SCI_AUTOCSETIGNORECASE=2115 +SCI_AUTOCGETIGNORECASE=2116 +SCI_USERLISTSHOW=2117 +SCI_AUTOCSETAUTOHIDE=2118 +SCI_AUTOCGETAUTOHIDE=2119 +SCI_AUTOCSETDROPRESTOFWORD=2270 +SCI_AUTOCGETDROPRESTOFWORD=2271 +SCI_REGISTERIMAGE=2405 +SCI_CLEARREGISTEREDIMAGES=2408 +SCI_AUTOCGETTYPESEPARATOR=2285 +SCI_AUTOCSETTYPESEPARATOR=2286 +SCI_AUTOCSETMAXWIDTH=2208 +SCI_AUTOCGETMAXWIDTH=2209 +SCI_AUTOCSETMAXHEIGHT=2210 +SCI_AUTOCGETMAXHEIGHT=2211 +SCI_SETINDENT=2122 +SCI_GETINDENT=2123 +SCI_SETUSETABS=2124 +SCI_GETUSETABS=2125 +SCI_SETLINEINDENTATION=2126 +SCI_GETLINEINDENTATION=2127 +SCI_GETLINEINDENTPOSITION=2128 +SCI_GETCOLUMN=2129 +SCI_COUNTCHARACTERS=2633 +SCI_SETHSCROLLBAR=2130 +SCI_GETHSCROLLBAR=2131 +SCI_SETINDENTATIONGUIDES=2132 +SCI_GETINDENTATIONGUIDES=2133 +SCI_SETHIGHLIGHTGUIDE=2134 +SCI_GETHIGHLIGHTGUIDE=2135 +SCI_GETLINEENDPOSITION=2136 +SCI_GETCODEPAGE=2137 +SCI_GETCARETFORE=2138 +SCI_GETREADONLY=2140 +SCI_SETCURRENTPOS=2141 +SCI_SETSELECTIONSTART=2142 +SCI_GETSELECTIONSTART=2143 +SCI_SETSELECTIONEND=2144 +SCI_GETSELECTIONEND=2145 +SCI_SETEMPTYSELECTION=2556 +SCI_SETPRINTMAGNIFICATION=2146 +SCI_GETPRINTMAGNIFICATION=2147 +SCI_SETPRINTCOLOURMODE=2148 +SCI_GETPRINTCOLOURMODE=2149 +SCI_FINDTEXT=2150 +SCI_FORMATRANGE=2151 +SCI_GETFIRSTVISIBLELINE=2152 +SCI_GETLINE=2153 +SCI_GETLINECOUNT=2154 +SCI_SETMARGINLEFT=2155 +SCI_GETMARGINLEFT=2156 +SCI_SETMARGINRIGHT=2157 +SCI_GETMARGINRIGHT=2158 +SCI_GETMODIFY=2159 +SCI_SETSEL=2160 +SCI_GETSELTEXT=2161 +SCI_GETTEXTRANGE=2162 +SCI_HIDESELECTION=2163 +SCI_POINTXFROMPOSITION=2164 +SCI_POINTYFROMPOSITION=2165 +SCI_LINEFROMPOSITION=2166 +SCI_POSITIONFROMLINE=2167 +SCI_LINESCROLL=2168 +SCI_SCROLLCARET=2169 +SCI_SCROLLRANGE=2569 +SCI_REPLACESEL=2170 +SCI_SETREADONLY=2171 +SCI_NULL=2172 +SCI_CANPASTE=2173 +SCI_CANUNDO=2174 +SCI_EMPTYUNDOBUFFER=2175 +SCI_UNDO=2176 +SCI_CUT=2177 +SCI_COPY=2178 +SCI_PASTE=2179 +SCI_CLEAR=2180 +SCI_SETTEXT=2181 +SCI_GETTEXT=2182 +SCI_GETTEXTLENGTH=2183 +SCI_GETDIRECTFUNCTION=2184 +SCI_GETDIRECTPOINTER=2185 +SCI_SETOVERTYPE=2186 +SCI_GETOVERTYPE=2187 +SCI_SETCARETWIDTH=2188 +SCI_GETCARETWIDTH=2189 +SCI_SETTARGETSTART=2190 +SCI_GETTARGETSTART=2191 +SCI_SETTARGETEND=2192 +SCI_GETTARGETEND=2193 +SCI_SETTARGETRANGE=2686 +SCI_GETTARGETTEXT=2687 +SCI_TARGETFROMSELECTION=2287 +SCI_TARGETWHOLEDOCUMENT=2690 +SCI_REPLACETARGET=2194 +SCI_REPLACETARGETRE=2195 +SCI_SEARCHINTARGET=2197 +SCI_SETSEARCHFLAGS=2198 +SCI_GETSEARCHFLAGS=2199 +SCI_CALLTIPSHOW=2200 +SCI_CALLTIPCANCEL=2201 +SCI_CALLTIPACTIVE=2202 +SCI_CALLTIPPOSSTART=2203 +SCI_CALLTIPSETPOSSTART=2214 +SCI_CALLTIPSETHLT=2204 +SCI_CALLTIPSETBACK=2205 +SCI_CALLTIPSETFORE=2206 +SCI_CALLTIPSETFOREHLT=2207 +SCI_CALLTIPUSESTYLE=2212 +SCI_CALLTIPSETPOSITION=2213 +SCI_VISIBLEFROMDOCLINE=2220 +SCI_DOCLINEFROMVISIBLE=2221 +SCI_WRAPCOUNT=2235 +SCI_SETFOLDLEVEL=2222 +SCI_GETFOLDLEVEL=2223 +SCI_GETLASTCHILD=2224 +SCI_GETFOLDPARENT=2225 +SCI_SHOWLINES=2226 +SCI_HIDELINES=2227 +SCI_GETLINEVISIBLE=2228 +SCI_GETALLLINESVISIBLE=2236 +SCI_SETFOLDEXPANDED=2229 +SCI_GETFOLDEXPANDED=2230 +SCI_TOGGLEFOLD=2231 +SCI_TOGGLEFOLDSHOWTEXT=2700 +SCI_FOLDDISPLAYTEXTSETSTYLE=2701 +SCI_FOLDLINE=2237 +SCI_FOLDCHILDREN=2238 +SCI_EXPANDCHILDREN=2239 +SCI_FOLDALL=2662 +SCI_ENSUREVISIBLE=2232 +SCI_SETAUTOMATICFOLD=2663 +SCI_GETAUTOMATICFOLD=2664 +SCI_SETFOLDFLAGS=2233 +SCI_ENSUREVISIBLEENFORCEPOLICY=2234 +SCI_SETTABINDENTS=2260 +SCI_GETTABINDENTS=2261 +SCI_SETBACKSPACEUNINDENTS=2262 +SCI_GETBACKSPACEUNINDENTS=2263 +SCI_SETMOUSEDWELLTIME=2264 +SCI_GETMOUSEDWELLTIME=2265 +SCI_WORDSTARTPOSITION=2266 +SCI_WORDENDPOSITION=2267 +SCI_ISRANGEWORD=2691 +SCI_SETIDLESTYLING=2692 +SCI_GETIDLESTYLING=2693 +SCI_SETWRAPMODE=2268 +SCI_GETWRAPMODE=2269 +SCI_SETWRAPVISUALFLAGS=2460 +SCI_GETWRAPVISUALFLAGS=2461 +SCI_SETWRAPVISUALFLAGSLOCATION=2462 +SCI_GETWRAPVISUALFLAGSLOCATION=2463 +SCI_SETWRAPSTARTINDENT=2464 +SCI_GETWRAPSTARTINDENT=2465 +SCI_SETWRAPINDENTMODE=2472 +SCI_GETWRAPINDENTMODE=2473 +SCI_SETLAYOUTCACHE=2272 +SCI_GETLAYOUTCACHE=2273 +SCI_SETSCROLLWIDTH=2274 +SCI_GETSCROLLWIDTH=2275 +SCI_SETSCROLLWIDTHTRACKING=2516 +SCI_GETSCROLLWIDTHTRACKING=2517 +SCI_TEXTWIDTH=2276 +SCI_SETENDATLASTLINE=2277 +SCI_GETENDATLASTLINE=2278 +SCI_TEXTHEIGHT=2279 +SCI_SETVSCROLLBAR=2280 +SCI_GETVSCROLLBAR=2281 +SCI_APPENDTEXT=2282 +SCI_GETTWOPHASEDRAW=2283 +SCI_SETTWOPHASEDRAW=2284 +SCI_GETPHASESDRAW=2673 +SCI_SETPHASESDRAW=2674 +SCI_SETFONTQUALITY=2611 +SCI_GETFONTQUALITY=2612 +SCI_SETFIRSTVISIBLELINE=2613 +SCI_SETMULTIPASTE=2614 +SCI_GETMULTIPASTE=2615 +SCI_GETTAG=2616 +SCI_LINESJOIN=2288 +SCI_LINESSPLIT=2289 +SCI_SETFOLDMARGINCOLOUR=2290 +SCI_SETFOLDMARGINHICOLOUR=2291 +SCI_SETACCESSIBILITY=2702 +SCI_GETACCESSIBILITY=2703 +SCI_LINEDOWN=2300 +SCI_LINEDOWNEXTEND=2301 +SCI_LINEUP=2302 +SCI_LINEUPEXTEND=2303 +SCI_CHARLEFT=2304 +SCI_CHARLEFTEXTEND=2305 +SCI_CHARRIGHT=2306 +SCI_CHARRIGHTEXTEND=2307 +SCI_WORDLEFT=2308 +SCI_WORDLEFTEXTEND=2309 +SCI_WORDRIGHT=2310 +SCI_WORDRIGHTEXTEND=2311 +SCI_HOME=2312 +SCI_HOMEEXTEND=2313 +SCI_LINEEND=2314 +SCI_LINEENDEXTEND=2315 +SCI_DOCUMENTSTART=2316 +SCI_DOCUMENTSTARTEXTEND=2317 +SCI_DOCUMENTEND=2318 +SCI_DOCUMENTENDEXTEND=2319 +SCI_PAGEUP=2320 +SCI_PAGEUPEXTEND=2321 +SCI_PAGEDOWN=2322 +SCI_PAGEDOWNEXTEND=2323 +SCI_EDITTOGGLEOVERTYPE=2324 +SCI_CANCEL=2325 +SCI_DELETEBACK=2326 +SCI_TAB=2327 +SCI_BACKTAB=2328 +SCI_NEWLINE=2329 +SCI_FORMFEED=2330 +SCI_VCHOME=2331 +SCI_VCHOMEEXTEND=2332 +SCI_ZOOMIN=2333 +SCI_ZOOMOUT=2334 +SCI_DELWORDLEFT=2335 +SCI_DELWORDRIGHT=2336 +SCI_DELWORDRIGHTEND=2518 +SCI_LINECUT=2337 +SCI_LINEDELETE=2338 +SCI_LINETRANSPOSE=2339 +SCI_LINEREVERSE=2354 +SCI_LINEDUPLICATE=2404 +SCI_LOWERCASE=2340 +SCI_UPPERCASE=2341 +SCI_LINESCROLLDOWN=2342 +SCI_LINESCROLLUP=2343 +SCI_DELETEBACKNOTLINE=2344 +SCI_HOMEDISPLAY=2345 +SCI_HOMEDISPLAYEXTEND=2346 +SCI_LINEENDDISPLAY=2347 +SCI_LINEENDDISPLAYEXTEND=2348 +SCI_HOMEWRAP=2349 +SCI_HOMEWRAPEXTEND=2450 +SCI_LINEENDWRAP=2451 +SCI_LINEENDWRAPEXTEND=2452 +SCI_VCHOMEWRAP=2453 +SCI_VCHOMEWRAPEXTEND=2454 +SCI_LINECOPY=2455 +SCI_MOVECARETINSIDEVIEW=2401 +SCI_LINELENGTH=2350 +SCI_BRACEHIGHLIGHT=2351 +SCI_BRACEHIGHLIGHTINDICATOR=2498 +SCI_BRACEBADLIGHT=2352 +SCI_BRACEBADLIGHTINDICATOR=2499 +SCI_BRACEMATCH=2353 +SCI_GETVIEWEOL=2355 +SCI_SETVIEWEOL=2356 +SCI_GETDOCPOINTER=2357 +SCI_SETDOCPOINTER=2358 +SCI_SETMODEVENTMASK=2359 +SCI_GETEDGECOLUMN=2360 +SCI_SETEDGECOLUMN=2361 +SCI_GETEDGEMODE=2362 +SCI_SETEDGEMODE=2363 +SCI_GETEDGECOLOUR=2364 +SCI_SETEDGECOLOUR=2365 +SCI_MULTIEDGEADDLINE=2694 +SCI_MULTIEDGECLEARALL=2695 +SCI_SEARCHANCHOR=2366 +SCI_SEARCHNEXT=2367 +SCI_SEARCHPREV=2368 +SCI_LINESONSCREEN=2370 +SCI_USEPOPUP=2371 +SCI_SELECTIONISRECTANGLE=2372 +SCI_SETZOOM=2373 +SCI_GETZOOM=2374 +SCI_CREATEDOCUMENT=2375 +SCI_ADDREFDOCUMENT=2376 +SCI_RELEASEDOCUMENT=2377 +SCI_GETMODEVENTMASK=2378 +SCI_SETFOCUS=2380 +SCI_GETFOCUS=2381 +SCI_SETSTATUS=2382 +SCI_GETSTATUS=2383 +SCI_SETMOUSEDOWNCAPTURES=2384 +SCI_GETMOUSEDOWNCAPTURES=2385 +SCI_SETMOUSEWHEELCAPTURES=2696 +SCI_GETMOUSEWHEELCAPTURES=2697 +SCI_SETCURSOR=2386 +SCI_GETCURSOR=2387 +SCI_SETCONTROLCHARSYMBOL=2388 +SCI_GETCONTROLCHARSYMBOL=2389 +SCI_WORDPARTLEFT=2390 +SCI_WORDPARTLEFTEXTEND=2391 +SCI_WORDPARTRIGHT=2392 +SCI_WORDPARTRIGHTEXTEND=2393 +SCI_SETVISIBLEPOLICY=2394 +SCI_DELLINELEFT=2395 +SCI_DELLINERIGHT=2396 +SCI_SETXOFFSET=2397 +SCI_GETXOFFSET=2398 +SCI_CHOOSECARETX=2399 +SCI_GRABFOCUS=2400 +SCI_SETXCARETPOLICY=2402 +SCI_SETYCARETPOLICY=2403 +SCI_SETPRINTWRAPMODE=2406 +SCI_GETPRINTWRAPMODE=2407 +SCI_SETHOTSPOTACTIVEFORE=2410 +SCI_GETHOTSPOTACTIVEFORE=2494 +SCI_SETHOTSPOTACTIVEBACK=2411 +SCI_GETHOTSPOTACTIVEBACK=2495 +SCI_SETHOTSPOTACTIVEUNDERLINE=2412 +SCI_GETHOTSPOTACTIVEUNDERLINE=2496 +SCI_SETHOTSPOTSINGLELINE=2421 +SCI_GETHOTSPOTSINGLELINE=2497 +SCI_PARADOWN=2413 +SCI_PARADOWNEXTEND=2414 +SCI_PARAUP=2415 +SCI_PARAUPEXTEND=2416 +SCI_POSITIONBEFORE=2417 +SCI_POSITIONAFTER=2418 +SCI_POSITIONRELATIVE=2670 +SCI_COPYRANGE=2419 +SCI_COPYTEXT=2420 +SCI_SETSELECTIONMODE=2422 +SCI_GETSELECTIONMODE=2423 +SCI_GETLINESELSTARTPOSITION=2424 +SCI_GETLINESELENDPOSITION=2425 +SCI_LINEDOWNRECTEXTEND=2426 +SCI_LINEUPRECTEXTEND=2427 +SCI_CHARLEFTRECTEXTEND=2428 +SCI_CHARRIGHTRECTEXTEND=2429 +SCI_HOMERECTEXTEND=2430 +SCI_VCHOMERECTEXTEND=2431 +SCI_LINEENDRECTEXTEND=2432 +SCI_PAGEUPRECTEXTEND=2433 +SCI_PAGEDOWNRECTEXTEND=2434 +SCI_STUTTEREDPAGEUP=2435 +SCI_STUTTEREDPAGEUPEXTEND=2436 +SCI_STUTTEREDPAGEDOWN=2437 +SCI_STUTTEREDPAGEDOWNEXTEND=2438 +SCI_WORDLEFTEND=2439 +SCI_WORDLEFTENDEXTEND=2440 +SCI_WORDRIGHTEND=2441 +SCI_WORDRIGHTENDEXTEND=2442 +SCI_SETWHITESPACECHARS=2443 +SCI_GETWHITESPACECHARS=2647 +SCI_SETPUNCTUATIONCHARS=2648 +SCI_GETPUNCTUATIONCHARS=2649 +SCI_SETCHARSDEFAULT=2444 +SCI_AUTOCGETCURRENT=2445 +SCI_AUTOCGETCURRENTTEXT=2610 +SCI_AUTOCSETCASEINSENSITIVEBEHAVIOUR=2634 +SCI_AUTOCGETCASEINSENSITIVEBEHAVIOUR=2635 +SCI_AUTOCSETMULTI=2636 +SCI_AUTOCGETMULTI=2637 +SCI_AUTOCSETORDER=2660 +SCI_AUTOCGETORDER=2661 +SCI_ALLOCATE=2446 +SCI_TARGETASUTF8=2447 +SCI_SETLENGTHFORENCODE=2448 +SCI_ENCODEDFROMUTF8=2449 +SCI_FINDCOLUMN=2456 +SCI_GETCARETSTICKY=2457 +SCI_SETCARETSTICKY=2458 +SCI_TOGGLECARETSTICKY=2459 +SCI_SETPASTECONVERTENDINGS=2467 +SCI_GETPASTECONVERTENDINGS=2468 +SCI_SELECTIONDUPLICATE=2469 +SCI_SETCARETLINEBACKALPHA=2470 +SCI_GETCARETLINEBACKALPHA=2471 +SCI_SETCARETSTYLE=2512 +SCI_GETCARETSTYLE=2513 +SCI_SETINDICATORCURRENT=2500 +SCI_GETINDICATORCURRENT=2501 +SCI_SETINDICATORVALUE=2502 +SCI_GETINDICATORVALUE=2503 +SCI_INDICATORFILLRANGE=2504 +SCI_INDICATORCLEARRANGE=2505 +SCI_INDICATORALLONFOR=2506 +SCI_INDICATORVALUEAT=2507 +SCI_INDICATORSTART=2508 +SCI_INDICATOREND=2509 +SCI_SETPOSITIONCACHE=2514 +SCI_GETPOSITIONCACHE=2515 +SCI_COPYALLOWLINE=2519 +SCI_GETCHARACTERPOINTER=2520 +SCI_GETRANGEPOINTER=2643 +SCI_GETGAPPOSITION=2644 +SCI_INDICSETALPHA=2523 +SCI_INDICGETALPHA=2524 +SCI_INDICSETOUTLINEALPHA=2558 +SCI_INDICGETOUTLINEALPHA=2559 +SCI_SETEXTRAASCENT=2525 +SCI_GETEXTRAASCENT=2526 +SCI_SETEXTRADESCENT=2527 +SCI_GETEXTRADESCENT=2528 +SCI_MARKERSYMBOLDEFINED=2529 +SCI_MARGINSETTEXT=2530 +SCI_MARGINGETTEXT=2531 +SCI_MARGINSETSTYLE=2532 +SCI_MARGINGETSTYLE=2533 +SCI_MARGINSETSTYLES=2534 +SCI_MARGINGETSTYLES=2535 +SCI_MARGINTEXTCLEARALL=2536 +SCI_MARGINSETSTYLEOFFSET=2537 +SCI_MARGINGETSTYLEOFFSET=2538 +SCI_SETMARGINOPTIONS=2539 +SCI_GETMARGINOPTIONS=2557 +SCI_ANNOTATIONSETTEXT=2540 +SCI_ANNOTATIONGETTEXT=2541 +SCI_ANNOTATIONSETSTYLE=2542 +SCI_ANNOTATIONGETSTYLE=2543 +SCI_ANNOTATIONSETSTYLES=2544 +SCI_ANNOTATIONGETSTYLES=2545 +SCI_ANNOTATIONGETLINES=2546 +SCI_ANNOTATIONCLEARALL=2547 +SCI_ANNOTATIONSETVISIBLE=2548 +SCI_ANNOTATIONGETVISIBLE=2549 +SCI_ANNOTATIONSETSTYLEOFFSET=2550 +SCI_ANNOTATIONGETSTYLEOFFSET=2551 +SCI_RELEASEALLEXTENDEDSTYLES=2552 +SCI_ALLOCATEEXTENDEDSTYLES=2553 +SCI_ADDUNDOACTION=2560 +SCI_CHARPOSITIONFROMPOINT=2561 +SCI_CHARPOSITIONFROMPOINTCLOSE=2562 +SCI_SETMOUSESELECTIONRECTANGULARSWITCH=2668 +SCI_GETMOUSESELECTIONRECTANGULARSWITCH=2669 +SCI_SETMULTIPLESELECTION=2563 +SCI_GETMULTIPLESELECTION=2564 +SCI_SETADDITIONALSELECTIONTYPING=2565 +SCI_GETADDITIONALSELECTIONTYPING=2566 +SCI_SETADDITIONALCARETSBLINK=2567 +SCI_GETADDITIONALCARETSBLINK=2568 +SCI_SETADDITIONALCARETSVISIBLE=2608 +SCI_GETADDITIONALCARETSVISIBLE=2609 +SCI_GETSELECTIONS=2570 +SCI_GETSELECTIONEMPTY=2650 +SCI_CLEARSELECTIONS=2571 +SCI_SETSELECTION=2572 +SCI_ADDSELECTION=2573 +SCI_DROPSELECTIONN=2671 +SCI_SETMAINSELECTION=2574 +SCI_GETMAINSELECTION=2575 +SCI_SETSELECTIONNCARET=2576 +SCI_GETSELECTIONNCARET=2577 +SCI_SETSELECTIONNANCHOR=2578 +SCI_GETSELECTIONNANCHOR=2579 +SCI_SETSELECTIONNCARETVIRTUALSPACE=2580 +SCI_GETSELECTIONNCARETVIRTUALSPACE=2581 +SCI_SETSELECTIONNANCHORVIRTUALSPACE=2582 +SCI_GETSELECTIONNANCHORVIRTUALSPACE=2583 +SCI_SETSELECTIONNSTART=2584 +SCI_GETSELECTIONNSTART=2585 +SCI_SETSELECTIONNEND=2586 +SCI_GETSELECTIONNEND=2587 +SCI_SETRECTANGULARSELECTIONCARET=2588 +SCI_GETRECTANGULARSELECTIONCARET=2589 +SCI_SETRECTANGULARSELECTIONANCHOR=2590 +SCI_GETRECTANGULARSELECTIONANCHOR=2591 +SCI_SETRECTANGULARSELECTIONCARETVIRTUALSPACE=2592 +SCI_GETRECTANGULARSELECTIONCARETVIRTUALSPACE=2593 +SCI_SETRECTANGULARSELECTIONANCHORVIRTUALSPACE=2594 +SCI_GETRECTANGULARSELECTIONANCHORVIRTUALSPACE=2595 +SCI_SETVIRTUALSPACEOPTIONS=2596 +SCI_GETVIRTUALSPACEOPTIONS=2597 +SCI_SETRECTANGULARSELECTIONMODIFIER=2598 +SCI_GETRECTANGULARSELECTIONMODIFIER=2599 +SCI_SETADDITIONALSELFORE=2600 +SCI_SETADDITIONALSELBACK=2601 +SCI_SETADDITIONALSELALPHA=2602 +SCI_GETADDITIONALSELALPHA=2603 +SCI_SETADDITIONALCARETFORE=2604 +SCI_GETADDITIONALCARETFORE=2605 +SCI_ROTATESELECTION=2606 +SCI_SWAPMAINANCHORCARET=2607 +SCI_MULTIPLESELECTADDNEXT=2688 +SCI_MULTIPLESELECTADDEACH=2689 +SCI_CHANGELEXERSTATE=2617 +SCI_CONTRACTEDFOLDNEXT=2618 +SCI_VERTICALCENTRECARET=2619 +SCI_MOVESELECTEDLINESUP=2620 +SCI_MOVESELECTEDLINESDOWN=2621 +SCI_SETIDENTIFIER=2622 +SCI_GETIDENTIFIER=2623 +SCI_RGBAIMAGESETWIDTH=2624 +SCI_RGBAIMAGESETHEIGHT=2625 +SCI_RGBAIMAGESETSCALE=2651 +SCI_MARKERDEFINERGBAIMAGE=2626 +SCI_REGISTERRGBAIMAGE=2627 +SCI_SCROLLTOSTART=2628 +SCI_SCROLLTOEND=2629 +SCI_SETTECHNOLOGY=2630 +SCI_GETTECHNOLOGY=2631 +SCI_CREATELOADER=2632 +SCI_FINDINDICATORSHOW=2640 +SCI_FINDINDICATORFLASH=2641 +SCI_FINDINDICATORHIDE=2642 +SCI_VCHOMEDISPLAY=2652 +SCI_VCHOMEDISPLAYEXTEND=2653 +SCI_GETCARETLINEVISIBLEALWAYS=2654 +SCI_SETCARETLINEVISIBLEALWAYS=2655 +SCI_SETLINEENDTYPESALLOWED=2656 +SCI_GETLINEENDTYPESALLOWED=2657 +SCI_GETLINEENDTYPESACTIVE=2658 +SCI_SETREPRESENTATION=2665 +SCI_GETREPRESENTATION=2666 +SCI_CLEARREPRESENTATION=2667 +SCI_STARTRECORD=3001 +SCI_STOPRECORD=3002 +SCI_SETLEXER=4001 +SCI_GETLEXER=4002 +SCI_COLOURISE=4003 +SCI_SETPROPERTY=4004 +SCI_SETKEYWORDS=4005 +SCI_SETLEXERLANGUAGE=4006 +SCI_LOADLEXERLIBRARY=4007 +SCI_GETPROPERTY=4008 +SCI_GETPROPERTYEXPANDED=4009 +SCI_GETPROPERTYINT=4010 +SCI_GETSTYLEBITSNEEDED=4011 +SCI_GETLEXERLANGUAGE=4012 +SCI_PRIVATELEXERCALL=4013 +SCI_PROPERTYNAMES=4014 +SCI_PROPERTYTYPE=4015 +SCI_DESCRIBEPROPERTY=4016 +SCI_DESCRIBEKEYWORDSETS=4017 +SCI_GETLINEENDTYPESSUPPORTED=4018 +SCI_ALLOCATESUBSTYLES=4020 +SCI_GETSUBSTYLESSTART=4021 +SCI_GETSUBSTYLESLENGTH=4022 +SCI_GETSTYLEFROMSUBSTYLE=4027 +SCI_GETPRIMARYSTYLEFROMSTYLE=4028 +SCI_FREESUBSTYLES=4023 +SCI_SETIDENTIFIERS=4024 +SCI_DISTANCETOSECONDARYSTYLES=4025 +SCI_GETSUBSTYLEBASES=4026 +SCI_SETKEYSUNICODE=2521 +SCI_GETKEYSUNICODE=2522 diff --git a/thirdparty/WinSpy/Constants/Styles.ini b/thirdparty/WinSpy/Constants/Styles.ini new file mode 100644 index 0000000..b469dea --- /dev/null +++ b/thirdparty/WinSpy/Constants/Styles.ini @@ -0,0 +1,468 @@ +[Window] +WS_OVERLAPPED|0x00000000|The window is an overlapped window. An overlapped window has a title bar and a border. Same as the WS_TILED style. +WS_MAXIMIZEBOX|0x00010000|The window has a maximize button. Cannot be combined with the WS_EX_CONTEXTHELP style. The WS_SYSMENU style must also be specified. +WS_TABSTOP|0x00010000|The window is a control that can receive the keyboard focus when the user presses the TAB key. Pressing the TAB key changes the keyboard focus to the next control with the WS_TABSTOP style.\n\nYou can turn this style on and off to change dialog box navigation. To change this style after a window has been created, use the SetWindowLong function. For user-created windows and modeless dialogs to work with tab stops, alter the message loop to call the IsDialogMessage function. +WS_MINIMIZEBOX|0x00020000|The window has a minimize button. Cannot be combined with the WS_EX_CONTEXTHELP style. The WS_SYSMENU style must also be specified. +WS_GROUP|0x00020000|The window is the first control of a group of controls. The group consists of this first control and all controls defined after it, up to the next control with the WS_GROUP style. The first control in each group usually has the WS_TABSTOP style so that the user can move from group to group. The user can subsequently change the keyboard focus from one control in the group to the next control in the group by using the direction keys.\n\nYou can turn this style on and off to change dialog box navigation. To change this style after a window has been created, use the SetWindowLong function. +WS_THICKFRAME|0x00040000|The window has a sizing border. Same as the WS_SIZEBOX style. +WS_SYSMENU|0x00080000|The window has a window menu on its title bar. The WS_CAPTION style must also be specified. +WS_HSCROLL|0x00100000|The window has a horizontal scroll bar. +WS_VSCROLL|0x00200000|The window has a vertical scroll bar. +WS_DLGFRAME|0x00400000|The window has a border of a style typically used with dialog boxes. A window with this style cannot have a title bar. +WS_BORDER|0x00800000|The window has a thin-line border. +WS_MAXIMIZE|0x01000000|The window is initially maximized. +WS_CLIPCHILDREN|0x02000000|Excludes the area occupied by child windows when drawing occurs within the parent window. This style is used when creating the parent window. +WS_CLIPSIBLINGS|0x04000000|Clips child windows relative to each other; that is, when a particular child window receives a WM_PAINT message, the WS_CLIPSIBLINGS style clips all other overlapping child windows out of the region of the child window to be updated. If WS_CLIPSIBLINGS is not specified and child windows overlap, it is possible, when drawing within the client area of a child window, to draw within the client area of a neighboring child window. +WS_DISABLED|0x08000000|The window is initially disabled. A disabled window cannot receive input from the user. To change this after a window has been created, use the EnableWindow function. +WS_VISIBLE|0x10000000|The window is initially visible. This style can be turned on and off by using the ShowWindow or SetWindowPos function. +WS_MINIMIZE|0x20000000|The window is initially minimized. Same as the WS_ICONIC style. +WS_CHILD|0x40000000|The window is a child window. A window with this style cannot have a menu bar. This style cannot be used with the WS_POPUP style. +WS_POPUP|0x80000000|The windows is a pop-up window. This style cannot be used with the WS_CHILD style. + +[WindowEx] +WS_EX_LEFT|0x00000000|The window has generic left-aligned properties. This is the default. +WS_EX_LTRREADING|0x00000000|The window text is displayed using left-to-right reading-order properties. This is the default. +WS_EX_RIGHTSCROLLBAR|0x00000000|The vertical scroll bar (if present) is to the right of the client area. This is the default. +WS_EX_DLGMODALFRAME|0x00000001|The window has a double border; the window can, optionally, be created with a title bar by specifying the WS_CAPTION style in the dwStyle parameter. +WS_EX_NOPARENTNOTIFY|0x00000004|The child window created with this style does not send the WM_PARENTNOTIFY message to its parent window when it is created or destroyed. +WS_EX_TOPMOST|0x00000008|The window should be placed above all non-topmost windows and should stay above them, even when the window is deactivated. +WS_EX_ACCEPTFILES|0x00000010|The window accepts drag-drop files. +WS_EX_TRANSPARENT|0x00000020|The window should not be painted until siblings beneath the window (that were created by the same thread) have been painted. The window appears transparent because the bits of underlying sibling windows have already been painted.\n\nTo achieve transparency without these restrictions, use the SetWindowRgn function. +WS_EX_MDICHILD|0x00000040|The window is a MDI child window. +WS_EX_TOOLWINDOW|0x00000080|The window is intended to be used as a floating toolbar. A tool window has a title bar that is shorter than a normal title bar, and the window title is drawn using a smaller font. A tool window does not appear in the taskbar or in the dialog that appears when the user presses ALT+TAB. If a tool window has a system menu, its icon is not displayed on the title bar. However, you can display the system menu by right-clicking or by typing ALT+SPACE. +WS_EX_WINDOWEDGE|0x00000100|The window has a border with a raised edge. +WS_EX_CLIENTEDGE|0x00000200|The window has a border with a sunken edge. +WS_EX_CONTEXTHELP|0x00000400|The title bar of the window includes a question mark. When the user clicks the question mark, the cursor changes to a question mark with a pointer. If the user then clicks a child window, the child receives a WM_HELP message. The child window should pass the message to the parent window procedure, which should call the WinHelp function using the HELP_WM_HELP command. The Help application displays a pop-up window that typically contains help for the child window.\n\nWS_EX_CONTEXTHELP cannot be used with the WS_MAXIMIZEBOX or WS_MINIMIZEBOX styles. +WS_EX_RIGHT|0x00001000|The window has generic "right-aligned" properties. This depends on the window class. This style has an effect only if the shell language is Hebrew, Arabic, or another language that supports reading-order alignment; otherwise, the style is ignored.\n\nUsing the WS_EX_RIGHT style for static or edit controls has the same effect as using the SS_RIGHT or ES_RIGHT style, respectively. Using this style with button controls has the same effect as using BS_RIGHT and BS_RIGHTBUTTON styles. +WS_EX_RTLREADING|0x00002000|If the shell language is Hebrew, Arabic, or another language that supports reading-order alignment, the window text is displayed using right-to-left reading-order properties. For other languages, the style is ignored. +WS_EX_LEFTSCROLLBAR|0x00004000|If the shell language is Hebrew, Arabic, or another language that supports reading order alignment, the vertical scroll bar (if present) is to the left of the client area. For other languages, the style is ignored. +WS_EX_CONTROLPARENT|0x00010000|The window itself contains child windows that should take part in dialog box navigation. If this style is specified, the dialog manager recurses into children of this window when performing navigation operations such as handling the TAB key, an arrow key, or a keyboard mnemonic. +WS_EX_STATICEDGE|0x00020000|The window has a three-dimensional border style intended to be used for items that do not accept user input. +WS_EX_APPWINDOW|0x00040000|Forces a top-level window onto the taskbar when the window is visible. +WS_EX_LAYERED|0x00080000| The window is a layered window. This style cannot be used if the window has a class style of either CS_OWNDC or CS_CLASSDC.\n\nWindows 8: The WS_EX_LAYERED style is supported for top-level windows and child windows. Previous Windows versions support WS_EX_LAYERED only for top-level windows. +WS_EX_NOINHERITLAYOUT|0x00100000|The window does not pass its window layout to its child windows. +WS_EX_NOREDIRECTIONBITMAP|0x00200000|The window does not render to a redirection surface. This is for windows that do not have visible content or that use mechanisms other than surfaces to provide their visual. +WS_EX_LAYOUTRTL|0x00400000|If the shell language is Hebrew, Arabic, or another language that supports reading order alignment, the horizontal origin of the window is on the right edge. Increasing horizontal values advance to the left. +WS_EX_COMPOSITED|0x02000000|Paints all descendants of a window in bottom-to-top painting order using double-buffering. For more information, see Remarks. This cannot be used if the window has a class style of either CS_OWNDC or CS_CLASSDC. +WS_EX_NOACTIVATE|0x08000000|A top-level window created with this style does not become the foreground window when the user clicks it. The system does not bring this window to the foreground when the user minimizes or closes the foreground window.\n\nTo activate the window, use the SetActiveWindow or SetForegroundWindow function.\n\nThe window does not appear on the taskbar by default. To force the window to appear on the taskbar, use the WS_EX_APPWINDOW style. + +[Static] +SS_LEFT|0x00000000|A simple rectangle and left-aligns the text in the rectangle. The text is formatted before it is displayed. Words that extend past the end of a line are automatically wrapped to the beginning of the next left-aligned line. Words that are longer than the width of the control are truncated. +SS_CENTER|0x00000001|A simple rectangle and centers the text in the rectangle. The text is formatted before it is displayed. Words that extend past the end of a line are automatically wrapped to the beginning of the next centered line. Words that are longer than the width of the control are truncated. +SS_RIGHT|0x00000002|A simple rectangle and right-aligns the text in the rectangle. The text is formatted before it is displayed. Words that extend past the end of a line are automatically wrapped to the beginning of the next right-aligned line. Words that are longer than the width of the control are truncated. +SS_ICON|0x00000003|An icon to be displayed in the dialog box. If the control is created as part of a dialog box, the text is the name of an icon (not a filename) defined elsewhere in the resource file. If the control is created via CreateWindow or a related function, the text is the name of an icon (not a filename) defined in the resource file associated with the module specified by the hInstance parameter to CreateWindow.\n\nThe icon can be an animated cursor.\n\nThe style ignores the CreateWindow parameters nWidth and nHeight; the control automatically sizes itself to accommodate the icon. As it uses the LoadIcon function, the SS_ICON style can load only icons of dimensions SM_CXICON and SM_CYICON. This restriction can be bypassed by using the SS_REALSIZEIMAGE style in addition to SS_ICON.\n\nIf an icon cannot be loaded through LoadIcon, an attempt is made to load the specified resource as a cursor using LoadCursor. If that too fails, an attempt is made to load from the device driver using LoadImage. +SS_BLACKRECT|0x00000004|A rectangle filled with the current window frame color. This color is black in the default color scheme. +SS_GRAYRECT|0x00000005|A rectangle filled with the current screen background color. This color is gray in the default color scheme. +SS_WHITERECT|0x00000006|A rectangle filled with the current window background color. This color is white in the default color scheme. +SS_BLACKFRAME|0x00000007|A box with a frame drawn in the same color as the window frames. This color is black in the default color scheme. +SS_GRAYFRAME|0x00000008|A box with a frame drawn with the same color as the screen background (desktop). This color is gray in the default color scheme. +SS_WHITEFRAME|0x00000009|A box with a frame drawn with the same color as the window background. This color is white in the default color scheme. +SS_USERITEM|0x0000000A|Specifies a user-defined item. +SS_SIMPLE|0x0000000B|A simple rectangle and displays a single line of left-aligned text in the rectangle. The text line cannot be shortened or altered in any way. Also, if the control is disabled, the control does not gray its text. +SS_LEFTNOWORDWRAP|0x0000000C|A simple rectangle and left-aligns the text in the rectangle. Tabs are expanded, but words are not wrapped. Text that extends past the end of a line is clipped. +SS_OWNERDRAW|0x0000000D|The owner of the static control is responsible for drawing the control. The owner window receives a WM_DRAWITEM message whenever the control needs to be drawn. +SS_BITMAP|0x0000000E|A bitmap is to be displayed in the static control. The text is the name of a bitmap (not a filename) defined elsewhere in the resource file. The style ignores the nWidth and nHeight parameters; the control automatically sizes itself to accommodate the bitmap. +SS_ENHMETAFILE|0x0000000F|An enhanced metafile is to be displayed in the static control. The text is the name of a metafile. An enhanced metafile static control has a fixed size; the metafile is scaled to fit the static control's client area. +SS_ETCHEDHORZ|0x00000010|Draws the top and bottom edges of the static control using the EDGE_ETCHED edge style. For more information, see the DrawEdge function. +SS_REALSIZECONTROL|0x00000040|Adjusts the bitmap to fit the size of the static control. For example, changing the locale can change the system font, and thus controls might be resized. If a static control had a bitmap, the bitmap would no longer fit the control. This style bit dictates automatic redimensioning of bitmaps to fit their controls.\n\nIf SS_CENTERIMAGE is specified, the bitmap or icon is centered (and clipped if needed). If SS_CENTERIMAGE is not specified, the bitmap or icon is stretched or shrunk.\n\nNote that the redimensioning in the two axes are independent, and the result may have a changed aspect ratio.\n\nCompare with SS_REALSIZEIMAGE. +SS_NOPREFIX|0x00000080|Prevents interpretation of any ampersand (&) characters in the control's text as accelerator prefix characters. These are displayed with the ampersand removed and the next character in the string underlined. This static control style may be included with any of the defined static controls. You can combine SS_NOPREFIX with other styles. This can be useful when filenames or other strings that may contain an ampersand (&) must be displayed in a static control in a dialog box. +SS_NOTIFY|0x00000100|Sends the parent window STN_CLICKED, STN_DBLCLK, STN_DISABLE, and STN_ENABLE notification codes when the user clicks or double-clicks the control. +SS_CENTERIMAGE|0x00000200|A bitmap is centered in the static control that contains it. The control is not resized, so that a bitmap too large for the control will be clipped. If the static control contains a single line of text, the text is centered vertically in the client area of the control. +SS_RIGHTJUST|0x00000400|The lower right corner of a static control with the SS_BITMAP or SS_ICON style is to remain fixed when the control is resized. Only the top and left sides are adjusted to accommodate a new bitmap or icon. +SS_REALSIZEIMAGE|0x00000800|Specifies that the actual resource width is used and the icon is loaded using LoadImage. SS_REALSIZEIMAGE is always used in conjunction with SS_ICON.\n\nSS_REALSIZEIMAGE uses LoadImage, overriding the process normally followed under SS_ICON. It does not load cursors; if LoadImage fails, no further attempts to load are made. It uses the actual resource width. The static control is resized accordingly, but the icon remains aligned to the originally specified left and top edges of the control.\n\nNote that if SS_CENTERIMAGE is also specified, the icon is centered within the control's space, which was specified using the CreateWindow parameters nWidth and nHeight.\n\nCompare with SS_REALSIZECONTROL. +SS_SUNKEN|0x00001000|Draws a half-sunken border around a static control. +SS_EDITCONTROL|0x00002000|The static control duplicates the text-displaying characteristics of a multiline edit control. Specifically, the average character width is calculated in the same manner as with an edit control, and the function does not display a partially visible last line. +SS_ENDELLIPSIS|0x00004000|If the end of a string does not fit in the rectangle, it is truncated and ellipses are added. If a word that is not at the end of the string goes beyond the limits of the rectangle, it is truncated without ellipses. Using this style will force the control's text to be on one line with no word wrap. Compare with SS_PATHELLIPSIS and SS_WORDELLIPSIS. +SS_PATHELLIPSIS|0x00008000|Replaces characters in the middle of the string with ellipses so that the result fits in the specified rectangle. If the string contains backslash (\) characters, SS_PATHELLIPSIS preserves as much as possible of the text after the last backslash. Using this style will force the control's text to be on one line with no word wrap. Compare with SS_ENDELLIPSIS and SS_WORDELLIPSIS. +SS_WORDELLIPSIS|0x0000C000|Truncates any word that does not fit in the rectangle and adds ellipses. Using this style will force the control's text to be on one line with no word wrap. + +[Button] +BS_PUSHBUTTON|0x00000000|Creates a push button that posts a WM_COMMAND message to the owner window when the user selects the button. +BS_TEXT|0x00000000|Specifies that the button displays text. +BS_DEFPUSHBUTTON|0x00000001|Creates a push button that behaves like a BS_PUSHBUTTON style button, but has a distinct appearance. If the button is in a dialog box, the user can select the button by pressing the ENTER key, even when the button does not have the input focus. This style is useful for enabling the user to quickly select the most likely (default) option. +BS_CHECKBOX|0x00000002|Creates a small, empty check box with text. By default, the text is displayed to the right of the check box. To display the text to the left of the check box, combine this flag with the BS_LEFTTEXT style (or with the equivalent BS_RIGHTBUTTON style). +BS_AUTOCHECKBOX|0x00000003|Creates a button that is the same as a check box, except that the check state automatically toggles between checked and cleared each time the user selects the check box. +BS_RADIOBUTTON|0x00000004|Creates a small circle with text. By default, the text is displayed to the right of the circle. To display the text to the left of the circle, combine this flag with the BS_LEFTTEXT style (or with the equivalent BS_RIGHTBUTTON style). Use radio buttons for groups of related, but mutually exclusive choices. +BS_3STATE|0x00000005|Creates a button that is the same as a check box, except that the box can be grayed as well as checked or cleared. Use the grayed state to show that the state of the check box is not determined. +BS_AUTO3STATE|0x00000006|Creates a button that is the same as a three-state check box, except that the box changes its state when the user selects it. The state cycles through checked, indeterminate, and cleared. +BS_GROUPBOX|0x00000007|Creates a rectangle in which other controls can be grouped. Any text associated with this style is displayed in the rectangle's upper left corner. +BS_USERBUTTON|0x00000008|Obsolete, but provided for compatibility with 16-bit versions of Windows. Applications should use BS_OWNERDRAW instead. +BS_AUTORADIOBUTTON|0x00000009|Creates a button that is the same as a radio button, except that when the user selects it, the system automatically sets the button's check state to checked and automatically sets the check state for all other buttons in the same group to cleared. +BS_OWNERDRAW|0x0000000B|Creates an owner-drawn button. The owner window receives a WM_DRAWITEM message when a visual aspect of the button has changed. Do not combine the BS_OWNERDRAW style with any other button styles. +BS_SPLITBUTTON|0x0000000C|Creates a split button. A split button has a drop down arrow. +BS_DEFSPLITBUTTON|0x0000000D|Creates a split button that behaves like a BS_PUSHBUTTON style button, but also has a distinctive appearance. If the split button is in a dialog box, the user can select the split button by pressing the ENTER key, even when the split button does not have the input focus. This style is useful for enabling the user to quickly select the most likely (default) option. +BS_COMMANDLINK|0x0000000E|Creates a command link button that behaves like a BS_PUSHBUTTON style button, but the command link button has a green arrow on the left pointing to the button text. A caption for the button text can be set by sending the BCM_SETNOTE message to the button. +BS_DEFCOMMANDLINK|0x0000000F|Creates a command link button that behaves like a BS_PUSHBUTTON style button. If the button is in a dialog box, the user can select the command link button by pressing the ENTER key, even when the command link button does not have the input focus. This style is useful for enabling the user to quickly select the most likely (default) option. +BS_LEFTTEXT|0x00000020|Places text on the left side of the radio button or check box when combined with a radio button or check box style. Same as the BS_RIGHTBUTTON style. +BS_ICON|0x00000040|Specifies that the button displays an icon. See the Remarks section for its interaction with BS_BITMAP. +BS_BITMAP|0x00000080|Specifies that the button displays a bitmap. See the Remarks section for its interaction with BS_ICON. +BS_LEFT|0x00000100|Left-justifies the text in the button rectangle. However, if the button is a check box or radio button that does not have the BS_RIGHTBUTTON style, the text is left justified on the right side of the check box or radio button. +BS_RIGHT|0x00000200|Right-justifies text in the button rectangle. However, if the button is a check box or radio button that does not have the BS_RIGHTBUTTON style, the text is right justified on the right side of the check box or radio button. +BS_CENTER|0x00000300|Centers text horizontally in the button rectangle. +BS_TOP|0x00000400|Places text at the top of the button rectangle. +BS_BOTTOM|0x00000800|Places text at the bottom of the button rectangle. +BS_VCENTER|0x00000C00|Places text in the middle (vertically) of the button rectangle. +BS_PUSHLIKE|0x00001000|Makes a button (such as a check box, three-state check box, or radio button) look and act like a push button. The button looks raised when it isn't pushed or checked, and sunken when it is pushed or checked. +BS_MULTILINE|0x00002000|Wraps the button text to multiple lines if the text string is too long to fit on a single line in the button rectangle. +BS_NOTIFY|0x00004000|Enables a button to send BN_KILLFOCUS and BN_SETFOCUS notification codes to its parent window.\n\nNote that buttons send the BN_CLICKED notification code regardless of whether it has this style. To get BN_DBLCLK notification codes, the button must have the BS_RADIOBUTTON or BS_OWNERDRAW style. +BS_FLAT|0x00008000|Specifies that the button is two-dimensional; it does not use the default shading to create a 3-D image. + +[Edit] +ES_LEFT|0x00000000|Aligns text with the left margin. +ES_CENTER|0x00000001|Centers text in a single-line or multiline edit control. +ES_RIGHT|0x00000002|Right-aligns text in a single-line or multiline edit control. +ES_MULTILINE|0x00000004|Designates a multiline edit control. The default is single-line edit control.\n\nWhen the multiline edit control is in a dialog box, the default response to pressing the ENTER key is to activate the default button. To use the ENTER key as a carriage return, use the ES_WANTRETURN style.\n\nWhen the multiline edit control is not in a dialog box and the ES_AUTOVSCROLL style is specified, the edit control shows as many lines as possible and scrolls vertically when the user presses the ENTER key. If you do not specify ES_AUTOVSCROLL, the edit control shows as many lines as possible and beeps if the user presses the ENTER key when no more lines can be displayed.\n\nIf you specify the ES_AUTOHSCROLL style, the multiline edit control automatically scrolls horizontally when the caret goes past the right edge of the control. To start a new line, the user must press the ENTER key. If you do not specify ES_AUTOHSCROLL, the control automatically wraps words to the beginning of the next line when necessary. A new line is also started if the user presses the ENTER key. The window size determines the position of the Wordwrap. If the window size changes, the Wordwrapping position changes and the text is redisplayed.\n\nMultiline edit controls can have scroll bars. An edit control with scroll bars processes its own scroll bar messages. Note that edit controls without scroll bars scroll as described in the previous paragraphs and process any scroll messages sent by the parent window. +ES_UPPERCASE|0x00000008|Converts all characters to uppercase as they are typed into the edit control.\n\nTo change this style after the control has been created, use SetWindowLong. +ES_LOWERCASE|0x00000010|Converts all characters to lowercase as they are typed into the edit control.\n\nTo change this style after the control has been created, use SetWindowLong. +ES_PASSWORD|0x00000020|Displays an asterisk (*) for each character typed into the edit control. This style is valid only for single-line edit controls.\n\nTo change the characters that is displayed, or set or clear this style, use the EM_SETPASSWORDCHAR message. +ES_AUTOVSCROLL|0x00000040|Automatically scrolls text up one page when the user presses the ENTER key on the last line. +ES_AUTOHSCROLL|0x00000080|Automatically scrolls text to the right by 10 characters when the user types a character at the end of the line. When the user presses the ENTER key, the control scrolls all text back to position zero. +ES_NOHIDESEL|0x00000100|Negates the default behavior for an edit control. The default behavior hides the selection when the control loses the input focus and inverts the selection when the control receives the input focus. If you specify ES_NOHIDESEL, the selected text is inverted, even if the control does not have the focus. +ES_OEMCONVERT|0x00000400|Converts text entered in the edit control. The text is converted from the Windows character set to the OEM character set and then back to the Windows character set. This ensures proper character conversion when the application calls the CharToOem function to convert a Windows string in the edit control to OEM characters. This style is most useful for edit controls that contain file names that will be used on file systems that do not support Unicode.\n\nTo change this style after the control has been created, use SetWindowLong. +ES_READONLY|0x00000800|Prevents the user from typing or editing text in the edit control.\n\nTo change this style after the control has been created, use the EM_SETREADONLY message. +ES_WANTRETURN|0x00001000|Specifies that a carriage return be inserted when the user presses the ENTER key while entering text into a multiline edit control in a dialog box. If you do not specify this style, pressing the ENTER key has the same effect as pressing the dialog box's default push button. This style has no effect on a single-line edit control.\n\nTo change this style after the control has been created, use SetWindowLong. +ES_NUMBER|0x00002000|Allows only digits to be entered into the edit control. Note that, even with this set, it is still possible to paste non-digits into the edit control.\n\nTo change this style after the control has been created, use SetWindowLong.\n\nTo translate text that was entered into the edit control to an integer value, use the GetDlgItemInt function. To set the text of the edit control to the string representation of a specified integer, use the SetDlgItemInt function. + +[ComboBox] +CBS_SIMPLE|0x00000001|Displays the list box at all times. The current selection in the list box is displayed in the edit control. +CBS_DROPDOWN|0x00000002|Similar to CBS_SIMPLE, except that the list box is not displayed unless the user selects an icon next to the edit control. +CBS_DROPDOWNLIST|0x00000003|Similar to CBS_DROPDOWN, except that the edit control is replaced by a static text item that displays the current selection in the list box. +CBS_OWNERDRAWFIXED|0x00000010|Specifies that the owner of the list box is responsible for drawing its contents and that the items in the list box are all the same height. The owner window receives a WM_MEASUREITEM message when the combo box is created and a WM_DRAWITEM message when a visual aspect of the combo box has changed. +CBS_OWNERDRAWVARIABLE|0x00000020|Specifies that the owner of the list box is responsible for drawing its contents and that the items in the list box are variable in height. The owner window receives a WM_MEASUREITEM message for each item in the combo box when you create the combo box and a WM_DRAWITEM message when a visual aspect of the combo box has changed. +CBS_AUTOHSCROLL|0x00000040|Automatically scrolls the text in an edit control to the right when the user types a character at the end of the line. If this style is not set, only text that fits within the rectangular boundary is allowed. +CBS_OEMCONVERT|0x00000080|Converts text entered in the combo box edit control from the Windows character set to the OEM character set and then back to the Windows character set. This ensures proper character conversion when the application calls the CharToOem function to convert a Windows string in the combo box to OEM characters. This style is most useful for combo boxes that contain file names and applies only to combo boxes created with the CBS_SIMPLE or CBS_DROPDOWN style. +CBS_SORT|0x00000100|Automatically sorts strings added to the list box. +CBS_HASSTRINGS|0x00000200|Specifies that an owner-drawn combo box contains items consisting of strings. The combo box maintains the memory and address for the strings so the application can use the CB_GETLBTEXT message to retrieve the text for a particular item.\n\nFor accessibility issues, see Exposing Owner-Drawn Combo Box Items +CBS_NOINTEGRALHEIGHT|0x00000400|Specifies that the size of the combo box is exactly the size specified by the application when it created the combo box. Normally, the system sizes a combo box so that it does not display partial items. +CBS_DISABLENOSCROLL|0x00000800|Shows a disabled vertical scroll bar in the list box when the box does not contain enough items to scroll. Without this style, the scroll bar is hidden when the list box does not contain enough items. +CBS_UPPERCASE|0x00001000|Converts to uppercase all text in both the selection field and the list. +CBS_LOWERCASE|0x00002000|Converts to lowercase all text in both the selection field and the list. + +[ListBox] +LBS_NOTIFY|0x00000001|Causes the list box to send a notification code to the parent window whenever the user clicks a list box item (LBN_SELCHANGE), double-clicks an item (LBN_DBLCLK), or cancels the selection (LBN_SELCANCEL). +LBS_SORT|0x00000002|Sorts strings in the list box alphabetically. +LBS_NOREDRAW|0x00000004|Specifies that the list box's appearance is not updated when changes are made.\n\nTo change the redraw state of the control, use the WM_SETREDRAW message. +LBS_MULTIPLESEL|0x00000008|Turns string selection on or off each time the user clicks or double-clicks a string in the list box. The user can select any number of strings. +LBS_OWNERDRAWFIXED|0x00000010|Specifies that the owner of the list box is responsible for drawing its contents and that the items in the list box are the same height. The owner window receives a WM_MEASUREITEM message when the list box is created and a WM_DRAWITEM message when a visual aspect of the list box has changed. +LBS_OWNERDRAWVARIABLE|0x00000020|Specifies that the owner of the list box is responsible for drawing its contents and that the items in the list box are variable in height. The owner window receives a WM_MEASUREITEM message for each item in the box when the list box is created and a WM_DRAWITEM message when a visual aspect of the list box has changed.\n\nThis style causes the LBS_NOINTEGRALHEIGHT style to be enabled.\n\nThis style is ignored if the LBS_MULTICOLUMN style is specified. +LBS_HASSTRINGS|0x00000040|Specifies that a list box contains items consisting of strings. The list box maintains the memory and addresses for the strings so that the application can use the LB_GETTEXT message to retrieve the text for a particular item. By default, all list boxes except owner-drawn list boxes have this style. You can create an owner-drawn list box either with or without this style.\n\nFor owner-drawn list boxes without this style, the LB_GETTEXT message retrieves the value associated with an item (the item data). +LBS_USETABSTOPS|0x00000080|Enables a list box to recognize and expand tab characters when drawing its strings. You can use the LB_SETTABSTOPS message to specify tab stop positions. The default tab positions are 32 dialog template units apart. Dialog template units are the device-independent units used in dialog box templates. To convert measurements from dialog template units to screen units (pixels), use the MapDialogRect function. +LBS_NOINTEGRALHEIGHT|0x00000100|Specifies that the size of the list box is exactly the size specified by the application when it created the list box. Normally, the system sizes a list box so that the list box does not display partial items.\n\nFor list boxes with the LBS_OWNERDRAWVARIABLE style, the LBS_NOINTEGRALHEIGHT style is always enforced. +LBS_MULTICOLUMN|0x00000200|Specifies a multi-column list box that is scrolled horizontally. The list box automatically calculates the width of the columns, or an application can set the width by using the LB_SETCOLUMNWIDTH message. If a list box has the LBS_OWNERDRAWFIXED style, an application can set the width when the list box sends the WM_MEASUREITEM message.\n\nA list box with the LBS_MULTICOLUMN style cannot scroll vertically - it ignores any WM_VSCROLL messages it receives.\n\nThe LBS_MULTICOLUMN and LBS_OWNERDRAWVARIABLE styles cannot be combined. If both are specified, LBS_OWNERDRAWVARIABLE is ignored. +LBS_WANTKEYBOARDINPUT|0x00000400|Specifies that the owner of the list box receives WM_VKEYTOITEM messages whenever the user presses a key and the list box has the input focus. This enables an application to perform special processing on the keyboard input. +LBS_EXTENDEDSEL|0x00000800|Allows multiple items to be selected by using the SHIFT key and the mouse or special key combinations. +LBS_DISABLENOSCROLL|0x00001000|Shows a disabled horizontal or vertical scroll bar when the list box does not contain enough items to scroll. If you do not specify this style, the scroll bar is hidden when the list box does not contain enough items. This style must be used with the WS_VSCROLL or WS_HSCROLL style. +LBS_NODATA|0x00002000|Specifies a no-data list box. Specify this style when the count of items in the list box will exceed one thousand. A no-data list box must also have the LBS_OWNERDRAWFIXED style, but must not have the LBS_SORT or LBS_HASSTRINGS style.\n\nA no-data list box resembles an owner-drawn list box except that it contains no string or bitmap data for an item. Commands to add, insert, or delete an item always ignore any specified item data; requests to find a string within the list box always fail. The system sends the WM_DRAWITEM message to the owner window when an item must be drawn. The itemID member of the DRAWITEMSTRUCT structure passed with the WM_DRAWITEM message specifies the line number of the item to be drawn. A no-data list box does not send a WM_DELETEITEM message. +LBS_NOSEL|0x00004000|Specifies that the list box contains items that can be viewed but not selected. +LBS_COMBOBOX|0x00008000|Notifies a list box that it is part of a combo box. This allows coordination between the two controls so that they present a unified UI. The combo box itself must set this style. If the style is set by anything but the combo box, the list box will regard itself incorrectly as a child of a combo box and a failure will result. + +[SysListView32] +LVS_ICON|0x00000000|This style specifies icon view. +LVS_ALIGNTOP|0x00000000|Items are aligned with the top of the list-view control in icon and small icon view. +LVS_REPORT|0x00000001|This style specifies report view. When using the LVS_REPORT style with a list-view control, the first column is always left-aligned. You cannot use LVCFMT_RIGHT to change this alignment. See LVCOLUMN for further information on column alignment. +LVS_SMALLICON|0x00000002|This style specifies small icon view. +LVS_LIST|0x00000003|This style specifies list view. +LVS_SINGLESEL|0x00000004|Only one item at a time can be selected. By default, multiple items may be selected. +LVS_SHOWSELALWAYS|0x00000008|The selection, if any, is always shown, even if the control does not have the focus. +LVS_SORTASCENDING|0x00000010|Item indexes are sorted based on item text in ascending order. +LVS_SORTDESCENDING|0x00000020|Item indexes are sorted based on item text in descending order. +LVS_SHAREIMAGELISTS|0x00000040|The image list will not be deleted when the control is destroyed. This style enables the use of the same image lists with multiple list-view controls. +LVS_NOLABELWRAP|0x00000080|Item text is displayed on a single line in icon view. By default, item text may wrap in icon view. +LVS_AUTOARRANGE|0x00000100|Icons are automatically kept arranged in icon and small icon view. +LVS_EDITLABELS|0x00000200|Item text can be edited in place. The parent window must process the LVN_ENDLABELEDIT notification code. +LVS_OWNERDATA|0x00001000|This style specifies a virtual list-view control. For more information about this list control style, see About List-View Controls. +LVS_NOSCROLL|0x00002000|Scrolling is disabled. All items must be within the client area. This style is not compatible with the LVS_LIST or LVS_REPORT styles. See Knowledge Base Article Q137520 for further discussion. +LVS_ALIGNLEFT|0x00000800|Items are left-aligned in icon and small icon view. +LVS_OWNERDRAWFIXED|0x00000400|The owner window can paint items in report view. The list-view control sends a WM_DRAWITEM message to paint each item; it does not send separate messages for each subitem. The iItemData member of the DRAWITEMSTRUCT structure contains the item data for the specified list-view item. +LVS_NOCOLUMNHEADER|0x00004000|Column headers are not displayed in report view. By default, columns have headers in report view. +LVS_NOSORTHEADER|0x00008000|Column headers do not work like buttons. This style can be used if clicking a column header in report view does not carry out an action, such as sorting. + +[SysListView32Ex] +LVS_EX_GRIDLINES|0x00000001|Displays gridlines around items and subitems. This style is available only in conjunction with the LVS_REPORT style. +LVS_EX_SUBITEMIMAGES|0x00000002|Allows images to be displayed for subitems. This style is available only in conjunction with the LVS_REPORT style. +LVS_EX_CHECKBOXES|0x00000004|Enables check boxes for items in a list-view control. Check boxes are visible and functional with all list view modes except the tile view mode introduced in ComCtl32.dll version 6. Clicking a checkbox in tile view mode only selects the item; the state does not change.\n\nYou can obtain the state of the check box for a given item with ListView_GetCheckState. To set the check state, use ListView_SetCheckState. If this style is set, the list-view control automatically toggles the check state when the user clicks the check box or presses the space bar. +LVS_EX_TRACKSELECT|0x00000008|Enables hot-track selection in a list-view control. Hot track selection means that an item is automatically selected when the cursor remains over the item for a certain period of time. The delay can be changed from the default system setting with a LVM_SETHOVERTIME message. This style applies to all styles of list-view control. You can check whether hot-track selection is enabled by calling SystemParametersInfo. +LVS_EX_HEADERDRAGDROP|0x00000010|Enables drag-and-drop reordering of columns in a list-view control. This style is only available to list-view controls that use the LVS_REPORT style. +LVS_EX_FULLROWSELECT|0x00000020|When an item is selected, the item and all its subitems are highlighted. This style is available only in conjunction with the LVS_REPORT style. +LVS_EX_ONECLICKACTIVATE|0x00000040|The list-view control sends an LVN_ITEMACTIVATE notification code to the parent window when the user clicks an item. This style also enables hot tracking in the list-view control. Hot tracking means that when the cursor moves over an item, it is highlighted but not selected. See the Extended List-View Styles Remarks section for a discussion of item activation. +LVS_EX_TWOCLICKACTIVATE|0x00000080|The list-view control sends an LVN_ITEMACTIVATE notification code to the parent window when the user double-clicks an item. This style also enables hot tracking in the list-view control. Hot tracking means that when the cursor moves over an item, it is highlighted but not selected. See the Extended List-View Styles Remarks section for a discussion of item activation. +LVS_EX_FLATSB|0x00000100|Enables flat scroll bars in the list view. If you need more control over the appearance of the list view's scroll bars, you should manipulate the list view's scroll bars directly using the Flat Scroll Bar APIs. If the system metrics change, you are responsible for adjusting the scroll bar metrics with FlatSB_SetScrollProp. See Flat Scroll Bars for further details. +LVS_EX_REGIONAL|0x00000200|Not supported on Windows Vista and later. Sets the list view window region to include only the item icons and text using SetWindowRgn. Any area that is not part of an item is excluded from the window region. This style is only available to list-view controls that use the LVS_ICON style. +LVS_EX_INFOTIP|0x00000400|When a list-view control uses the LVS_EX_INFOTIP style, the LVN_GETINFOTIP notification code is sent to the parent window before displaying an item's tooltip. +LVS_EX_UNDERLINEHOT|0x00000800|Causes those hot items that may be activated to be displayed with underlined text. This style requires that LVS_EX_ONECLICKACTIVATE or LVS_EX_TWOCLICKACTIVATE also be set. See the Extended List-View Styles Remarks section for a discussion of item activation. +LVS_EX_UNDERLINECOLD|0x00001000|Causes those non-hot items that may be activated to be displayed with underlined text. This style requires that LVS_EX_TWOCLICKACTIVATE be set also. See the Extended List-View Styles Remarks section for a discussion of item activation. +LVS_EX_MULTIWORKAREAS|0x00002000|If the list-view control has the LVS_AUTOARRANGE style, the control will not autoarrange its icons until one or more work areas are defined (see LVM_SETWORKAREAS). To be effective, this style must be set before any work areas are defined and any items have been added to the control. +LVS_EX_LABELTIP|0x00004000|If a partially hidden label in any list view mode lacks tooltip text, the list-view control will unfold the label. If this style is not set, the list-view control will unfold partly hidden labels only for the large icon mode. +LVS_EX_BORDERSELECT|0x00008000|Changes border color when an item is selected, instead of highlighting the item. +LVS_EX_DOUBLEBUFFER|0x00010000|Paints via double-buffering, which reduces flicker. This extended style also enables alpha-blended marquee selection on systems where it is supported. +LVS_EX_HIDELABELS|0x00020000|Hides the labels in icon and small icon view. +LVS_EX_SINGLEROW|0x00040000|Not used. +LVS_EX_SNAPTOGRID|0x00080000|In icon view, icons automatically snap into a grid. +LVS_EX_SIMPLESELECT|0x00100000|In icon view, moves the state image of the control to the top right of the large icon rendering. In views other than icon view there is no change. When the user changes the state by using the space bar, all selected items cycle over, not the item with the focus. +LVS_EX_JUSTIFYCOLUMNS|0x00200000|Icons are lined up in columns that use up the whole view. +LVS_EX_TRANSPARENTBKGND|0x00400000|Background is painted by the parent via WM_PRINTCLIENT. +LVS_EX_TRANSPARENTSHADOWTEXT|0x00800000|Enable shadow text on transparent backgrounds only. +LVS_EX_AUTOAUTOARRANGE|0x01000000|Automatically arrange icons if no icon positions have been set (Similar to LVS_AUTOARRANGE). +LVS_EX_HEADERINALLVIEWS|0x02000000|Show column headers in all view modes. +LVS_EX_AUTOCHECKSELECT|0x08000000|Automatically select check boxes on single click. +LVS_EX_AUTOSIZECOLUMNS|0x10000000|Automatically size listview columns. +LVS_EX_COLUMNSNAPPOINTS|0x40000000|Snap to minimum column width when the user resizes a column. +LVS_EX_COLUMNOVERFLOW|0x80000000|Indicates that an overflow button should be displayed in icon/tile view if there is not enough client width to display the complete set of header items. The list-view control sends the LVN_COLUMNOVERFLOWCLICK notification when the overflow button is clicked. This flag is only valid when LVS_EX_HEADERINALLVIEWS is also specified. + +[SysTreeView32] +TVS_HASBUTTONS|0x00000001|Displays plus (+) and minus (-) buttons next to parent items. The user clicks the buttons to expand or collapse a parent item's list of child items. To include buttons with items at the root of the tree view, TVS_LINESATROOT must also be specified. +TVS_HASLINES|0x00000002|Uses lines to show the hierarchy of items. +TVS_LINESATROOT|0x00000004|Uses lines to link items at the root of the tree-view control. This value is ignored if TVS_HASLINES is not also specified. +TVS_EDITLABELS|0x00000008|Allows the user to edit the labels of tree-view items. +TVS_DISABLEDRAGDROP|0x00000010|Prevents the tree-view control from sending TVN_BEGINDRAG notification codes. +TVS_SHOWSELALWAYS|0x00000020|Causes a selected item to remain selected when the tree-view control loses focus. +TVS_RTLREADING|0x00000040|Causes text to be displayed from right-to-left (RTL). Usually, windows display text left-to-right (LTR). Windows can be mirrored to display languages such as Hebrew or Arabic that read RTL. Typically, tree-view text is displayed in the same direction as the text in its parent window. If TVS_RTLREADING is set, tree-view text reads in the opposite direction from the text in the parent window. +TVS_NOTOOLTIPS|0x00000080|Disables tooltips. +TVS_CHECKBOXES|0x00000100|Enables check boxes for items in a tree-view control. A check box is displayed only if an image is associated with the item. When set to this style, the control effectively uses DrawFrameControl to create and set a state image list containing two images. State image 1 is the unchecked box and state image 2 is the checked box. Setting the state image to zero removes the check box altogether. For more information, see Working with state image indexes.\n\nVersion 5.80. Displays a check box even if no image is associated with the item.\n\nOnce a tree-view control is created with this style, the style cannot be removed. Instead, you must destroy the control and create a new one in its place. Destroying the tree-view control does not destroy the check box state image list. You must destroy it explicitly. Get the handle to the state image list by sending the tree-view control a TVM_GETIMAGELIST message. Then destroy the image list with ImageList_Destroy.\n\nIf you want to use this style, you must set the TVS_CHECKBOXES style with SetWindowLong after you create the treeview control, and before you populate the tree. Otherwise, the checkboxes might appear unchecked, depending on timing issues. +TVS_TRACKSELECT|0x00000200|Enables hot tracking in a tree-view control. +TVS_SINGLEEXPAND|0x00000400|Causes the item being selected to expand and the item being unselected to collapse upon selection in the tree view. If the user holds down the CTRL key while selecting an item, the item being unselected will not be collapsed. +TVS_INFOTIP|0x00000800|Obtains tooltip information by sending the TVN_GETINFOTIP notification. +TVS_FULLROWSELECT|0x00001000|Enables full-row selection in the tree view. The entire row of the selected item is highlighted, and clicking anywhere on an item's row causes it to be selected. This style cannot be used in conjunction with the TVS_HASLINES style. +TVS_NOSCROLL|0x00002000|Disables both horizontal and vertical scrolling in the control. The control will not display any scroll bars. +TVS_NONEVENHEIGHT|0x00004000|Sets the height of the items to an odd height with the TVM_SETITEMHEIGHT message. By default, the height of items must be an even value. +TVS_NOHSCROLL|0x00008000|Disables horizontal scrolling in the control. The control will not display any horizontal scroll bars. + +[SysTreeView32Ex] +TVS_EX_NOSINGLECOLLAPSE|0x00000001|Intended for internal use; not recommended for use in applications. Do not collapse the previously selected tree-view item unless it has the same parent as the new selection. This style must be used with the TVS_SINGLEEXPAND style. +TVS_EX_MULTISELECT|0x00000002|Not supported. Do not use. +TVS_EX_DOUBLEBUFFER|0x00000004|Specifies how the background is erased or filled. +TVS_EX_NOINDENTSTATE|0x00000008|Do not indent the tree view for the expando buttons. +TVS_EX_RICHTOOLTIP|0x00000010|Allow rich tooltips in the tree view (custom drawn with icon and text). +TVS_EX_AUTOHSCROLL|0x00000020|Remove the horizontal scroll bar and auto-scroll depending on mouse position. +TVS_EX_FADEINOUTEXPANDOS|0x00000040|Fade expando buttons in or out when the mouse moves away or into a state of hovering over the control. +TVS_EX_PARTIALCHECKBOXES|0x00000080|Include partial checkbox state if the control has the TVS_CHECKBOXES style. +TVS_EX_EXCLUSIONCHECKBOXES|0x00000100|Include exclusion checkbox state if the control has the TVS_CHECKBOXES style. +TVS_EX_DIMMEDCHECKBOXES|0x00000200|Include dimmed checkbox state if the control has the TVS_CHECKBOXES style. +TVS_EX_DRAWIMAGEASYNC|0x00000400|Retrieves calendar grid information. + +[msctls_statusbar32] +SBARS_SIZEGRIP|0x00000100|The status bar control will include a sizing grip at the right end of the status bar. A sizing grip is similar to a sizing border; it is a rectangular area that the user can click and drag to resize the parent window. +SBARS_TOOLTIPS|0x00000800|Use this style to enable tooltips. + +[SysLink] +LWS_TRANSPARENT|0x00000001|The background mix mode is transparent. +LWS_IGNORERETURN|0x00000002|When the link has keyboard focus and the user presses Enter, the keystroke is ignored by the control and passed to the host dialog box. +LWS_NOPREFIX|0x00000004|Windows Vista. If the text contains an ampersand, it is treated as a literal character rather than the prefix to a shortcut key. +LWS_USEVISUALSTYLE|0x00000008|Windows Vista. The link is displayed in the current visual style. +LWS_USECUSTOMTEXT|0x00000010|Windows Vista. An NM_CUSTOMTEXT notification is sent when the control is drawn, so that the application can supply text dynamically. +LWS_RIGHT|0x00000020|Windows Vista. The text is right-justified. + +[msctls_trackbar32] +TBS_HORZ|0x00000000|The trackbar control is oriented horizontally. This is the default orientation. +TBS_BOTTOM|0x00000000|The trackbar control displays tick marks below the control. This style is valid only with TBS_HORZ. +TBS_RIGHT|0x00000000|The trackbar control displays tick marks to the right of the control. This style is valid only with TBS_VERT. +TBS_AUTOTICKS|0x00000001|The trackbar control has a tick mark for each increment in its range of values. +TBS_VERT|0x00000002|The trackbar control is oriented vertically. +TBS_TOP|0x00000004|The trackbar control displays tick marks above the control. This style is valid only with TBS_HORZ. +TBS_LEFT|0x00000004|The trackbar control displays tick marks to the left of the control. This style is valid only with TBS_VERT. +TBS_BOTH|0x00000008|The trackbar control displays tick marks on both sides of the control. This will be both top and bottom when used with TBS_HORZ or both left and right if used with TBS_VERT. +TBS_NOTICKS|0x00000010|The trackbar control does not display any tick marks. +TBS_ENABLESELRANGE|0x00000020|The trackbar control displays a selection range only. The tick marks at the starting and ending positions of a selection range are displayed as triangles (instead of vertical dashes), and the selection range is highlighted. +TBS_FIXEDLENGTH|0x00000040|The trackbar control allows the size of the slider to be changed with the TBM_SETTHUMBLENGTH message. +TBS_NOTHUMB|0x00000080|The trackbar control does not display a slider. +TBS_TOOLTIPS|0x00000100|The trackbar control supports tooltips. When a trackbar control is created using this style, it automatically creates a default tooltip control that displays the slider's current position. You can change where the tooltips are displayed by using the TBM_SETTIPSIDE message. +TBS_REVERSED|0x00000200|This style bit is used for "reversed" trackbars, where a smaller number indicates "higher" and a larger number indicates "lower." It has no effect on the control; it is simply a label that can be checked to determine whether a trackbar is normal or reversed. +TBS_DOWNISLEFT|0x400|By default, the trackbar control uses down equal to right and up equal to left. Use the TBS_DOWNISLEFT style to reverse the default, making down equal left and up equal right. +TBS_NOTIFYBEFOREMOVE|0x800|Trackbar should notify parent before repositioning the slider due to user action (enables snapping). +TBS_TRANSPARENTBKGND|0x1000|Background is painted by the parent via the WM_PRINTCLIENT message. + +[msctls_updown32] +UDS_WRAP|0x00000001|Causes the position to "wrap" if it is incremented or decremented beyond the ending or beginning of the range. +UDS_SETBUDDYINT|0x00000002|Causes the up-down control to set the text of the buddy window (using the WM_SETTEXT message) when the position changes. The text consists of the position formatted as a decimal or hexadecimal string. +UDS_ALIGNRIGHT|0x00000004|Positions the up-down control next to the right edge of the buddy window. The width of the buddy window is decreased to accommodate the width of the up-down control. +UDS_ALIGNLEFT|0x00000008|Positions the up-down control next to the left edge of the buddy window. The buddy window is moved to the right, and its width is decreased to accommodate the width of the up-down control. +UDS_AUTOBUDDY|0x00000010|Automatically selects the previous window in the z-order as the up-down control's buddy window. +UDS_ARROWKEYS|0x00000020|Causes the up-down control to increment and decrement the position when the UP ARROW and DOWN ARROW keys are pressed. +UDS_HORZ|0x00000040|Causes the up-down control's arrows to point left and right instead of up and down. +UDS_NOTHOUSANDS|0x00000080|Does not insert a thousands separator between every three decimal digits. +UDS_HOTTRACK|0x00000100|Causes the control to exhibit "hot tracking" behavior. That is, it highlights the UP ARROW and DOWN ARROW on the control as the pointer passes over them. This style requires Windows 98 or Windows 2000. If the system is running Windows 95 or Windows NT 4.0, the flag is ignored. To check whether hot tracking is enabled, call SystemParametersInfo. + +[msctls_progress32] +PBS_SMOOTH|0x00000001|The progress bar displays progress status in a smooth scrolling bar instead of the default segmented bar.\n\nNote: This style is supported only in the Windows Classic theme. All other themes override this style. +PBS_VERTICAL|0x00000004|The progress bar displays progress status vertically, from bottom to top. +PBS_MARQUEE|0x00000008|The progress indicator does not grow in size but instead moves repeatedly along the length of the bar, indicating activity without specifying what proportion of the progress is complete. +PBS_SMOOTHREVERSE|0x00000010|Windows Vista. Determines the animation behavior that the progress bar should use when moving backward (from a higher value to a lower value). If this is set, then a "smooth" transition will occur, otherwise the control will "jump" to the lower value. + +[SysTabControl32] +TCS_SINGLELINE|0x00000000|Only one row of tabs is displayed. The user can scroll to see more tabs, if necessary. This style is the default. +TCS_TABS|0x00000000|Tabs appear as tabs, and a border is drawn around the display area. This style is the default. +TCS_RIGHTJUSTIFY|0x00000000|The width of each tab is increased, if necessary, so that each row of tabs fills the entire width of the tab control. This window style is ignored unless the TCS_MULTILINE style is also specified. +TCS_SCROLLOPPOSITE|0x00000001|Unneeded tabs scroll to the opposite side of the control when a tab is selected. +TCS_BOTTOM|0x00000002|Tabs appear at the bottom of the control. This value equals TCS_RIGHT. +TCS_MULTISELECT|0x00000004|Multiple tabs can be selected by holding down the CTRL key when clicking. This style must be used with the TCS_BUTTONS style. +TCS_FLATBUTTONS|0x00000008|Selected tabs appear as being indented into the background while other tabs appear as being on the same plane as the background. This style only affects tab controls with the TCS_BUTTONS style. +TCS_FORCEICONLEFT|0x00000010|Icons are aligned with the left edge of each fixed-width tab. This style can only be used with the TCS_FIXEDWIDTH style. +TCS_FORCELABELLEFT|0x00000020|Labels are aligned with the left edge of each fixed-width tab; that is, the label is displayed immediately to the right of the icon instead of being centered. This style can only be used with the TCS_FIXEDWIDTH style, and it implies the TCS_FORCEICONLEFT style. +TCS_HOTTRACK|0x00000040|Items under the pointer are automatically highlighted. You can check whether hot tracking is enabled by calling SystemParametersInfo. +TCS_VERTICAL|0x00000080|Tabs appear at the left side of the control, with tab text displayed vertically. This style is valid only when used with the TCS_MULTILINE style. To make tabs appear on the right side of the control, also use the TCS_RIGHT style. +TCS_BUTTONS|0x00000100|Tabs appear as buttons, and no border is drawn around the display area. +TCS_MULTILINE|0x00000200|Multiple rows of tabs are displayed, if necessary, so all tabs are visible at once. +TCS_FIXEDWIDTH|0x00000400|All tabs are the same width. This style cannot be combined with the TCS_RIGHTJUSTIFY style. +TCS_RAGGEDRIGHT|0x00000800|Rows of tabs will not be stretched to fill the entire width of the control. This style is the default. +TCS_FOCUSONBUTTONDOWN|0x00001000|The tab control receives the input focus when clicked. +TCS_OWNERDRAWFIXED|0x00002000|The parent window is responsible for drawing tabs. +TCS_TOOLTIPS|0x00004000|The tab control has a tooltip control associated with it. +TCS_FOCUSNEVER|0x00008000|The tab control does not receive the input focus when clicked. + +[SysTabControl32Ex] +TCS_EX_FLATSEPARATORS|0x00000001|The tab control will draw separators between the tab items. This extended style only affects tab controls that have the TCS_BUTTONS and TCS_FLATBUTTONS styles. By default, creating the tab control with the TCS_FLATBUTTONS style sets this extended style. If you do not require separators, you should remove this extended style after creating the control. +TCS_EX_REGISTERDROP|0x00000002|The tab control generates TCN_GETOBJECT notification codes to request a drop target object when an object is dragged over the tab items in the control. The application must call CoInitialize or OleInitialize before setting this style. + +[SysMonthCal32] +MCS_DAYSTATE|0x00000001|The month calendar sends MCN_GETDAYSTATE notifications to request information about which days should be displayed in bold. +MCS_MULTISELECT|0x00000002|The month calendar enables the user to select a range of dates within the control. By default, the maximum range is one week. You can change the maximum range that can be selected by using the MCM_SETMAXSELCOUNT message. +MCS_WEEKNUMBERS|0x00000004|The month calendar control displays week numbers (1-52) to the left of each row of days. Week 1 is defined as the first week that contains at least four days. +MCS_NOTODAYCIRCLE|0x00000008|The month calendar control does not circle the "today" date. +MCS_NOTODAY|0x00000010|The month calendar control does not display the "today" date at the bottom of the control. +MCS_NOTRAILINGDATES|0x00000040|Dates from the previous and next months are not displayed in the current month's calendar. +MCS_SHORTDAYSOFWEEK|0x00000080|Short day names are displayed in the header. +MCS_NOSELCHANGEONNAV|0x00000100|The selection is not changed when the user navigates next or previous in the calendar. This allows the user to select a range larger than is visible. + +[SysDateTimePick32] +DTS_SHORTDATEFORMAT|0x00000000|Displays the date in short format. The default format string for this style is defined by LOCALE_SSHORTDATE, which produces output like "4/19/96". +DTS_UPDOWN|0x00000001|Places an up-down control to the right of the DTP control to modify date-time values. This style can be used in place of the drop-down month calendar, which is the default style. +DTS_SHOWNONE|0x00000002|It is possible to have no date currently selected in the control. With this style, the control displays a check box that is automatically selected whenever a date is picked or entered. If the check box is subsequently deselected, the application cannot retrieve the date from the control because, in essence, the control has no date. The state of the check box can be set with the DTM_SETSYSTEMTIME message or queried with the DTM_GETSYSTEMTIME message. +DTS_LONGDATEFORMAT|0x00000004|Displays the date in long format. The default format string for this style is defined by LOCALE_SLONGDATEFORMAT, which produces output like "Friday, April 19, 1996". When this style is used, the dropdown button does not display an icon. +DTS_SHORTDATECENTURYFORMAT|0x0000000C|Similar to the DTS_SHORTDATEFORMAT style, except the year is a four-digit field. The default format string for this style is based on LOCALE_SSHORTDATE. The output looks like: "4/19/1996". +DTS_TIMEFORMAT|0x00000009|Displays the time. The default format string for this style is defined by LOCALE_STIMEFORMAT, which produces output like "5:31:42 PM". +DTS_APPCANPARSE|0x00000010|Allows the owner to parse user input and take necessary action. It enables users to edit within the client area of the control when they press the F2 key. The control sends DTN_USERSTRING notification codes when users are finished. +DTS_RIGHTALIGN|0x00000020|The drop-down month calendar will be right-aligned with the control instead of left-aligned, which is the default. + +[ToolbarWindow32] +TBSTYLE_TOOLTIPS|0x00000100|Creates a tooltip control that an application can use to display descriptive text for the buttons in the toolbar. +TBSTYLE_WRAPABLE|0x00000200|Creates a toolbar that can have multiple lines of buttons. Toolbar buttons can "wrap" to the next line when the toolbar becomes too narrow to include all buttons on the same line. When the toolbar is wrapped, the break will occur on either the rightmost separator or the rightmost button if there are no separators on the bar. This style must be set to display a vertical toolbar control when the toolbar is part of a vertical rebar control. This style cannot be combined with CCS_VERT. +TBSTYLE_ALTDRAG|0x00000400|Allows users to change a toolbar button's position by dragging it while holding down the ALT key. If this style is not specified, the user must hold down the SHIFT key while dragging a button. Note that the CCS_ADJUSTABLE style must be specified to enable toolbar buttons to be dragged. +TBSTYLE_FLAT|0x00000800|Creates a flat toolbar. In a flat toolbar, both the toolbar and the buttons are transparent and hot-tracking is enabled. Button text appears under button bitmaps. To prevent repainting problems, this style should be set before the toolbar control becomes visible. +TBSTYLE_LIST|0x00001000|Creates a flat toolbar with button text to the right of the bitmap. Otherwise, this style is identical to TBSTYLE_FLAT. To prevent repainting problems, this style should be set before the toolbar control becomes visible. +TBSTYLE_CUSTOMERASE|0x00002000|Generates NM_CUSTOMDRAW notification codes when the toolbar processes WM_ERASEBKGND messages. +TBSTYLE_REGISTERDROP|0x00004000|Generates TBN_GETOBJECT notification codes to request drop target objects when the cursor passes over toolbar buttons. +TBSTYLE_TRANSPARENT|0x00008000|Creates a transparent toolbar. In a transparent toolbar, the toolbar is transparent but the buttons are not. Button text appears under button bitmaps. To prevent repainting problems, this style should be set before the toolbar control becomes visible. + +[ToolbarWindow32Ex] +TBSTYLE_EX_DRAWDDARROWS|0x00000001|This style allows buttons to have a separate dropdown arrow. Buttons that have the BTNS_DROPDOWN style will be drawn with a dropdown arrow in a separate section, to the right of the button. If the arrow is clicked, only the arrow portion of the button will depress, and the toolbar control will send a TBN_DROPDOWN notification code to prompt the application to display the dropdown menu. If the main part of the button is clicked, the toolbar control sends a WM_COMMAND message with the button's ID. The application normally responds by launching the first command on the menu.\n\nThere are many situations where you may want to have only some of the dropdown buttons on a toolbar with separated arrows. To do so, set the TBSTYLE_EX_DRAWDDARROWS extended style. Give those buttons that will not have separated arrows the BTNS_WHOLEDROPDOWN style. Buttons with this style will have an arrow displayed next to the image. However, the arrow will not be separate and when any part of the button is clicked, the toolbar control will send a TBN_DROPDOWN notification code. To prevent repainting problems, this style should be set before the toolbar control becomes visible. +TBSTYLE_EX_MULTICOLUMN|0x00000002|Intended for internal use; not recommended for use in applications. This style gives the toolbar a vertical orientation and organizes the toolbar buttons into columns. The buttons flow down vertically until a button has exceeded the bounding height of the toolbar (see TB_SETBOUNDINGSIZE), and then a new column is created. The toolbar flows the buttons in this manner until all buttons are positioned. To use this style, the TBSTYLE_EX_VERTICAL style must also be set. +TBSTYLE_EX_VERTICAL|0x00000004|Intended for internal use; not recommended for use in applications. This style gives the toolbar a vertical orientation. Toolbar buttons flow from top to bottom instead of horizontally. +TBSTYLE_EX_MIXEDBUTTONS|0x00000008|This style allows you to set text for all buttons, but only display it for those buttons with the BTNS_SHOWTEXT button style. The TBSTYLE_LIST style must also be set. Normally, when a button does not display text, your application must handle TBN_GETINFOTIP or TTN_GETDISPINFO to display a tooltip. With the TBSTYLE_EX_MIXEDBUTTONS extended style, text that is set but not displayed on a button will automatically be used as the button's tooltip text. Your application only needs to handle TBN_GETINFOTIP or or TTN_GETDISPINFO if it needs more flexibility in specifying the tooltip text. +TBSTYLE_EX_HIDECLIPPEDBUTTONS|0x00000010|This style hides partially clipped buttons. The most common use of this style is for toolbars that are part of a rebar control. If an adjacent band covers part of a button, the button will not be displayed. However, if the rebar band has the RBBS_USECHEVRON style, the button will be displayed on the chevron's dropdown menu. +TBSTYLE_EX_DOUBLEBUFFER|0x00000080|This style requires the toolbar to be double buffered. Double buffering is a mechanism that detects when the toolbar has changed. + +[RebarWindow32] +RBS_TOOLTIPS|0x00000100|Not yet supported. +RBS_VARHEIGHT|0x00000200|The rebar control displays bands at the minimum required height, when possible. Without this style, the rebar control displays all bands at the same height, using the height of the tallest visible band to determine the height of other bands. +RBS_BANDBORDERS|0x00000400|The rebar control displays narrow lines to separate adjacent bands. +RBS_FIXEDORDER|0x00000800|The rebar control always displays bands in the same order. You can move bands to different rows, but the band order is static. +RBS_REGISTERDROP|0x00001000|The rebar control generates RBN_GETOBJECT notification codes when an object is dragged over a band in the control. To receive the RBN_GETOBJECT notifications, initialize OLE with a call to OleInitialize or CoInitialize. +RBS_AUTOSIZE|0x00002000|The rebar control will automatically change the layout of the bands when the size or position of the control changes. An RBN_AUTOSIZE notification will be sent when this occurs. +RBS_VERTICALGRIPPER|0x00004000|The size grip will be displayed vertically instead of horizontally in a vertical rebar control. This style is ignored for rebar controls that do not have the CCS_VERT style. +RBS_DBLCLKTOGGLE|0x00008000|The size grip will be displayed vertically instead of horizontally in a vertical rebar control. This style is ignored for rebar controls that do not have the CCS_VERT style. + +[ScrollBar] +SBS_HORZ|0x00000000|Designates a horizontal scroll bar. If neither the SBS_BOTTOMALIGN nor SBS_TOPALIGN style is specified, the scroll bar has the height, width, and position specified by the x, y, nWidth, and nHeight parameters of CreateWindowEx. +SBS_VERT|0x00000001|Designates a vertical scroll bar. If you specify neither the SBS_RIGHTALIGN nor the SBS_LEFTALIGN style, the scroll bar has the height, width, and position specified by the x, y, nWidth, and nHeight parameters of CreateWindowEx. +SBS_TOPALIGN|0x00000002|Aligns the top edge of the scroll bar with the top edge of the rectangle defined by the x, y, nWidth, and nHeight parameters of CreateWindowEx. The scroll bar has the default height for system scroll bars. Use this style with the SBS_HORZ style. +SBS_LEFTALIGN|0x00000002|Aligns the left edge of the scroll bar with the left edge of the rectangle defined by the x, y, nWidth, and nHeight parameters of CreateWindowEx. The scroll bar has the default width for system scroll bars. Use this style with the SBS_VERT style. +SBS_SIZEBOXTOPLEFTALIGN|0x00000002|Aligns the upper left corner of the size box with the upper left corner of the rectangle specified by the x, y, nWidth, and nHeight parameters of CreateWindowEx. The size box has the default size for system size boxes. Use this style with the SBS_SIZEBOX style. +SBS_BOTTOMALIGN|0x00000004|Aligns the bottom edge of the scroll bar with the bottom edge of the rectangle defined by the x, y, nWidth, and nHeight parameters of CreateWindowEx function. The scroll bar has the default height for system scroll bars. Use this style with the SBS_HORZ style. +SBS_RIGHTALIGN|0x00000004|Aligns the right edge of the scroll bar with the right edge of the rectangle defined by the x, y, nWidth, and nHeight parameters of CreateWindowEx. The scroll bar has the default width for system scroll bars. Use this style with the SBS_VERT style. +SBS_SIZEBOXBOTTOMRIGHTALIGN|0x00000004|Aligns the lower right corner of the size box with the lower right corner of the rectangle specified by the x, y, nWidth, and nHeight parameters of CreateWindowEx. The size box has the default size for system size boxes. Use this style with the SBS_SIZEBOX style. +SBS_SIZEBOX|0x00000008|Designates a size box. If you specify neither the SBS_SIZEBOXBOTTOMRIGHTALIGN nor the SBS_SIZEBOXTOPLEFTALIGN style, the size box has the height, width, and position specified by the x, y, nWidth, and nHeight parameters of CreateWindowEx. +SBS_SIZEGRIP|0x00000010|Same as SBS_SIZEBOX, but with a raised edge. + +[SysPager] +PGS_VERT|0x00000000|Creates a pager control that can be scrolled vertically. This is the default direction if no direction style is specified. This style and the PGS_HORZ style are mutually exclusive and cannot be combined. +PGS_HORZ|0x00000001|Creates a pager control that can be scrolled horizontally. This style and the PGS_VERT style are mutually exclusive and cannot be combined. +PGS_AUTOSCROLL|0x00000002|The pager control will scroll when the user hovers the mouse over one of the scroll buttons. +PGS_DRAGNDROP|0x00000004|The contained window can be a drag-and-drop target. The pager control will automatically scroll if an item is dragged from outside the pager over one of the scroll buttons. + +[SysAnimate] +ACS_CENTER|0x00000001|Centers the animation in the animation control's window. +ACS_TRANSPARENT|0x00000002|Allows you to match an animation's background color to that of the underlying window, creating a "transparent" background. The parent of the animation control must not have the WS_CLIPCHILDREN style (see Window Styles). The control sends a WM_CTLCOLORSTATIC message to its parent. Use SetBkColor to set the background color for the device context to an appropriate value. The control interprets the upper-left pixel of the first frame as the animation's default background color. It will remap all pixels with that color to the value you supplied in response to WM_CTLCOLORSTATIC. +ACS_AUTOPLAY|0x00000004|Starts playing the animation as soon as the AVI clip is opened. +ACS_TIMER|0x00000008|By default, the control creates a thread to play the AVI clip. If you set this flag, the control plays the clip without creating a thread; internally the control uses a Win32 timer to synchronize playback.\n\nComctl32.dll version 6 and later: This style is not supported. By default, the control plays the AVI clip without creating a thread. + +[ComboBoxExEx] +CBES_EX_NOEDITIMAGE|0x00000001|The edit box and the dropdown list will not display item images. +CBES_EX_NOEDITIMAGEINDENT|0x00000002|The edit box and the dropdown list will not display item images. +CBES_EX_PATHWORDBREAKPROC|0x00000004|Windows NT only. The edit box will use the slash (/), backslash (\), and period (.) characters as word delimiters. This makes keyboard shortcuts for word-by-word cursor movement effective in path names and URLs. +CBES_EX_NOSIZELIMIT|0x00000008|Allows the ComboBoxEx control to be vertically sized smaller than its contained combo box control. If the ComboBoxEx is sized smaller than the combo box, the combo box will be clipped. +CBES_EX_CASESENSITIVE|0x00000010|BSTR searches in the list will be case sensitive. This includes searches as a result of text being typed in the edit box and the CB_FINDSTRINGEXACT message. +CBES_EX_TEXTENDELLIPSIS|0x00000020|Causes items in the drop-down list and the edit box (when the edit box is read only) to be truncated with an ellipsis ("...") rather than just clipped by the edge of the control. This is useful when the control needs to be set to a fixed width, yet the entries in the list may be long. + +[#32770] +DS_3DLOOK|0x00000004|Obsolete. The system automatically applies the three-dimensional look to dialog boxes created by applications. +DS_ABSALIGN|0x00000001|Indicates that the coordinates of the dialog box are screen coordinates. If this style is not specified, the coordinates are client coordinates. +DS_CENTER|0x00000800|Centers the dialog box in the working area of the monitor that contains the owner window. If no owner window is specified, the dialog box is centered in the working area of a monitor determined by the system. The working area is the area not obscured by the taskbar or any appbars. +DS_CENTERMOUSE|0x00001000|Centers the dialog box on the mouse cursor. +DS_CONTEXTHELP|0x00002000|Includes a question mark in the title bar of the dialog box. When the user clicks the question mark, the cursor changes to a question mark with a pointer. If the user then clicks a control in the dialog box, the control receives a WM_HELP message. The control should pass the message to the dialog box procedure, which should call the function using the HELP_WM_HELP command. The help application displays a pop-up window that typically contains help for the control.\n\nNote that DS_CONTEXTHELP is only a placeholder. When the dialog box is created, the system checks for DS_CONTEXTHELP and, if it is there, adds WS_EX_CONTEXTHELP to the extended style of the dialog box. WS_EX_CONTEXTHELP cannot be used with the WS_MAXIMIZEBOX or WS_MINIMIZEBOX styles. +DS_CONTROL|0x00000400|Creates a dialog box that works well as a child window of another dialog box, much like a page in a property sheet. This style allows the user to tab among the control windows of a child dialog box, use its accelerator keys, and so on. +DS_FIXEDSYS|0x00000008|Causes the dialog box to use the SYSTEM_FIXED_FONT instead of the default SYSTEM_FONT. This is a monospace font compatible with the System font in 16-bit versions of Windows earlier than 3.0. +DS_LOCALEDIT|0x00000020|Applies to 16-bit applications only. This style directs edit controls in the dialog box to allocate memory from the application's data segment. Otherwise, edit controls allocate storage from a global memory object. +DS_MODALFRAME|0x00000080|Creates a dialog box with a modal dialog-box frame that can be combined with a title bar and window menu by specifying the WS_CAPTION and WS_SYSMENU styles. +DS_NOFAILCREATE|0x00000010|Creates the dialog box even if errors occur - for example, if a child window cannot be created or if the system cannot create a special data segment for an edit control. +DS_NOIDLEMSG|0x00000100|Suppresses WM_ENTERIDLE messages that the system would otherwise send to the owner of the dialog box while the dialog box is displayed. +DS_SETFONT|0x00000040|Indicates that the header of the dialog box template (either standard or extended) contains additional data specifying the font to use for text in the client area and controls of the dialog box. If possible, the system selects a font according to the specified font data. The system passes a handle to the font to the dialog box and to each control by sending them the WM_SETFONT message. For descriptions of the format of this font data, see DLGTEMPLATE and DLGTEMPLATEEX.\n\nIf neither DS_SETFONT nor DS_SHELLFONT is specified, the dialog box template does not include the font data. +DS_SETFOREGROUND|0x00000200|Causes the system to use the SetForegroundWindow function to bring the dialog box to the foreground. This style is useful for modal dialog boxes that require immediate attention from the user regardless of whether the owner window is the foreground window.\n\nThe system restricts which processes can set the foreground window. For more information, see Foreground and Background Windows. +DS_SHELLFONT|0x00000048|Indicates that the dialog box should use the system font. The typeface member of the extended dialog box template must be set to MS Shell Dlg. Otherwise, this style has no effect. It is also recommended that you use the DIALOGEX Resource, rather than the DIALOG Resource. For more information, see Dialog Box Fonts.\n\nThe system selects a font using the font data specified in the pointsize, weight, and italic members. The system passes a handle to the font to the dialog box and to each control by sending them the WM_SETFONT message. For descriptions of the format of this font data, see DLGTEMPLATEEX.\n\nIf neither DS_SHELLFONT nor DS_SETFONT is specified, the extended dialog box template does not include the font data. +DS_SYSMODAL|0x00000002|This style is obsolete and is included for compatibility with 16-bit versions of Windows. If you specify this style, the system creates the dialog box with the WS_EX_TOPMOST style. This style does not prevent the user from accessing other windows on the desktop.\n\nDo not combine this style with the DS_CONTROL style. + +[CommonControls] +CCS_TOP|0x00000001|Causes the control to position itself at the top of the parent window's client area and sets the width to be the same as the parent window's width. Toolbars have this style by default. +CCS_NOMOVEY|0x00000002|Causes the control to resize and move itself horizontally, but not vertically, in response to a WM_SIZE message. If CCS_NORESIZE is used, this style does not apply. Header windows have this style by default. +CCS_BOTTOM|0x00000003|Causes the control to position itself at the bottom of the parent window's client area and sets the width to be the same as the parent window's width. Status windows have this style by default. +CCS_NORESIZE|0x00000004|Prevents the control from using the default width and height when setting its initial size or a new size. Instead, the control uses the width and height specified in the request for creation or sizing. +CCS_NOPARENTALIGN|0x00000008|Prevents the control from automatically moving to the top or bottom of the parent window. Instead, the control keeps its position within the parent window despite changes to the size of the parent. If CCS_TOP or CCS_BOTTOM is also used, the height is adjusted to the default, but the position and width remain unchanged. +CCS_ADJUSTABLE|0x00000020|Enables a toolbar's built-in customization features, which let the user to drag a button to a new position or to remove a button by dragging it off the toolbar. In addition, the user can double-click the toolbar to display the Customize Toolbar dialog box, which enables the user to add, delete, and rearrange toolbar buttons. +CCS_NODIVIDER|0x00000040|Prevents a two-pixel highlight from being drawn at the top of the control. +CCS_VERT|0x00000080|Causes the control to be displayed vertically. +CCS_LEFT|0x00000081|Causes the control to be displayed vertically on the left side of the parent window. +CCS_NOMOVEX|0x00000082|Causes the control to resize and move itself vertically, but not horizontally, in response to a WM_SIZE message. If CCS_NORESIZE is used, this style does not apply. +CCS_RIGHT|0x00000083|Causes the control to be displayed vertically on the right side of the parent window. + +[SysHeader32] +HDS_HORZ|0x00000000|Creates a header control with a horizontal orientation. +HDS_BUTTONS|0x00000002|Each item in the control looks and behaves like a push button. This style is useful if an application carries out a task when the user clicks an item in the header control. For example, an application could sort information in the columns differently depending on which item the user clicks. +HDS_HOTTRACK|0x00000004|Enables hot tracking. +HDS_HIDDEN|0x00000008|Indicates a header control that is intended to be hidden. This style does not hide the control. Instead, when you send the HDM_LAYOUT message to a header control with the HDS_HIDDEN style, the control returns zero in the cy member of the WINDOWPOS structure. You would then hide the control by setting its height to zero. This can be useful when you want to use the control as an information container instead of a visual control. +HDS_DRAGDROP|0x00000040|Allows drag-and-drop reordering of header items. +HDS_FULLDRAG|0x00000080|Causes the header control to display column contents even while the user resizes a column. +HDS_FILTERBAR|0x00000100|Include a filter bar as part of the standard header control. This bar allows users to conveniently apply a filter to the display. Calls to HDM_LAYOUT will yield a new size for the control and cause the list view to update. +HDS_FLAT|0x00000200|Causes the header control to be drawn flat when the operating system is running in classic mode. +HDS_CHECKBOXES|0x00000400|Allows the placing of checkboxes on header items. For more information, see the fmt member of HDITEM. +HDS_NOSIZING|0x00000800|The user cannot drag the divider on the header control. +HDS_OVERFLOW|0x00001000|A button is displayed when not all items can be displayed within the header control's rectangle. When clicked, this button sends an HDN_OVERFLOWCLICK notification. + +[tooltips_class32] +TTS_ALWAYSTIP|0x00000001|Indicates that the tooltip control appears when the cursor is on a tool, even if the tooltip control's owner window is inactive. Without this style, the tooltip appears only when the tool's owner window is active. +TTS_NOPREFIX|0x00000002|Prevents the system from stripping ampersand characters from a string or terminating a string at a tab character. Without this style, the system automatically strips ampersand characters and terminates a string at the first tab character. This allows an application to use the same string as both a menu item and as text in a tooltip control. +TTS_NOANIMATE|0x00000010|Disables sliding tooltip animation on Windows 98 and Windows 2000 systems. This style is ignored on earlier systems. +TTS_NOFADE|0x00000020|Disables fading tooltip animation. +TTS_BALLOON|0x00000040|Indicates that the tooltip control has the appearance of a cartoon "balloon," with rounded corners and a stem pointing to the item. +TTS_CLOSE|0x00000080|Displays a Close button on the tooltip. Valid only when the tooltip has the TTS_BALLOON style and a title; see TTM_SETTITLE. +TTS_USEVISUALSTYLE|0x00000100|Uses themed hyperlinks. The theme will define the styles for any links in the tooltip. This style always requires TTF_PARSELINKS to be set. + +[RICHEDIT50W] +ES_SAVESEL|0x00008000|Preserves the selection when the control loses the focus. By default, the entire contents of the control are selected when it regains the focus. +ES_SUNKEN|0x00004000|Displays the control with a sunken border style so that the rich edit control appears recessed into its parent window. +ES_DISABLENOSCROLL|0x00002000|Disables scroll bars instead of hiding them when they are not needed. +ES_SELECTIONBAR|0x01000000|Adds space to the left margin where the cursor changes to a right-up arrow, allowing the user to select full lines of text. +ES_NOOLEDRAGDROP|0x00000008|Disables support for drag-drop of OLE objects. +ES_EX_NOCALLOLEINIT|0x00000000|Obsolete. Prevents the control from calling the OleInitialize function when created. This window style is useful only in dialog templates because CreateWindowEx does not accept this style. +ES_VERTICAL|0x00400000|Draws text and objects in a vertical direction. This style is available for Asian-language support only. +ES_NOIME|0x00080000|Disables the IME operation. This style is available for Asian language support only. +ES_SELFIME|0x00040000|Directs the rich edit control to allow the application to handle all IME operations. This style is available for Asian language support only. +ES_AUTOHSCROLL|0x00000080|Automatically scrolls text to the right by 10 characters when the user types a character at the end of the line. When the user presses the ENTER key, the control scrolls all text back to position zero. +ES_AUTOVSCROLL|0x00000040|Automatically scrolls text up one page when the user presses the ENTER key on the last line. +ES_CENTER|0x00000001|Centers text in a single-line or multiline edit control. +ES_LEFT|0x00000000|Left aligns text. +ES_MULTILINE|0x00000004|Designates a multiline edit control. The default is single-line edit control. +ES_NOHIDESEL|0x00000100|Negates the default behavior for an edit control. The default behavior hides the selection when the control loses the input focus and inverts the selection when the control receives the input focus. If you specify ES_NOHIDESEL, the selected text is inverted, even if the control does not have the focus. +ES_NUMBER|0x00002000|Allows only digits to be entered into the edit control. +ES_PASSWORD|0x00000020|Displays an asterisk (*) for each character typed into the edit control. This style is valid only for single-line edit controls. +ES_READONLY|0x00000800|Prevents the user from typing or editing text in the edit control. +ES_RIGHT|0x00000002|Right aligns text in a single-line or multiline edit control. +ES_WANTRETURN|0x00001000|Specifies that a carriage return be inserted when the user presses the ENTER key while entering text into a multiline edit control in a dialog box. If you do not specify this style, pressing the ENTER key has the same effect as pressing the dialog box's default push button. This style has no effect on a single-line edit control. diff --git a/thirdparty/WinSpy/Resources/CrossHair.cur b/thirdparty/WinSpy/Resources/CrossHair.cur new file mode 100644 index 0000000000000000000000000000000000000000..ae6c1cdb2db4f47e3f783142a3d62b2db889583d GIT binary patch literal 326 zcmb7;u?@mN3`O510tFO7gAiR(LdOQV5!i@KzzST6C^H0eASOsjh4CjysbkCM```at zhKxX6L*aQ0um$#BP7%F==P&+k0OMA?eQBX$7gN!&dvH@_A1OC<=HN)#;#Rk`K~gaUTNsU;x(5}dimtno-gme BbH4xp literal 0 HcmV?d00001 diff --git a/thirdparty/WinSpy/Resources/FindTool1.bmp b/thirdparty/WinSpy/Resources/FindTool1.bmp new file mode 100644 index 0000000000000000000000000000000000000000..2ef3e0db540464404850ccd87c6ad9cf7fc7c0a5 GIT binary patch literal 634 zcmb7AF%H5o47?(w3?K!G6^XxeVPfe!*cd7?^<7MP0FUtx%-L?MHgv&_9beApI%)5( z9o*iG5BimUp*Pqw0;K`Yhwu}zd3)=g#{FaCZz{-%(~zui*=lFHr|!ai)yT~KCA1kzRJrlo;_ z0f-nH8Xy#q1Tq;895?`^K@$JLh~fW#5DSQb5F`X5&;UPB5D74h@{vLV7+#cy2U>75 Wu$S|kfdlq(26lF2K0Agyx_$t?7iU-i literal 0 HcmV?d00001 diff --git a/thirdparty/WinSpy/Resources/Search.ico b/thirdparty/WinSpy/Resources/Search.ico new file mode 100644 index 0000000000000000000000000000000000000000..bbb2d29ee5ae724311779966b6036a9288916dd0 GIT binary patch literal 1150 zcmb7CT}V@57=8nx%e?Bg=ql(k2u~1;elEJ`CXgV4KosUh12I8Jh%_i;U>BpP8v_-U zB}OORQj1y`NSahwm6BGaFcGLsj$?tgd0-0yG@FI^Ymt*gSw-Rm;)nK4lBz>Kd8r92W#K@2xI@cO0( zf75wPceP>a`JJ8I+-T85-QVuWd#;5hFxsTyL)&Gfl5u3SSz?&61-!j|4r9${u$hR# zZV#Sq-si#l77fdR9yzP>XYR)fm0AQ;};H{T&#;ry=%va8C_$;jzcIoYJ#r z-0)$-t-&BheCwIt1SP64SdLHsNRI zPK4ikQSKIm(h)-YuwWPVtoyP0ujP7Hbjl>XwT(-ze{h+4d^c;J+lz0X-X*$~aid0% zxtX*7w*1Y)(tx4zXV>%6st!%bMeEahKUEcZpeAx|%ZjoUlKgWiiQvq&zp8f%sDehlbt0T}%r1hG_bMZDMOfw$%FcyY)g8>+! zOsQC#@*{1RFN7_1Y>)W~(C!AHOtoOID+Vo*^G#lqmB!T)YL%RPLpxH76EsXFybyJ$ zR(-mM$M`yf#)?eph3H4bQ4jrIJy?~ctHzqV<9s~Xt~xp1N5aB*7$VMRY-?@)RX)b+ zps`XAG)aNMyjfY!lCpxMT#RW~Eslpsm>&wj9R6;*;{FoP{Hc3eM7t?t^-7}40DgT1 z&btR1B4=^HtFesrk+ZL88@zuR0P~ZAuYYp7q1+aCC|5>tFGu?9KKAX z<(XmJdmlvI8tBC5bT?P5G9AzHEE!=WXo0w^9{jp0FiZ1S_}XF)`N2Vt=J2quDf3m> z_UrT10DOAGz^B*!urL;aw+Ro7hHa4O(6FHv@m-I$^oT)x^AOMT8u#(+P-g>7ge|Gb zm}_+&|IgW^7h+B&OXHcQ%(b|thZ%hSMjdm?jxuh=P`^WVBJQk9Pq@`zn07TpERy|U zQX&W#Yv$bAvI85rf7!IHHb~p#YxnnGIczyX%cl_fvIC*%tq2jD@H~eQiq0amb$VT* S*cJ-cV_Y65-|ryAvA+S-X!&aZ literal 0 HcmV?d00001 diff --git a/thirdparty/WinSpy/Resources/TreeIcons.icl b/thirdparty/WinSpy/Resources/TreeIcons.icl new file mode 100644 index 0000000000000000000000000000000000000000..110ae92a05e98223e77b060283d9dedaf87f9a38 GIT binary patch literal 38912 zcmeHw2S63q(*MvwkX{w_B8Xte4mPldm*T^2V)Q*sVuBqLjhH|ZY!Qu#sHh|{D$h!S z1v`1fLev=S*bx*30i{?#K;}QQd-t;U!Wz);d&&EMoXhXdo|*Zbb9VM}cK7Vr-Pgvz z3#WZA%zSy`kO2U%>gmI?b@N6^rDcGno4KBem|ZDpNm{D`Kh74G^#P1PPk^E1mP`wz z=OhZUs5nPt=8H?>g8Z9p%jF97asq&94eFOwwVM$-BbW=}I=Sv>g1X(bBqV_3ep z+ZU2FBDs#FG0A--d25^@$?eD?X-1MNiD*E=nWQ<%4kRr|4kp=<`u~&9}%Dw19#NeD?R9;6rIK~jhZNg*C2g?Nw@;z3e~2T36w zB!zewtK&gZhzCg_9wdc$kQCxUQiumhAs!@!c#st0K~jhZNg*C4>UfY8;z3e~2T36w zB!zg86yiZrhzCg_9wdc$kQCxUQizACIvym|;Q%ondSFHi{<0swTt7rXKVCsUO+haN zPhGLR{ACLM>lE|}3i@OP{TT&)hJwCOK@Y-47gs>uerpB2Nm9TfEb3i=@m`tb_-X$txX z1^qGw{W=AGf`UF-L4QU;pP`^HRL}!=ay7+YL9bHKcTmv#E9i$P=*KJQrzz+o6!gm! z^y?J#2@3jT1^pQXeTIU*P(cs8bEzr*3VM}-z60s~X-7f(Rmc+mkzlim^0d>F^46Z( z`Pr?t{WIEY+Xr`{{VW}1Nc?GCwe6RCX!HI3wey?%Yx`RVYTIYOuAR>a(yq^Rn0CIy zaP9J9=y+MazA#SPK5>G!{mevdd-o~Y<&U4LZ9hI!+g|vgwtZBXcKONS+IFvb+WBQ) zYUfM8(k@^1wRU+6S7_%8S8MY}eXq@rSO>tz8q)TP*2!Eugw@)kd6 z*Qe6Sch<=d*2%x6lb@!OkJQP>=;XKSH&X0H}PRBAFA?UYi+^)yeDC92qA*- zSuOE7`O$w2yz%`Tp8FOKbieaOKev3w=V~eCb!B*fDu4a}j|V|scBhFyEiGYnS=r-< z`1ElxmJ&(`ysQMtcgBF$H<*7V@w+0V^h}KklFtMCRT8H6_rAvbYl*7`ei`X%gL3kF zMkUM~*izu9?_Kpm{8@uVe&)WFb>>%4{c~RN6zb195Ut^J+iJ58m9z$*yxKzG-#z$^ zhW|%gE}y~th}T7aezMqpQVVhA*h)~+vHpwK+{E}Ld{T5L;}T|FKaF>8oWVQSMP$jB zNq76|Z-i5reeDG1UroX)QH699Xh)EM9SPJ<=|1>Abu)yQ9z3^nH z3U^KIhI2;-;hH%ke;=wwnF~Gge+&01`1fS z;n)-v{5stYex1=APR?|P-)4Ehso9>8I;SP1hIv7=w=Tk&Pg=p*Pg}vc&)UHG&)dSq zFWSMy$aZjPeh0X;paWc9=mS?4bb~94NG|FGSHA2B*A{n%>q|Prjip^7{j08U^XqQ# zkH~Kzm3MO&*Zc zR`6hBf5HI3ZSA1l{9-8h*FeDS?E&LE0shn-$`XjbqbEGx(H|b}7zo8X2Sf3$K-jnS zYrsQq0wyuW0{+Z+n=lSi4t)!ck1T^@$v?qKLgvx$;LPEl;K<2+aEy@h+djxYyBR9Z z{tND&-w*e1Bm-uq0A`&aoCLgc3h?glgwuf8=Kyog1Kzs;n41QecZqNXF#j6h{Tq;U zzZ|gOCLt4&AC$vk!jXbr_$%)Q|Kshq2F{#1vPF#L{K(J#7Bcaj ze~uq8d*+OmG1gx$TJYMeN$;Wl>MXgB?s#*}|`)ym~xEp&4m=hRET$(W@}16QqDwc?w; zOWoY`Vw$POEbZglrISy)zDwWi-7UsrXmj!q(wn_U^@wTS+}+*7)2nsc4jnsp_3N#( zwlOinPqa3DEN?{}zq<6Z!GS&y9Ow%ngw$XkNDJ|S>`-4qU&s#Y3k8vZkR2IBG6=Gx z#y~-IFq9CoqeB2=8KKm_g+f7G7$n9;LlU7NE|U7MFi47zg@X7fND*W-$vD8oC@4vc zhSWq_PKqYPLTXYx{QUFJfGMO)jfYdGPQjToXW;z#^N^8|QUCw?m;O(!Z`^-#1X}4N zdwuFnWN`A{QIa3r0Xgfrw`l3r-luDKzn;DHC=X4Vd$#my)2WMZkDh|vwV8*f zLF;y%yZQPFc4rrrfsuh%n~vRl1-qSt0jE|Se7XsC8#@yNm4Tr_t2UhkyOoWBy{j8} zc()bomR2@)PK}!y7`OBi?BJ55X=w zIAyy|lKM-Yz*AQ+SG%88Ukp|FS;_m_q*yxNjg6%9-$+Oyq|$kCNlGH5q@+MeY9gK2 z61W1LWIS+$@G-h^mYjTy^VioNT4{6!;NnN`d?eTpt!4WS zjXlP6rNr-RE2d9~cjK&|+gO(8wyuANxbIAN^O36OrbJMtHjp@ytRAP@?T>WF7c^rF zvM~jYBabU^EO~4pB&q;H2~u2Z8f!?3i-pi=@{2Cf8h7Ba25F3e#};^7q^Bl9b}Ef^ z*03$4^{bcl5vY&A|4am0R!^38wze9O+1At3(bLn#)6>b*)0XosJezoMrinW5=;Y+0 z2HPzKi&JA8vRkshho_^5r;BwXrxqf=iIe6dlqZx-t zLx%~pr)5v^Ny!s@^5k*Nps@r_SL6Cn`^EZsykO+Wky!S$6btU>V_xn(%)OUWBktwg z)9|;?5Z8Z5&@dc1YBUZB8j80wGx5gt>v-eZwHk5l>UA~WALBoC5td)%>&DhWm@vm( zC}Vr518xtsM{WS&^S z&L4mL@q1xmVU6a_oeOmVbC^qGSrZ9BV^X!|voCX)J7vn0_X)t5J$v>amcc%fKXc!E z@4XKQAYs<5S&C(_P4ZLA55|ulA3^{LK0ZF6r>6&f`t%VbFRN547%^gm#z*oc88T|r zs7VB1&{(*J!#rI`elj^}$dDnE3DB!ouWJ6fd{}L zjT!;_t1+cVj~>$q5;u8p(F{lS9n~eSJEIrTQrOlYE;cXDEHD2I~bs z_LV?oahYoo{|r3<|E zS^)UJIRgR+{%_5MK4U+G(5dgk^0^;C@SHDUZRAWC7P$sCEcpaxEm;k7m&AbkSNq}9 zWouyDiuv$a^mp*L6+2)aO#*Gd<`-DFb|WnQelzS{zZ~{&h=wKWx58H&x5GPe2ch?- zlkoGFH85_=FOZV(1C06UB)pw)5{~cO0AqHh!in7*;WxT={YK(NIJI{Zr0&}cr}uA# zsrysm?7?kt?$CCacJM5`d*~vZPx=uq{QD=kn4AD+|*leIJHqz8`HGMixwuck7EVUG@mq>vm8+q5xMb@OT}<&BLknhf;s=B3V?*t-u3 zFd~Hub+Y;fhRu5o=-FTpDO~6vJkY59pzaP1gILjMxY=;a-hCT8_Z!3tt7gN^hr9Z@ z4({*d;Oj8Rs*l_7hQt5n`s(oE!(Oqou`(UeYPcGJIH1hFAFTp5EcZdofyt4;bp8mQ+Z~5@4{Snihc17|+9*sX*b3*I=g z7q9=a3sbgzi%PHn7kq^As}|ySi)Q1>h^ayu zxyN=Q$3wUNlwF$y{&&QQo&O>3T_26>m(0bTYnR{#l3dn}qkAy__&(&A>hce6T7$Q* zT)^GmeT_TTF2#Ru`wn+~w+s(#jKQ6;OQ;=-@b^7i@y5?TB5xaA{>cLgLjB(_oJIA| z#QkxraD7x5mGPBOKes8J;_=|j;TrkB{Imh@TuT#p`{H8o2;~ouOy2fA?%S{e6W1-r z(+7XT%wv0T82v_c>p!28B-Fq9^J%!^(@D7hU#o>U?1){8-!A+}i0SRK$FcZoD)Mhk zm!Ed>uoypTXY9P0$noIz@A+Xlu3sD`l$CYiH+*#S0uJ?UQH{^*pLO*--pjm>dAHK> z%E=>`bMp#bKJg3Y+_;2yuU)|NhxgGG*55FwyGJ$tmD9fp^-Et_SI!HIw=Rj2%bh>z zP5kV=p_StX_(bZq|2qBd7=0Ey46GSw%7&x*DnuG{Qj%(U27MI z?}%LzzHP-k!u;?JOFs>dTNV+y&rLTo*BW$PMewx(xOubg{ft)S z|G^Bcru;Cp&dV>`RNeZe@^tl5p6#?8u8`-kGELI);dPUEo!F*vqy@Q6(zB1`r(Oww(*8waAIje_nfBFJ(&+i({mpt13Z~P z=ZZ4`DrhY#3CJKn3EIaqhGIbq-!)x}O^p|?$7-&{7Gw+e5KyP9P>QJT*iZQQyV9iO z+4E+rUL_ebWMYRlBo~>QS@#4uMU%Hh`y#T_svS6RK(x;%-_c>g5Em5+@zLUS>$IdqNJ~kg>!i=WMk*c7j$SRK6{Guk z^Jj%7Ki-8uD@MO>#-A0V7ktd0D*FraqBj z^L%+IJX~2y^R0pn$G{OV`3Nj;@QV=NIsGaGqmd5YKb%BZYbP;=KBJ zVLp9HQXEOzmIS``otRQWKqyJ0?Mg^WMaWJ|gOc=A$WBj#0s>}JK0BR|4fkn&7#7en z|DXK9|A=Dn>J9Y~_%Dw@Zx0W*7BaX61hfqZXyfPGwwqrY|DGNmLcW8aUmHKa_PzW) znzU^rerUkhvTYlW7UUcd&^{o*x@#wgfB-i&pYk2MS_cGpc(m!zwmrkz!P>e_2ahIV z`O9ua$qfhgeE!~?rHnQr{-BhntE0-=djqPn4T9}x%GY|)( zDe8ZnJ7?UWPJ|tG#CuZ1h&QUTj*08i<*ylMhlycrao=Ztn7l9$Q@$R9$G;hir`NuR zSGLc`J3q(asUKG(S5*^#;wvsV@1N~({>09>?Bm|})hGVAeDM%myd(&tzx@YpO_+pn zKZYyvy#rma?MM|4nA#El@x@@A^Zj`IV*M!GviW`7z5RVWab`W9rEwmm`bWIm6+c)$ z27fxR2#fMkvAnVbD=G`=Ms2!YTzQ{%Cr|NC)^$bxx*tBmwClUckMEwpO`vn>%3?wW zEz@~1>2BUuuD`JGEcrYVImLATe)kYjHX}YhO6Ss-NS})tX?qpx&)hW!F=HFz$$5w; z79t)FN4&P0%H(r;x@*07H{MGANRfa3)0UXIxFcpP?0^}|dSJ%lE|?J;gc&EJG2_CI zn0aamo;&=dBEK#_A)W2dzu!@Hgx0yF^jrK-OX;{bna3AsEVDL{IMt7Pm5=8_LPEeN z&70r@z676ilIgzCH@zaT`C!>sc3vaPq0_nEvL!Pkux65DkB|5L|veEzA6e7e@1pPf@H=yExqniRL0#yODg zjl%foFr@r)rSjx_nlnCz?y17W=uk{c6|ZxUPRO&Kmfz7WN8&R#E^-X}&@QBUN>59n z)AwMukCvAq@wxo8ltkg4KW6j&f4YgwU_V_xuU|a1xj=o-U_nU%#-_!gcdR$Yrp5|- zsVrVMc|5rOI3Y&yf*iDLKzaD*Doq0P}2tHbDU}aiOl782c`sJ z-_$_#P4X4Xp?1g<`%CM<{OGVTn35Ea*~DkWXUAhu8kLa}DDY#`Vm0yL?GhELUB9&c z%;h#@7i3czi9$Q#(&K2o3N+Q%wEn_6P+aNx1j2eq?cjJy>%{BDb=MSs=2KiI^Y%}r zZ78)v;&M4Oo`dS&#~^9lSu$5bT594OTt2r^hzG@#+Y}!iQmtO842dh3LOh~^h2KBN zR=&L@o+RZwX}K={e^S3u+K0w>n*n4{N5^JDr#3dxi)fsi;R2*QE` z2|*A^NTub-kTLXZj37t~35KXp8lxld*lBcF2*gG*LTMZ|3{s*ZAw60gPfesT)x_8+ z8o!GoS@moTzF#GUA$u-HIz1aBh2|CUb1_O1>6sXb@lZm~#*mNWmC$oCs4o!4XA5ZT zE|2E_eU=(9Ol3 z@~X$A%WB0c3Y~b8FV8wVq}F{{1b*0?6K4 z&zADGYP+gWXJ3ATx3k9HX@Kx(hJcpDZ%%x_0V=YqH1=M8oqbxj_R{2Ec57<)v&z@i zA|fK7l%AvYqKTdu@6bErej^XuXdc2_eajr&fpx! zaDyn?C%DDaz4(z)5Ka4r$fzhnG{nZn0v*FZY+M`!rUpV>d^|)YkxyzgM5RRm9oIlq zdK9ElA5YJ(5XK|keNZl?a&yP7s~vNNsXyXsjq zurQG24fPH6jAi*cF3S5%UM?W~O87$Okd*Th*rns(Nl0^aRA;@x)*hWHHV+qr-LAzcClIlw@a{nh&Z z0|J_N6!uU)BCUUbu9Pa3uQM;#C9%JDoRs%Rv2@-M$DrpC@bmfN=)5D5=E5Wqg3}N} z2#MJQ+E8>ZOQ_$s)MZ=L`_@O`uN(p00b_kIq`T6q0P^8xOG|x2%ZBE{$AZ2sczjyS zir>O8c0vR+A8glo0X5} zd;GJA{NqLf^7z zD2+M96Jp~NY5XA(q7q3G5>rwkiIJKLDFV_Ug~lOxEFvwt0Mcn3LK=%mFDRkq5=f`x z#%uv7j7`*!OZ;Vjru7Z`FOPuE7HIr4o>!R)O7`<{#BB-*_@IuOYP%1<$jjS74DIsYlM8QkgpGh(zU@b z0$&T9I(2H*^*`Ynpm_a{<`oF{Qp88|H9xxcN9WvposXY=&)4?&S@%CuL+bm;+HARc zpZW;=mqftU+Nz;N12YqPj-0+eok%)3@hf_r#6)>|fE_qXc{<5-;4Gcma&n?^PDh#9 zi6%tQMM25i$%$T@#t*TfS0fAVPBhPq@>LG>c42weiC(crR(m@e8!Jl-iw5TO=yzt< zA<6qp>H3%?h4WTFsDM@uhR81zDG@(Q^C(z zmHJhlHvx1%6VO;@eZN|Vja=_qAAvtP0-BLPX+gS>B}z+6b)NbhUee@kZ1wFe%uO_T zD{HGNJ3Tr}O%v@__F&(zftiMHZ6!Es^40w91b-tV8qMT_wESuKlyzbvyS2RmwZzm| zP*9$RA|@fjt9-qT>+$#Z2cE}qoZhWe*SQ?(>tQzP`4?{eIthto z2U=nY2BKtxoBFz!n|l59p2L@TQaLs9pBE>r@u4_X47O{>NmXTh&JsPZ59OFVc{0i& zw@J(L;^?`7^sbOXnk!m_1%*XeSXhijMTFvqSp4u2K79BXA3b`Ej~|!Nb2>|r{X0~k znaiPPVK$#!I^2HtW*ju{Cp>xiCOv;Mm-t0Bavu}7r1UAyn>PH04Gh`7{;RpT zjb1BQzL9pT$NL~Ad0^Tiz-6xkE|~E)&Ak=tW$x3mGF-oYJ@$W!{oDRld9lyfNfnWP z^!TD#faey{D-5Rr{_6v}75NLm-BSQ3)9Voz&Y6y-Ps;>uSy?%5*suY6lwtGUxwuF5 zLmEyepN+wQTPK_2!$(h$-VZ@>;`g7FVkxb!hFe~a^ezb8ym>P^&G^vJXKn27-H$!N zR#QI58SMa9(d!kXy8^BttW{%qC%{3z?F3#~`7Zf)(^?#LocVXzzm+70-~~KY`CGD{=ew?E*ij0klq9IS`Mf zMhRuO^d5+tsce21Ov1aaSQ%x3l@!;xA;B6h^Ai#h1b(kJEv&!)sLN5@>x0M6EEdXW z(mMzzj1ENH-U{)TKujA+uYXKRsFBa>Fm-6(Hj8OKG@b~+ooSnJ@XsZnlCUc)<+`9R`oXg7x z4<1AYm!kw~V+FnAhF<(9rVJ8{WI{v@V7-J4S{6XZz!`K%pFxN1b?9e!q9480975{= z_HV?;xa#BF2>u_hEr=T-an<}OBx{|B&;CN)EY*1-#+NQ#Vg-P*o>#xrhNXLctyV_!e=f(HcZ!g9 z`O|qdB&f@is@KTFIhEDQ@EyMy>G`8{Luz%t^gHJmNXr{fT&q?Fy@!h5Ma4H=NWY)w zZvP`$6`C^WxB(M?KFWOT(SNQ`hSdIR^nB;s++6BIs>_{exk4Ea=~iBP*&<;|@70cuOV^w*gj$embr4zX{&Mwo5e*CD;DnC)jKV?x@ z)fO6qucqUFfhw+82mKgjI=%{02I@>DQ{W?H}U V`k+yx)C>RD@)VT%^nW-4{||=zx^4gf literal 0 HcmV?d00001 diff --git a/thirdparty/WinSpy/Resources/WinSpy.ico b/thirdparty/WinSpy/Resources/WinSpy.ico new file mode 100644 index 0000000000000000000000000000000000000000..0df0b9a10c5d642ed7958f4bfc8af586f814e7d6 GIT binary patch literal 4406 zcmeH~e@NSB9>;UL+rjR-qrGi+-hSNKp0i~etyM?Y?ylNeukCcz+OpNEQ|hlfx1xho zRI)_LiK5gHaWrR8LV_V75)vXMA`vAd1jRFmA%ui42_b1v(llbV66AC5Z@x7+?T+hR z2lvN5JfH9L_&im`nc)Wk2 z?-=?J!pn!Vao=b3qy5_z*xcNV$Kxw2E8%cB^n&ccg9i^EK79Q6@slS{9zA;0T9Pe1 zoA$y>Yiah{+8R!-|1WR(e7@xuY5)Sut(?3x-R*YIJ~JUtfPdKVKo0-m0k)i^Wc-GsOT9SdMS5Jr)QAuwwtYfz#aFoS&bs z86K{@d9$~-7x3M30D2W;*fuNwEU|1q4FE8)w>vOqW zd$a%o%kgKM-j75g{(T0ZR4T2jy;XkW^Xu2HmEX8gS6e$UFwouIT~t)m#^--gRW&#` zh)Z#w)DIxA9N&KX1KhvC?;5Vjrl!Vr{%w;+z8dr<)>m+xH0lH$ZJ%7eR9#)&P+vc) zP=Neh-P2zH0?YB|zdjy~M)7<|8CJ5b^^WS^Kw!?a;&H@+?x=q`8gQ+Jys@B1Hzu#F zs8A@BSmcysPXj<;IsPL51Rg=FyG*aw5A}=v4x?{Iwd!4r1zgbp_-u&R&9@1h{zq$-Wot)Ilf1b zy|uN49?me8?#_W8uZC>SMxvC!BlLA%askRt|>yL5Y-z;gV6_(QIdI^r>?9g%|Uw`s!8$@K_>$v-V2 zcW~aQ9hD*`75~ge3X6?E8^fV6ojE>X_EP)Fp{guH=QWqI*`wx1tfLW!I^r0M%&Gm8 z5^YCG_x1Pg*JWB7GAHZaHP>d`zm;LCK4Sdhh@tARzVh&RMY`@LTexxAjktex+fF0Kw1hVGsZ z^yD$(KQUdWnXXd-ac=PMSyT0g<)y!~G`=@@3oHNv%kh6a{vWMCCq5T` zD4*f+e!BNm+3ys5x+K3<*zcDg%J^lciUnt0`$xyeZ#!UhwKZ>WSd_i8(YI&h-EdbR#W<>i2aSUF6GE}3F#}%&d$=*)D$5% zrm?XxDk(0ePN9&HR3#a#R)76%kv9+_q+8$XNSLVX>Q!oOX(8mn$v9TSYRwhD7X>0Q zLVlKXB#?xJm5fGXa$I~JP(?)r@td1TtJ4v(s$?9iVYM?gheeU-1|k1Rx>Bj2p3Zif zoY0e2DW}GUda9|eA>{OgTqYIAYFMqK;fN@@zD-EX2kA#7A52rDQ7jT*7;?IXd^*{#D$CoJ^5xe6n0t&SyfUW3oMZmOe6})7&eY|R>Nvt zEtw)T3GYlY8TAyI8>ir+nefVn`@mQx{YXFI#hi>`<5*`ktk%arDq^qQZMf6rqa}-m z{0=?lFhwDF#5qX@orVqBXa3e>B3IjS(aOjb3d@QpFm#EO{LAE0w^M9sf}(Ki2%p9p zvuUC0G}$|H$o@?>&9)yWtKbBgYcT)T6C$#FMhRmnZK$tMKvGEhI~PbN{ET!RSIP2q z7P{?1VfOWvhLK^jFz4w0+-7qq5%nHX__XfwQ!$8>!tVg%VD=9^tEM4R=_9Mrj} c5hFYWKaIGLF>XGz^LhX4eNFV=6IkuP06w8C82|tP literal 0 HcmV?d00001 diff --git a/thirdparty/WinSpy/WinSpy.ahk b/thirdparty/WinSpy/WinSpy.ahk new file mode 100644 index 0000000..1dc893d --- /dev/null +++ b/thirdparty/WinSpy/WinSpy.ahk @@ -0,0 +1,3278 @@ +; WinSpy - Window Information Tool + +#SingleInstance Off +#NoEnv +#MaxMem 640 +#NoTrayIcon +SetWorkingDir %A_ScriptDir% +DetectHiddenWindows On +CoordMode Mouse, Screen +SetControlDelay -1 +SetWinDelay -1 +SetBatchLines -1 +ListLines Off +#KeyHistory 0 + +Global AppName := "WinSpy" +, Version := "1.0.3" +, IniFile := AppName . ".ini" +, ResDir := A_ScriptDir . "\Resources" + +, hFindTool +, Bitmap1 := ResDir . "\FindTool1.bmp" +, Bitmap2 := ResDir . "\FindTool2.bmp" +, hCrossHair := DllCall("LoadImage", "Int", 0 + , "Str", ResDir . "\CrossHair.cur" + , "Int", 2 ; IMAGE_CURSOR + , "Int", 32, "Int", 32 + , "UInt", 0x10, "Ptr") ; LR_LOADFROMFILE +, hOldCursor +, Dragging := False + +, g_Borders := [] +, g_hWnd +, hSpyWnd +, hTab +, hStylesTab +, hWindowsTab +, g_Style +, g_ExStyle +, g_ExtraStyle +, g_WinMsgs := "" +, hCbxMsg +, Cursors := {} +, oStyles := {} +, Workaround := True +, FindDlgExist := False +, MenuViewerExist := False +, hTreeWnd := 0 +, TreeIcons := ResDir . "\TreeIcons.icl" +, ImageList +, g_TreeShowAll := False +, g_Minimized +, g_MouseCoordMode := "Screen" + +, g_DetectHidden +, g_Minimize +, g_AlwaysOnTop + +IniRead g_DetectHidden, %IniFile%, Settings, DetectHidden, 0 +IniRead g_Minimize, %IniFile%, Settings, CompactMode, 0 +IniRead g_AlwaysOnTop, %IniFile%, Settings, AlwaysOnTop, 0 + +IniRead g_ShowBorder, %IniFile%, Screenshot, ShowBorder, 1 +IniRead g_BorderColor, %IniFile%, Screenshot, BorderColor, 0xFF0000 +g_BorderColorTemp := g_BorderColor +IniRead g_BorderWidth, %IniFile%, Screenshot, BorderWidth, 4 + +Menu Tray, Icon, %ResDir%\WinSpy.ico + +; Main window +Gui Spy: New, LabelSpy hWndhSpyWnd +SetWindowIcon(hSpyWnd, ResDir . "\WinSpy.ico", 1) + +Gui Font, s9, Segoe UI + +Gui Add, Picture, hWndhFindTool gFindToolHandler x10 y12 w31 h28, %Bitmap1% +Gui Add, Text, x48 y10 w198, Drag the Finder Tool over a window`nto select it, then release the mouse +Gui Add, CheckBox, gSetDHW x247 y8 Checked%g_DetectHidden%, &Detect Hidden Windows +Gui Add, CheckBox, vg_Minimize gSetMinimize x247 y28 Checked%g_Minimize%, Compact &Mode + +Gui Add, Tab3, hWndhTab vTab gTabHandler x10 y50 w382 h373 AltSubmit -Wrap, General|Styles|Details|Messages|Extra|Windows|Process +; General +Gui Tab, 1 + Gui Add, Text, x28 y88 w62 h23 +0x200, Handle: + Gui Add, Edit, vEdtHandle gSetHandle x109 y90 w180 h21 + Gui Add, Button, hWndhBtnCommands gShowCommandsMenu x297 y88 w83 h23, Commands + Gui Add, Text, vTxtText x28 y119 w62 h21 +0x200, Text: + Gui Add, Edit, vEdtText x109 y120 w180 h21 + Gui Add, Button, vBtnSetText gSetText x297 y118 w83 h23, Set Text + + Gui Add, Text, x28 y146 w62 h21 +0x200, Class: + Gui Add, Edit, vEdtClass x109 y150 w270 h21 -E0x200 ReadOnly + + Gui Add, Text, x28 y176 w62 h21 +0x200, ClassNN: + Gui Add, Edit, vEdtClassNN x109 y180 w270 h21 -E0x200 ReadOnly + Gui Add, Text, x23 y209 w357 0x10 + + Gui Add, Text, x28 y220 w62 h21 +0x200, Style: + Gui Add, Edit, vEdtStyle x109 y224 w270 h21 -E0x200 ReadOnly + Gui Add, Text, x28 y250 w62 h21 +0x200, Extended: + Gui Add, Edit, vEdtExStyle x109 y254 w270 h21 -E0x200 ReadOnly + Gui Add, Text, x23 y283 w357 0x10 + + Gui Add, Text, x28 y294 w62 h21 +0x200, Position: + Gui Add, Edit, vEdtPosition x109 y298 w180 h21 -E0x200 ReadOnly + Gui Add, Button, gShowXYWHDlg x297 y294 w83 h23, Change... + Gui Add, Text, x28 y324 w62 h21 +0x200, Size: + Gui Add, Edit, vEdtSize x109 y328 w180 h21 -E0x200 ReadOnly + Gui Add, Text, x23 y357 w357 0x10 + + Gui Add, Text, x28 y368 w80 h21 +0x200, Cursor: + Gui Add, Edit, vEdtCursor x109 y372 w180 h21 -E0x200 ReadOnly + Gui Add, DropDownList, vMouseCoordMode gSetMouseCoordMode x297 y368 w83, Client|Window|Screen|| + +; Styles +Gui Tab, 2 + Gui Add, Custom, ClassSysTabControl32 hWndhStylesTab gStylesTabHandler x21 y85 w360 h230 + Tab_AddItem(hStylesTab, "Styles") + Tab_AddItem(hStylesTab, "Extended Styles") + + ; ListBox style +0x108: no integral height and simplified multiple selection + Gui Add, ListBox + , hWndhLbxStyles vLbxStyles gLbxStylesHandler x28 y116 w344 h190 +0x108 -E0x200 T133 + Gui Add, ListBox + , hWndhLbxExStyles vLbxExStyles gLbxStylesHandler x28 y116 w344 h190 +0x108 -E0x200 T133 Hidden + Gui Add, ListBox + , hWndhLbxExtraStyles vLbxExtraStyles gLbxStylesHandler x28 y116 w344 h190 +0x108 -E0x200 T133 Hidden + + Gui Add, GroupBox, vGrpDesc x21 y319 w268 h91, Description + Gui Add, Text, vTxtDesc gShowDescription x32 y338 w245 h64 +0x80, Left/Right-click an item to see its description. + + Gui Add, Edit, vEdtStyleSum x297 y326 w83 h23, 0x00000000 + Gui Add, Edit, vEdtExStyleSum x297 y326 w83 h23 Hidden, 0x00000000 + Gui Add, Edit, vEdtExtraStyleSum x297 y326 w83 h23 Hidden, 0x00000000 + + Gui Add, Button, gApplyStyle x297 y355 w83 h24, Apply + Gui Add, Button, gResetStyle x297 y386 w83 h24, Reset + +; Details +Gui Tab, 3 + Gui Add, ListView, hWndhClassInfo x21 y84 w360 h200 +LV0x14000, Property|Value + LV_ModifyCol(1, 138) + LV_ModifyCol(2, 201) + + Gui Add, Text, x21 y288 w360 h20, Window Properties: + Gui Add, ListView, hWndhPropInfo x21 y306 w360 h104 +LV0x14000, Property|Data + LV_ModifyCol(1, 238) + LV_ModifyCol(2, 100) + +; Messages +Gui Tab, 4 + Gui Add, Text, x30 y94 w63 h23 +0x200, Message: + Gui Add, ComboBox, hWndhCbxMsg vCbxMessages x105 y94 w182 + SendMessage 0x1701, 20, 0,, ahk_id %hCbxMsg% ; CB_SETMINVISIBLE + Gui Add, Link, gGoogleSearch x299 y97 w78 h23, Google Search + Gui Add, Text, x30 y127 w63 h23 +0x200, wParam: + Gui Add, Edit, vwParam x105 y127 w182 h23 + Gui Add, DropDownList, vwParamType x297 y126 w78, Number||String + Gui Add, Text, x30 y161 w63 h23 +0x200, lParam: + Gui Add, Edit, vlParam x105 y161 w182 h23 + Gui Add, DropDownList, vlParamType x297 y160 w78, Number||String + Gui Add, Button, gSendMsg x97 y206 w99 h24, SendMessage + Gui Add, Button, gPostMsg x203 y206 w99 h24, PostMessage + Gui Add, GroupBox, x84 y242 w232 h51 Center, Result + Gui Add, Edit, vResult x103 y264 w195 h21 Center -E0x200 ReadOnly + Gui Add, Picture, x58 y390 w16 h16 +Icon2, user32.dll + Gui Add, Text, x80 y390 w290 h23, Some messages may crash the target application. + +; Extra +Gui Tab, 5 + Gui Add, ListView, hWndhExtraInfo x21 y84 w360 h261 +LV0x14000, Property|Value + + Gui Add, Button, hWndhBtnMenu gShowMenuViewer x21 y355 w83 h23, Menu... + Gui Add, Button, gShowScrollBarInfo x21 y387 w83 h23, Scroll Bars... + +; Windows +Gui Tab, 6 + Gui Add, Custom, ClassSysTabControl32 hWndhWindowsTab gWindowsTabHandler x21 y85 w360 h255 + Tab_AddItem(hWindowsTab, "Child Windows") + Tab_AddItem(hWindowsTab, "Sibling Windows") + + Gui Add, ListView, hWndhChildList gChildListHandler x28 y116 w344 h214 -E0x200 +LV0x14000 + , Handle|Class Name|Window Text + LV_ModifyCol(1, 76) + LV_ModifyCol(2, 113) + LV_ModifyCol(3, 136) + Gui Add, ListView, hWndhSiblingList gSiblingListHandler x28 y116 w344 h214 -E0x200 +LV0x14000 Hidden + , Handle|Class Name|Window Text + LV_ModifyCol(1, 76) + LV_ModifyCol(2, 113) + LV_ModifyCol(3, 136) + + Gui Add, Text, x33 y352 w48 h23 +0x200, Parent: + Gui Add, Link, vParentLink gLinkToHandle x87 y357 w300 h20, 0x00000000 + Gui Add, Text, x33 y380 w48 h23 +0x200, Owner: + Gui Add, Link, vOwnerLink gLinkToHandle x87 y385 w300 h20, 0x00000000 + +; Process +Gui Tab, 7 + Gui Add, Picture, vProgIcon x21 y82 w32 h32 Icon3, shell32.dll + Gui Add, Text, vProgName x60 y82 w180 h20, N/A + Gui Add, Text, vProgVer x60 y96 w180 h20 +0x200 + Gui Add, ListView, hWndhProcInfo x21 y120 w360 h257 +LV0x14000, Property|Value + LV_ModifyCol(1, 100) + LV_ModifyCol(2, 256) + Gui Add, Button, gEndProcess x21 y386 w83 h23, End Process + Gui Add, Button, gOpenFolder x110 y386 w83 h23, Open Folder + +Gui Tab +Gui Add, Button, hWndhBtnOpts gShowSettingsDlg x10 y432 w24 h24 +Gui Add, Button, gShowFindDlg x39 y432 w84 h24, &Find... +Gui Add, Button, gShowTree x128 y432 w84 h24, &Tree... +Gui Add, Button, gCopyToClipboard x217 y432 w84 h24, &Copy +Gui Add, Button, gScreenshot x306 y432 w84 h24, &Screenshot + +SetButtonIcon(hBtnOpts, ResDir . "\Settings.ico") + +; Show main window +IniRead px, %IniFile%, Settings, x, Center +IniRead py, %IniFile%, Settings, y, Center +Gui Show, x%px% y%py% w400 h465 Hide, %AppName% ; Show main window +If (g_Minimize) { + WinMove ahk_id %hSpyWnd%,,,,, 78 + g_Minimized := True +} +Gui Show + +SetExplorerTheme(hClassInfo) +SetExplorerTheme(hPropInfo) +SetExplorerTheme(hExtraInfo) +SetExplorerTheme(hChildList) +SetExplorerTheme(hSiblingList) +SetExplorerTheme(hProcInfo) + +; Commands menu +Menu CommandsMenu, Add, Visible, MenuHandler +Menu CommandsMenu, Add, Enabled, MenuHandler +Menu CommandsMenu, Add, Always on Top, MenuHandler +Menu CommandsMenu, Add +Menu CommandsMenu, Add, Redraw Window, MenuHandler +Menu CommandsMenu, Add +Menu CommandsMenu, Add, Close Window, MenuHandler +Global hCommandsMenu := MenuGetHandle("CommandsMenu") + +RegRead Sep, HKEY_CURRENT_USER\Control Panel\International, sThousand +If (Sep == "") { + Sep := "." +} + +OnMessage(0x100, "OnWM_KEYDOWN") +OnMessage(0x112, "OnWM_SYSCOMMAND") +OnMessage(0x200, "OnWM_MOUSEMOVE") +OnMessage(0x202, "OnWM_LBUTTONUP") +OnMessage(0x204, "OnWM_RBUTTONDOWN") + +LoadCursors() + +hSysMenu := DllCall("GetSystemMenu", "Ptr", hSpyWnd, "Int", False, "Ptr") +DllCall("InsertMenu", "Ptr", hSysMenu, "UInt", 5, "UInt", 0x400, "UPtr", 0xC0DE, "Str", "About...") +DllCall("InsertMenu", "Ptr", hSysMenu, "UInt", 5, "UInt", 0xC00, "UPtr", 0, "Str", "") ; Separator + +Return ; End of the auto-execute section + +SpyEscape: +SpyClose: + p := GetWindowPlacement(hSpyWnd) + + If (!FileExist(IniFile)) { + FileAppend % "[Settings]`n`n[Screenshot]", %IniFile%, UTF-16 + } + + IniWrite % p.x, %IniFile%, Settings, x + IniWrite % p.y, %IniFile%, Settings, y + + IniWrite %g_DetectHidden%, %IniFile%, Settings, DetectHidden + IniWrite %g_Minimize%, %IniFile%, Settings, CompactMode + IniWrite %g_AlwaysOnTop%, %IniFile%, Settings, AlwaysOnTop + + IniWrite %g_ShowBorder%, %IniFile%, Screenshot, ShowBorder + IniWrite %g_BorderColor%, %IniFile%, Screenshot, BorderColor + IniWrite %g_BorderWidth%, %IniFile%, Screenshot, BorderWidth + + ExitApp + +IsChild(hWnd) { + WinGet Style, Style, ahk_id %hWnd% + Return Style & 0x40000000 ; WS_CHILD +} + +ShowWindowInfo(ClassNN := "") { + GuiControl -g, EdtHandle + + If (IsChild(g_hWnd)) { + LoadControlInfo(ClassNN) + } Else { + LoadWindowInfo() + } + + GuiControl +gSetHandle, EdtHandle + + GoSub LoadStyles + GoSub LoadClassInfo + GoSub LoadProperties + GoSub LoadExtraInfo + GoSub LoadWindowsTab + + GuiControlGet Tab,, Tab, %hTab% + TabHandler(Tab) + + GoSub UpdateTitleBar +} + +LoadWindowInfo() { + Gui Spy: Default + + ; Handle + GuiControl,, EdtHandle, % Format("0x{:X}", g_hWnd) + + ; Title + WinGetTitle Title, ahk_id %g_hWnd% + GuiControl,, EdtText, %Title% + GuiControl,, TxtText, Title: + GuiControl,, BtnSetText, Set Title + + ; Class + WinGetClass Class, ahk_id %g_hWnd% + GuiControl,, EdtClass, %Class% + + GuiControl,, EdtClassNN, N/A + + ; Style + WinGet g_Style, Style, ahk_id %g_hWnd% + If ((g_Style & 0x00FF0000) == 0xCF0000) { + StyleInfo := " (overlapped window)" + } Else If (g_Style & 0x80880000) { + StyleInfo := " (popup window)" + } Else { + StyleInfo := "" + } + GuiControl,, EdtStyle, % Format("0x{:08X}", g_Style) . StyleInfo + + ; Extended style + WinGet g_ExStyle, ExStyle, ahk_id %g_hWnd% + GuiControl,, EdtExStyle, % Format("0x{:08X}", g_ExStyle) + + ; Position/size + SetFormat Integer, D + WinGetPos X, Y, W, H, ahk_id %g_hWnd% + wi := GetWindowInfo(g_hWnd) + GuiControl,, EdtPosition, % X . ", " . Y . " (" . wi.ClientX . ", " . wi.ClientY . ")" + GuiControl,, EdtSize, % W . " x " . H . " (" . wi.ClientW . " x " . wi.ClientH . ")" +} + +LoadControlInfo(ClassNN) { + If (ClassNN == "") { + ClassNN := GetClassNNEx(g_hWnd) + } + + Gui Spy: Default + SetFormat Integer, Hex + + ; Handle + GuiControl,, EdtHandle, % Format("0x{:X}", g_hWnd) + + ; Class + WinGetClass, Class, ahk_id %g_hWnd% + GuiControl,, EdtClass, %Class% + + ; Control text + ControlGetText Text,, ahk_id %g_hWnd% + GuiControl,, EdtText, %Text% + GuiControl,, TxtText, Text: + GuiControl,, BtnSetText, Set Text + + ; ClassNN + GuiControl,, EdtClassNN, %ClassNN% + + ; Style + ControlGet g_Style, Style,,, ahk_id %g_hWnd% + GuiControl,, EdtStyle, %g_Style% + + ; Extended style + ControlGet g_ExStyle, ExStyle,,, ahk_id %g_hWnd% + GuiControl,, EdtExStyle, %g_ExStyle% + + ; Position/Size + SetFormat Integer, D + GetWindowPos(g_hWnd, X, Y, W, H) + wi := GetWindowInfo(g_hWnd) + Pos := X . ", " . Y ; Relative to parent + + hParent := GetParent(g_hWnd) + hAncestor := GetAncestor(g_hWnd) + If (hParent != hAncestor) { + VarSetCapacity(RECT, 16, 0) + DllCall("GetWindowRect", "Ptr", g_hWnd, "Ptr", &RECT) + DllCall("MapWindowPoints", "Ptr", 0, "Ptr", GetAncestor(g_hWnd), "Ptr", &RECT, "UInt", 1) + AX := NumGet(RECT, 0, "Int") + AY := NumGet(RECT, 4, "Int") + Pos .= " (" . AX ", " . AY . ")" ; Relative to ancestor + } + + GuiControl,, EdtPosition, %Pos% + + If (W != wi.ClientW || H != wi.ClientH) { + GuiControl,, EdtSize, % W . " x " . H . " (" . wi.ClientW . " x " . wi.ClientH . ")" + } Else { + GuiControl,, EdtSize, %W% x %H% + } + + g_ExtraStyle := GetExtraStyle(g_hWnd) +} + +GetStatusBarText(hWnd) { + SB_Text := "" + hParentWnd := GetParent(hWnd) + + SendMessage 0x406, 0, 0,, ahk_id %hWnd% ; SB_GETPARTS + Count := ErrorLevel + If (Count != "FAIL") { + Loop %Count% { + StatusBarGetText PartText, %A_Index%, ahk_id %hParentWnd% + SB_Text .= PartText . "|" + } + } + + Return SubStr(SB_Text, 1, -1) +} + +TabHandler: + Gui Spy: Submit, NoHide + TabHandler(Tab) +Return + +TabHandler(Tab) { + If (Tab == 7) { ; Process + GoSub LoadProcessProperties + } Else If (Tab == 4) { ; Messages + GoSub LoadMessages + WinSet Redraw,, ahk_id %hCbxMsg% + } +} + +; Flag: GA_PARENT = 1, GA_ROOT = 2, GA_ROOTOWNER = 3 +GetAncestor(hWnd, Flag := 2) { + Return DllCall("GetAncestor", "Ptr", hWnd, "UInt", Flag, "Ptr") +} + +GetClassNNEx(hWnd) { + hAncestor := GetAncestor(hWnd) + If (!hAncestor) { + Return + } + + WinGetClass BaseClass, ahk_id %hWnd% + NN := 0 + + WinGet ControlList, ControlListHwnd, % "ahk_id " . hAncestor + Loop Parse, ControlList, `n + { + WinGetClass Class, ahk_id %A_LoopField% + If (Class == BaseClass) { + NN++ + If (A_LoopField == hWnd) { + Return Class . NN + } + } + } +} + +SetHandle: + Gui Spy: Submit, NoHide + + If (!Dragging && WinExist("ahk_id " . EdtHandle)) { + g_hWnd := EdtHandle + ShowWindowInfo() + } +Return + +MenuHandler: + If (A_ThisMenuItem == "Visible") { + ShowWindow(g_hWnd, !IsWindowVisible(g_hWnd)) + } Else If (A_ThisMenuItem == "Enabled") { + DllCall("EnableWindow", "Ptr", g_hWnd, "UInt", !IsWindowEnabled(g_hWnd)) + } Else If (A_ThisMenuItem == "Always on Top") { + WinSet AlwaysOnTop, Toggle, ahk_id %g_hWnd% + } Else If (A_ThisMenuItem == "Close Window") { + WinClose ahk_id %g_hWnd% + } Else If (A_ThisMenuItem == "Redraw Window") { + WinSet Redraw,, ahk_id %g_hWnd% + } +Return + +UpdateCommandsMenu() { + Visible := IsWindowVisible(g_hWnd) + Enabled := IsWindowEnabled(g_hWnd) + WinGet ExStyle, ExStyle, ahk_id %g_hWnd% + + Menu CommandsMenu, % (Visible) ? "Check" : "Uncheck", Visible + Menu CommandsMenu, % (Enabled) ? "Check" : "Uncheck", Enabled + + Menu CommandsMenu, % (ExStyle & 0x8) ? "Check" : "Uncheck", Always on Top ; WS_EX_TOPMOST + Menu CommandsMenu, % (IsChild(g_hWnd)) ? "Disable" : "Enable", Always on Top +} + +IsWindowEnabled(hWnd) { + Return DllCall("IsWindowEnabled", "Ptr", hWnd) +} + +ShowCommandsMenu: + UpdateCommandsMenu() + + Flags:= 0x8 ; TPM_TOPALIGN | TPM_RIGHTALIGN + WingetPos wx, wy, ww, wh, ahk_id %hSpyWnd% + ControlGetPos cx, cy, cw, ch,, ahk_id %hBtnCommands% + x := wx + cx + cw + y := wy + cy + ch + DllCall("TrackPopupMenu", "Ptr", hCommandsMenu, "UInt", 0x8, "Int", x, "Int", y, "Int", 0, "Ptr", hSpyWnd, "Ptr", 0) +Return + +SetText: + Gui Spy: Submit, NoHide + If (IsChild(g_hWnd)) { + ControlSetText,, %EdtText%, ahk_id %g_hWnd% + } Else { + WinSetTitle ahk_id %g_hWnd%,, %EdtText% + } +Return + +ShowBorder(hWnd, Duration := 500, Color := "0x3FBBE3", r := 3) { + Local x, y, w, h, Index + + WinGetPos x, y, w, h, ahk_id %hWnd% + If (!w) { + Return + } + + g_Borders := [] + Loop 4 { + Index := A_Index + 90 + Gui %Index%: +hWndhBorder -Caption +ToolWindow +AlwaysOnTop + Gui %Index%: Color, %Color% + g_Borders.Push(hBorder) + } + + Gui 91: Show, % "NA x" (x - r) " y" (y - r) " w" (w + r + r) " h" r ; Top + Gui 92: Show, % "NA x" (x - r) " y" (y + h) " w" (w + r + r) " h" r ; Bottom + Gui 93: Show, % "NA x" (x - r) " y" y " w" r " h" h ; Left + Gui 94: Show, % "NA x" (x + w) " y" y " w" r " h" h ; Right + + If (Duration != -1) { + Sleep %Duration% + Loop 4 { + Index := A_Index + 90 + Gui %Index%: Destroy + } + } +} + +GetClassLong(hWnd, Param) { + Static GetClassLong := A_PtrSize == 8 ? "GetClassLongPtr" : "GetClassLong" + Return DllCall(GetClassLong, "Ptr", hWnd, "Int", Param) +} + +GetWindowLong(hWnd, Param) { + ;GetWindowLong := A_PtrSize == 8 ? "GetWindowLongPtr" : "GetWindowLong" + Return DllCall("GetWindowLong", "Ptr", hWnd, "Int", Param) +} + +; Details +LoadClassInfo: + Gui ListView, %hClassInfo% + LV_Delete() + + SetFormat Integer, H + WinGetClass ClassName, ahk_id %g_hWnd% + ClassStyle := GetClassLong(g_hWnd, -26) + + LV_Add("", "Class name", ClassName) + LV_Add("", "Control ID", GetWindowLong(g_hWnd, -12)) + LV_Add("", "Font", GetFont()) + LV_Add("", "Window procedure", GetClassLong(g_hWnd, -24)) + LV_Add("", "Instance handle", GetClassLong(g_hWnd, -16)) + LV_Add("", "Class style", ClassStyle . GetClassStyles(ClassStyle)) + LV_Add("", "Icon handle", GetClassLong(g_hWnd, -14)) + LV_Add("", "Small icon handle", GetClassLong(g_hWnd, -34)) + LV_Add("", "Cursor handle", GetCursor(GetClassLong(g_hWnd, -12))) + LV_Add("", "Background Brush", GetSysColorName(GetClassLong(g_hWnd, -10) - 1)) + LV_Add("", "Menu name", GetClassLong(g_hWnd, -8)) + LV_Add("", "Window extra bytes", GetClassLong(g_hWnd, -18)) + LV_Add("", "Class extra bytes", GetClassLong(g_hWnd, -20)) + LV_Add("", "Class atom", GetClassLong(g_hWnd, -32)) + LV_Add("", "User data", GetWindowLong(g_hWnd, -21)) + SetFormat Integer, D + LV_Add("", "Unicode", DllCall("IsWindowUnicode", "Ptr", g_hWnd) ? "Yes" : "No") + LV_Add("", "Tab order index", GetTabOrderIndex(g_hWnd)) + LV_Add("", "Help context ID", DllCall("GetWindowContextHelpId", "Ptr", g_hWnd)) + LV_Add("", "Touch-capable", DllCall("IsTouchWindow", "Ptr", g_hWnd, "Ptr", 0)) +Return + +GetFont() { + FontName := FontSize := FontStyle := "" + + Wingetclass Class, ahk_id %g_hWnd% + If (Class == "Scintilla") { + FontName := Scintilla_GetFont(g_hWnd) + FontSize := SendMsg(2485, 32) ; SCI_STYLEGETSIZE, STYLE_DEFAULT + } Else { + Control_GetFont(g_hWnd, FontName, FontSize, FontStyle) + If (FontName == "" || FontSize > 1000) { + Return "System default" + } + } + + FontInfo := FontName . ", " . Format("{:d}", FontSize) + If (FontStyle != "") { + FontInfo .= ", " . FontStyle + } + + Return FontInfo +} + +; www.autohotkey.com/forum/viewtopic.php?p=465438#465438 +Control_GetFont(hWnd, ByRef Name, ByRef Size, ByRef Style, IsGDIFontSize := 0) { + SendMessage 0x31, 0, 0, , ahk_id %hWnd% ; WM_GETFONT + If (ErrorLevel == "FAIL") { + Return + } + + hFont := Errorlevel + VarSetCapacity(LOGFONT, LOGFONTSize := 60 * (A_IsUnicode ? 2 : 1 )) + DllCall("GetObject", "Ptr", hFont, "Int", LOGFONTSize, "Ptr", &LOGFONT) + + Name := DllCall("MulDiv", "Int", &LOGFONT + 28, "Int", 1, "Int", 1, "Str") + + Style := Trim((Weight := NumGet(LOGFONT, 16, "Int")) == 700 ? "Bold" : (Weight == 400) ? "" : " w" . Weight + . (NumGet(LOGFONT, 20, "UChar") ? " Italic" : "") + . (NumGet(LOGFONT, 21, "UChar") ? " Underline" : "") + . (NumGet(LOGFONT, 22, "UChar") ? " Strikeout" : "")) + + Size := IsGDIFontSize ? -NumGet(LOGFONT, 0, "Int") : Round((-NumGet(LOGFONT, 0, "Int") * 72) / A_ScreenDPI) +} + +Scintilla_GetFont(hWnd) { + WinGet PID, PID, ahk_id %hWnd% + If !(hProc := DllCall("OpenProcess", "UInt", 0x438, "Int", False, "UInt", PID, "Ptr")) { + Return + } + + ; LF_FACESIZE := 32 + Address := DllCall("VirtualAllocEx", "Ptr", hProc, "Ptr", 0, "UPtr", 32, "UInt", 0x1000, "UInt", 4, "Ptr") + + SendMessage 2486, 32, Address,, ahk_id %hWnd% ; SCI_STYLEGETFONT, STYLE_DEFAULT + If (ErrorLevel != "FAIL") { + VarSetCapacity(FontName, 32, 0) + DllCall("ReadProcessMemory", "Ptr", hProc, "Ptr", Address, "Ptr", &FontName, "UPtr", 32, "Ptr", 0) + FontName := StrGet(&FontName, "UTF-8") + } + + DllCall("VirtualFreeEx", "Ptr", hProc, "Ptr", Address, "UPtr", 0, "UInt", 0x8000) ; MEM_RELEASE + DllCall("CloseHandle", "Ptr", hProc) + + Return FontName +} + +Scintilla_GetLexerLanguage(hWnd) { + WinGet PID, PID, ahk_id %hWnd% + If !(hProc := DllCall("OpenProcess", "UInt", 0x438, "Int", False, "UInt", PID, "Ptr")) { + Return + } + + Sendmessage 4012, 0, 0,, ahk_id %hWnd% ; SCI_GETLEXERLANGUAGE + BufferSize := ErrorLevel + Address := DllCall("VirtualAllocEx", "Ptr", hProc, "Ptr", 0, "UPtr", BufferSize, "UInt", 0x1000, "UInt", 4, "Ptr") + + Sendmessage 4012, 0, Address,, ahk_id %hWnd% ; SCI_GETLEXERLANGUAGE + If (ErrorLevel != "FAIL") { + VarSetCapacity(LexerName, BufferSize, 0) + DllCall("ReadProcessMemory", "Ptr", hProc, "Ptr", Address, "Ptr", &LexerName, "UPtr", 32, "Ptr", 0) + LexerName := StrGet(&LexerName, "UTF-8") + } + + DllCall("VirtualFreeEx", "Ptr", hProc, "Ptr", Address, "UPtr", 0, "UInt", 0x8000) ; MEM_RELEASE + DllCall("CloseHandle", "Ptr", hProc) + + Return LexerName +} + +GetClassStyles(Style) { + Static CS := {0x1: "CS_VREDRAW" + , 0x2: "CS_HREDRAW" + , 0x8: "CS_DBLCLKS" + , 0x20: "CS_OWNDC" + , 0x40: "CS_CLASSDC" + , 0x80: "CS_PARENTDC" + , 0x200: "CS_NOCLOSE" + , 0x800: "CS_SAVEBITS" + , 0x1000: "CS_BYTEALIGNCLIENT" + , 0x2000: "CS_BYTEALIGNWINDOW" + , 0x4000: "CS_GLOBALCLASS" + , 0x10000: "CS_IME" + , 0x20000: "CS_DROPSHADOW"} + + Styles := " (" + For k, v in CS { + If (Style & k) { + Styles .= v ", " + } + } + + Return RTrim(Styles, ", ") . ")" +} + +LoadCursors() { + Static Constants := {"IDC_ARROW": 32512 + , "IDC_IBEAM": 32513 + , "IDC_WAIT": 32514 + , "IDC_CROSS": 32515 + , "IDC_UPARROW": 32516 + , "IDC_SIZENWSE": 32642 + , "IDC_SIZENESW": 32643 + , "IDC_SIZEWE": 32644 + , "IDC_SIZENS": 32645 + , "IDC_SIZEALL": 32646 + , "IDC_NO": 32648 + , "IDC_HAND": 32649 + , "IDC_APPSTARTING": 32650 + , "IDC_HELP": 32651} + + For Key, Value in Constants { + hCursor := DllCall("LoadCursor", "Ptr", 0, "UInt", Value, "Ptr") + Cursors[hCursor] := Key + } +} + +GetCursor(CursorHandle) { + Cursor := Cursors[CursorHandle] + Return (Cursor != "") ? Cursor : CursorHandle +} + +GetTabOrderIndex(hWnd) { + hParent := GetAncestor(hWnd) + + WinGet ControlList, ControlListHwnd, ahk_id %hParent% + Index := 1 + Loop Parse, ControlList, `n + { + If (!IsWindowVisible(A_LoopField)) { + Continue + } + + WinGet Style, Style, ahk_id %A_LoopField% + If !(Style & 0x10000) { ; WS_TABSTOP + Continue + } + + If (A_LoopField == hWnd) { + Return Index + } + + Index++ + } + + Return 0 +} + +Tab_AddItem(hTab, Text) { + VarSetCapacity(TCITEM, 16 + A_PtrSize * 3, 0) + NumPut(0x1, TCITEM, 0, "UInt") ; TCIF_TEXT + NumPut(&Text, TCITEM, 8 + A_PtrSize, "Ptr") + SendMessage 0x1304, 0, 0,, ahk_id %hTab% ; TCM_GETITEMCOUNT + SendMessage 0x133E, %ErrorLevel%, &TCITEM, , ahk_id %hTab% ; TCM_INSERTITEMW +} + +StylesTabHandler: + If (A_GuiEvent == "N") { + Code := NumGet(A_EventInfo + 0, A_PtrSize * 2, "Int") + If (Code == -551) { ; TCN_SELCHANGE + SendMessage 0x130B, 0, 0,, ahk_id %hStylesTab% ; TCM_GETCURSEL + nTab := Errorlevel + 1 + If (nTab == 1) { + GuiControl Hide, ListBox3 + GuiControl Hide, ListBox2 + GuiControl Show, ListBox1 + + GuiControl Hide, EdtExtraStyleSum + GuiControl Hide, EdtExStyleSum + GuiControl Show, EdtStyleSum + } Else If (nTab == 2) { + GuiControl Hide, ListBox1 + GuiControl Hide, ListBox3 + GuiControl Show, ListBox2 + + GuiControl Hide, EdtExtraStyleSum + GuiControl Hide, EdtStyleSum + GuiControl Show, EdtExStyleSum + } Else If (nTab == 3) { + GuiControl Hide, ListBox1 + GuiControl Hide, ListBox2 + GuiControl Show, ListBox3 + + GuiControl Hide, EdtStyleSum + GuiControl Hide, EdtExStyleSum + GuiControl Show, EdtExtraStyleSum + } + } + } +Return + +; Styles +LoadStyles: + Gui Spy: Default + + GuiControl,, EdtStyleSum, %g_Style% + GuiControl,, EdtExStyleSum, %g_ExStyle% + GuiControl,, EdtExtraStyleSum, %g_ExtraStyle% + + WinGetClass Class, ahk_id %g_hWnd% + If (Class == "") { + Return + } + + ; Load control styles + LoadStyles(Class, "ListBox1") + + If (Class == "ToolbarWindow32" || Class == "ReBarWindow32") { + LoadStyles("CommonControls", "ListBox1", True) + } + + ; Load window styles + LoadStyles("Window", "ListBox1", True) + LoadStyles("WindowEx", "ListBox2") + + ; Delete the third tab + SendMessage 0x1308, 2, 0,, ahk_id %hStylesTab% ; TCM_DELETEITEM + If (ErrorLevel == True) { + GuiControl Hide, ListBox3 + GuiControl Show, ListBox1 + SendMessage 0x1330, 0, 0,, ahk_id %hStylesTab% ; TCM_SETCURFOCUS + Sleep 0 + SendMessage 0x130C, 0, 0,, ahk_id %hStylesTab% ; TCM_SETCURSEL + } + + If (Class == "ComboBox" && g_Style & 0x10) { ; CBS_OWNERDRAWFIXED + Class := "ComboBoxEx" + } + + ; Add third tab + If (Class == "SysListView32" + || Class == "SysTreeView32" + || Class == "SysTabControl32" + || Class == "ToolbarWindow32" + || Class == "ComboBoxEx") { + Tab_AddItem(hStylesTab, RegExReplace(Class, "Sys|32|Control|Window") . " Extended Styles") + LoadStyles(Class . "Ex", "ListBox3") + } + + WStyle := g_Style + Type := 0 + If (Class == "Button") { + Type := WStyle & 0xF ; BS_TYPEMASK + WStyle &= ~Type + } Else If (Class == "SysListView32") { + Type := WStyle & 0x3 ; LVS_TYPEMASK + WStyle &= ~Type + } Else If (Class == "Static") { + Type := WStyle & 0x1F ; SS_TYPEMASK + WStyle &= ~Type + } + + ControlGet Items, List,,, ahk_id %hLbxStyles% + Loop Parse, Items, `n + { + LStyle := StrSplit(A_LoopField, "`t")[2] + If (WStyle & LStyle || Type == LStyle) { + WStyle &= ~LStyle + GuiControl Choose, %hLbxStyles%, %A_Index% + } + } + + If (WStyle) { + Leftover := Format("0x{:08X}", WStyle) + GuiControl,, %hLbxStyles%, % Leftover . "`t" . Leftover . "||" + } + + SendMessage 0x115, 6, 0,, ahk_id %hLbxStyles% ; WM_VSCROLL, scroll to top + WinSet Redraw,, ahk_id %hLbxStyles% + + ; Extended styles + WExStyle := g_ExStyle + ControlGet Items, List,,, ahk_id %hLbxExStyles% + Loop Parse, Items, `n + { + LExStyle := StrSplit(A_LoopField, "`t")[2] + If (WExStyle & LExStyle || LExStyle == 0) { + WExStyle &= ~LExStyle + GuiControl Choose, %hLbxExStyles%, %A_Index% + } + } + + If (WExStyle) { + Leftover := Format("0x{:08X}", WExStyle) + GuiControl,, %hLbxExStyles%, % Leftover . "`t" . Leftover . "||" + } + + SendMessage 0x115, 6, 0,, ahk_id %hLbxExStyles% ; WM_VSCROLL, scroll to top + WinSet Redraw,, ahk_id %hLbxExStyles% + + ; Extra control styles (LV, TV, Toolbar, Tab) + ExtraStyle := g_ExtraStyle + ControlGet Items, List,,, ahk_id %hLbxExtraStyles% + Loop Parse, Items, `n + { + LExtraStyle := StrSplit(A_LoopField, "`t")[2] + If (ExtraStyle & LExtraStyle || LExtraStyle == 0) { + ExtraStyle &= ~LExtraStyle + GuiControl Choose, %hLbxExtraStyles%, %A_Index% + } + } +Return + +LoadStyles(IniSection, ListBox, Append := False) { + Static IniFile := A_ScriptDir . "\Constants\Styles.ini" + IniRead Section, %IniFile%, %IniSection% + + Child := (IniSection == "Window" && IsChild(g_hWnd)) ? True : False + + Values := "" + Loop Parse, Section, `n + { + Fields := StrSplit(A_LoopField, "|") + Const := Fields[1] + + If (Child && (Const == "WS_MAXIMIZEBOX" || Const == "WS_MINIMIZEBOX" || Const == "WS_OVERLAPPED")) { + Continue + } + + If (!Child && (Const == "WS_TABSTOP" || Const == "WS_GROUP")) { + Continue + } + + Values .= Const . "`t" . Fields[2] . "|" + oStyles[Const] := {"Value": Fields[2], "Desc": Fields[3]} + } + + Gui Spy: Default + GuiControl,, %ListBox%, % (Append) ? Values : "|" . Values +} + +LbxStylesHandler: + Gui Spy: Default + GuiControlGet hLbx, hWnd, %A_GuiControl% + GuiControl -AltSubmit, %hLbx% + + GuiControlGet Items,, %hLbx% + + Sum := 0 + Loop Parse, Items, | + { + StringSplit Field, A_LoopField, `t + Sum += Field2 + } + + GuiControl,, % StrReplace(A_GuiControl, "Lbx", "Edt") . "um", % Format("0x{:08X}", Sum) + + ; Style description + GuiControl +AltSubmit, %hLbx% + SendMessage 0x188, 0, 0,, ahk_id %hLbx% ; LB_GETCURSEL + If (ErrorLevel != "FAIL") { + ; Credits to just_me + Index := ErrorLevel + SendMessage 0x18A, %Index%, 0,, ahk_id %hLbx% ; LB_GETTEXTLEN + Len := ErrorLevel + VarSetCapacity(LB_Text, Len << !!A_IsUnicode, 0) + SendMessage 0x189, %Index%, % &LB_Text,, ahk_id %hLbx% ; LB_GETTEXT + Const := StrSplit(StrGet(&LB_Text, Len), "`t")[1] + Desc := StrReplace(oStyles[Const].Desc, "\n", "`n") + GuiControl,, GrpDesc, %Const% + GuiControl,, TxtDesc, %Desc% + } +Return + +ApplyStyle: + SendMessage 0x130B, 0, 0,, ahk_id %hStylesTab% ; TCM_GETCURSEL + nTab := ErrorLevel + 1 + + If (nTab == 1) { + GuiControlGet Style,, EdtStyleSum + WinSet Style, %Style%, ahk_id %g_hWnd% + } Else If (nTab == 2) { + GuiControlGet ExStyle,, EdtExStyleSum + WinSet ExStyle, %ExStyle%, ahk_id %g_hWnd% + } Else If (nTab == 3) { + GuiControlGet ExtraStyle,, EdtExtraStyleSum + WinGetClass Class, ahk_id %g_hWnd% + + If (Class == "SysListView32") { + SendMessage 0x1036, 0, %ExtraStyle%,, ahk_id %g_hWnd% ; LVM_SETEXTENDEDLISTVIEWSTYLE + } Else If (Class == "SysTreeView32") { + SendMessage 0x112C, 0, %ExtraStyle%,, ahk_id %g_hWnd% ; TVM_SETEXTENDEDSTYLE + } Else If (Class == "SysTabControl32") { + SendMessage 0x1334, 0, %ExtraStyle%,, ahk_id %g_hWnd% ; TCM_SETEXTENDEDSTYLE + } Else If (Class == "ToolbarWindow32") { + SendMessage 0x454, 0, %ExtraStyle%,, ahk_id %g_hWnd% ; TB_SETEXTENDEDSTYLE + } Else If (Class == "ComboBox" && (g_Style & 0x10)) { + SendMessage 0x40E, 0, %ExtraStyle%,, ahk_id %g_hWnd% ; CBEM_SETEXTENDEDSTYLE + } + } + + ; 0x17: SWP_NOSIZE | SWP_NOMOVE | SWP_NOZORDER | SWP_NOACTIVATE + DllCall("SetWindowPos", "Ptr", g_hWnd, "UInt", 0, "Int", 0, "Int", 0, "Int", 0, "Int", 0, "UInt", 0x17) + WinSet Redraw,, ahk_id %g_hWnd% +Return + +ResetStyle: + nTab := DllCall("SendMessage", "Ptr", hStylesTab, "UInt", 0x130B, "UInt", 0, "UInt", 0) + 1 + If (nTab == 1) { + GuiControl, Spy:, EdtStyleSum, %g_Style% + } Else If (nTab == 2) { + GuiControl, Spy:, EdtExStyleSum, %g_ExStyle% + } Else If (nTab == 3) { + GuiControl, Spy:, EdtExtraStyleSum, %g_ExtraStyle% + } + + GoSub LoadStyles +Return + +GetExtraStyle(hWnd) { + WinGetClass Class, ahk_id %hWnd% + + If (Class == "SysListView32") { + Message := 0x1037 ; LVM_GETEXTENDEDLISTVIEWSTYLE + } Else If (Class == "SysTreeView32") { + Message := 0x112D ; TVM_GETEXTENDEDSTYLE + } Else If (Class == "SysTabControl32") { + Message := 0x1335 ; TCM_GETEXTENDEDSTYLE + } Else If (Class == "ToolbarWindow32") { + Message := 0x455 ; TB_GETEXTENDEDSTYLE + } Else If (Class == "ComboBox" && g_Style & 0x10) { + Message := 0x409 ; CBEM_GETEXTENDEDSTYLE + } + + SendMessage %Message%, 0, 0,, ahk_id %hWnd% + Return Format("0x{:08X}", ErrorLevel) +} + +ShowDescription: + GuiControlGet Const,, GrpDesc + GuiControlGet Desc,, TxtDesc + + Gui Desc: New, LabelDesc -SysMenu OwnerSpy + Gui Color, White + Gui Margin, 10, 0 + Gui Add, CheckBox, x0 y0 w0 h0 + + Gui Add, Picture, x12 y12 w32 h32 Icon5, user32.dll + Gui Font, s12 c0x003399, Segoe UI + Gui Add, Text, x58 y15 w473 h23 +0x200, %Const% + Gui Font + + Gui Font, s10, Segoe UI + Gui Add, Edit, vEdtDesc x55 y55 w444 Multi -VScroll -E0x200, %Desc% + Gui Font + + GuicontrolGet Pos, Pos, EdtDesc + py := PosY + PosH + 20 + Gui Add, Text, hWndhFooter x-1 y%py% w533 h48 -Background + + Gui Font, s9, Segoe UI + Gui Add, Button, gDescClose x432 yp+12 w88 h25 Default, &Close + + Gui Show, w531, Style Description +Return + +DescEscape: +DescClose: + Gui Desc: Destroy +Return + +; Messages +LoadMessages: + WinGetClass Class, ahk_id %g_hWnd% + + Constants := GetMessages(Class) + + Gui Spy: Default + GuiControlGet CurrentItem,, CbxMessages, Text + GuiControl,, CbxMessages, |%Constants% + GuiControl Text, CbxMessages, %CurrentItem% + + ; Common Control Messages + If (Class == "ToolbarWindow32" || Class == "ReBarWindow32") { + GuiControl,, CbxMessages, % GetMessages("CommonControls") + } + + If (g_WinMsgs == "") { + g_WinMsgs := GetMessages("Window") + } + + GuiControl,, CbxMessages, %g_WinMsgs% +Return + +GetMessages(Class) { + Static IniFile := A_ScriptDir . "\Constants\Messages.ini" + + If (Class == "") { + Return + } + + IniRead Section, %IniFile%, %Class% + + Constants := "" + Loop Parse, Section, `n + { + Constants .= StrSplit(A_LoopField, "=")[1] . "|" + } + + Sort Constants, D| + Return Constants +} + +SendMsg: +PostMsg: + Gui Spy: Submit, NoHide + + Function := (A_ThisLabel == "SendMsg") ? "SendMessage" : "PostMessage" + + If CbxMessages is Not Number + { + If (SubStr(CbxMessages, 1, 3) == "WM_") { + ClassName := "Window" + } Else { + ClassName := GetClassName(g_hWnd) + } + + IniRead Message, %A_ScriptDir%\Constants\Messages.ini, %ClassName%, %CbxMessages% + If (Message == "ERROR") { + Gui Spy: +OwnDialogs + MsgBox 0x10, %AppName%, %CbxMessages%: invalid message. + Return + } + } Else { + Message := CbxMessages + } + + DataTypes := {"Number": "UPtr", "String": "WStr"} + wType := DataTypes[wParamType] + lType := DataTypes[lParamType] + + Result := DllCall(Function, "Ptr", g_hWnd, "UInt", Message, wType, wParam, lType, lParam) + GuiControl,, Result, %Result% +Return + +GoogleSearch: + GuiControlGet Message,, CbxMessages + + If (Message == "") { + Return + } + + If (SubStr(Message, 1, 3) == "SCI") { + URL := "http://www.scintilla.org/ScintillaDoc.html#" + } Else { + URL := "https://www.google.com/#q=" + } + + Try { + Run %URL%%Message% + } +Return + +CopyToClipboard: + Gui Spy: Default + + CRLF := "`r`n" + Output := "" + + If (Tab == 1) { ; General + Gui Spy: Submit, NoHide + Output .= "[General]" . CRLF + Output .= "Handle:`t" . EdtHandle . CRLF + Output .= "Text:`t" . EdtText . CRLF + Output .= "Class:`t" . EdtClass . CRLF + Output .= "ClassNN:`t" . EdtClassNN . CRLF + Output .= "Style:`t" . EdtStyle . CRLF + Output .= "Extended:`t" . EdtExStyle . CRLF + Output .= "Position:`t" . EdtPosition . CRLF + Output .= "Size:`t" . EdtSize . CRLF + Output .= "Cursor:`t" . EdtCursor . CRLF + } + Else If (Tab == 2) { ; Styles + If (g_Style) { + GuiControlGet Styles,, %hLbxStyles% + Output .= "[Styles]" . CRLF . StrReplace(Styles, "|", CRLF) . CRLF . CRLF + } + + If (g_ExStyle) { + GuiControlGet ExStyles,, %hLbxExStyles% + Output .= "[ExStyles]" . CRLF . StrReplace(ExStyles, "|", CRLF) . CRLF . CRLF + } + + If (g_ExtraStyle) { + GuiControlGet ExtraStyles,, %hLbxExtraStyles% + Output .= "[ExtraStyles]" . CRLF . StrReplace(ExtraStyles, "|", CRLF) + } + } + Else If (Tab == 3) { ; Details + ControlGet, ClassInfo, List,,, ahk_id %hClassInfo% + ControlGet, PropInfo, List,,, ahk_id %hPropInfo% + Output .= "[Details]" . CRLF . ClassInfo . CRLF . CRLF . "[Properties]" . CRLF . PropInfo + } + Else If (Tab == 5) { ; Extra + ControlGet, ExtraInfo, List,,, ahk_id %hExtraInfo% + Output .= "[Extra]" . CRLF . ExtraInfo + } + Else If (Tab == 6) { ; Windows + ControlGet, Child, List,,, ahk_id %hChildList% + If (Child != "") { + Output .= "[Child]" . CRLF . Child . CRLF . CRLF + } + + ControlGet, Sibling, List,,, ahk_id %hSiblingList% + If (Sibling != "") { + Output .= "[Sibling]" . CRLF . Sibling . CRLF . CRLF + } + + GuiControlGet ParentLink,, ParentLink + Output .= "Parent:`t" . RegExReplace(ParentLink, "\<\/?a\>") . CRLF + GuiControlGet OwnerLink,, OwnerLink + Output .= "Owner:`t" . RegExReplace(OwnerLink, "\<\/?a\>") + } + Else If (Tab == 7) { ; Process + ControlGet, ProcInfo, List,,, ahk_id %hProcInfo% + Output .= "[Process]" . CRLF . ProcInfo + } + + Clipboard := RTrim(Output, CRLF) +Return + +ControlFromPoint(mx, my, hWnd) { + hParent := GetParent(hWnd) + If (hParent == 0) { + hParent := hWnd + } + + SmallerArea := 999999999 + hChildWnd := 0 + + WinGet List, ControlListHwnd, ahk_id %hParent% ; EnumChildWindows + Loop Parse, List, `n + { + VarSetCapacity(RECT, 16, 0) + DllCall("GetWindowRect", "Ptr", A_LoopField, "Ptr", &RECT) + Left := NumGet(RECT, 0, "Int") + Top := NumGet(RECT, 4, "Int") + Right := NumGet(RECT, 8, "Int") + Bottom := NumGet(RECT, 12, "Int") + + If ((mx >= Left) && (mx <= Right) && (my >= Top) && (my <= Bottom)) { + Area := (Right - Left) * (Bottom - Top) + If (Area < SmallerArea) { + SmallerArea := Area + hChildWnd := A_LoopField + } + } + } + + Return (hChildWnd == 0) ? hWnd : hChildWnd +} + +; Details tab +LoadProperties: + Gui Spy: ListView, %hPropInfo% + LV_Delete() + + Callback := RegisterCallback("PropEnumProcEx", "F") + DllCall("EnumPropsEx", "Ptr", g_hWnd, "Ptr", Callback, "UInt", lParam := 0) +Return + +PropEnumProcEx(hWnd, lpszString, hData, dwData) { + Global hPropInfo + + Property := StrGet(lpszString, "UTF-16") + If (Property == "") { + Property := lpszString . " (Atom)" + } + + Gui Spy: ListView, %hPropInfo% + LV_Add("", Property, Format("0x{:08X}", hData)) + + Return True +} + +LoadExtraInfo: + Gui Spy: ListView, %hExtraInfo% + + LV_Delete() + While (LV_GetText(foo, 0, 1)) { + LV_DeleteCol(1) + } + + WinGetClass Class, ahk_id %g_hWnd% + + If (Class == "Edit" || InStr(Class, "RICHEDIT")) { + LV_InsertCol(1, "169", "Property") + LV_InsertCol(2, "169", "Value") + + ControlGetText Text,, ahk_id %g_hWnd% + Length := StrLen(Text) . " characters" + ControlGet Lines, LineCount,,, ahk_id %g_hWnd% + ControlGet CurLine, CurrentLine,,, ahk_id %g_hWnd% + ControlGet CurCol, CurrentCol,,, ahk_id %g_hWnd% + + LV_Add("", "Length", Length) + LV_Add("", "Current line", CurLine) + LV_Add("", "Current column", CurCol) + LV_Add("", "Line count", Lines) + LV_Add("", "Text Limit", SendMsg(0xD5) . " bytes") ; EM_GETLIMITTEXT + LV_Add("", "Modified", {0: "False", 1: "True"}[SendMsg(0xB8)]) ; EM_GETMODIFY + } + Else If (InStr(Class, "Scintilla")) { + + LV_InsertCol(1, "169", "Property") + LV_InsertCol(2, "169", "Value") + + LexerName := Scintilla_GetLexerLanguage(g_hWnd) + CodePage := SendMsg(2137) ; SCI_GETCODEPAGE + Pos := SendMsg(2008) + Line := SendMsg(2166, Pos) + Char := SendMsg(2007, Pos) + Size := FormatBytes(SendMsg(2006), Sep, "B", 0) . " bytes" + SelSize := FormatBytes(SendMsg(2161, 0, 0) - 1, Sep, "B", 0) . " bytes" + + LV_Add("", "Lexer", SendMsg(4002) . (LexerName != "" ? " (" . LexerName . ")" : "")) ; SCI_GETLEXER + LV_Add("", "Current position", Pos + 1) ; SCI_GETCURRENTPOS + LV_Add("", "Char at position", Char . " (""" . Chr(Char) . """)") ; SCI_GETCHARAT + LV_Add("", "Style at position", SendMsg(2010, Pos)) ; SCI_GETSTYLEAT + LV_Add("", "Current line", Line + 1) ; SCI_LINEFROMPOSITION + LV_Add("", "Position from line", SendMsg(2167, Line) + 1) ; SCI_POSITIONFROMLINE + LV_Add("", "Line end position", SendMsg(2136, Line) + 1) ; SCI_GETLINEENDPOSITION + LV_Add("", "Line length", SendMsg(2350, Line)) ; SCI_LINELENGTH + LV_Add("", "Current column", SendMsg(2129, Pos) + 1) ; SCI_GETCOLUMN + LV_Add("", "Line count", SendMsg(2154)) ; SCI_GETLINECOUNT + LV_Add("", "Document size", Size) ; SCI_GETLENGTH + LV_Add("", "File encoding", (CodePage == 65001 ? "UTF-8 (65001)" : CodePage)) ; SCI_GETCODEPAGE + LV_Add("", "Modified", SendMsg(2159) ? "True" : "False") ; SCI_GETMODIFY + LV_Add("", "Read only", SendMsg(2140) ? "True" : "False") ; SCI_GETREADONLY + LV_Add("", "Wrap mode", SendMsg(2269)) ; SCI_GETWRAPMODE + LV_Add("", "Tab width", SendMsg(2121)) ; SCI_GETTABWIDTH + LV_Add("", "Indent with spaces", !SendMsg(2125) ? "True" : "False") ; SCI_GETUSETABS + LV_Add("", "Show indentation guides", SendMsg(2133) ? "True" : "False") ; SCI_GETINDENTATIONGUIDES + LV_Add("", "EOL mode", {0: "CRLF", 1: "CR", 2: "LF"}[SendMsg(2030)]) ; SCI_GETEOLMODE + LV_Add("", "Paste convert EOL", SendMsg(2468) ? "True" : "False") ; SCI_GETPASTECONVERTENDINGS + LV_Add("", "Overtype mode", SendMsg(2187) ? "1 (overtype)" : "0 (insert)") ; SCI_GETOVERTYPE + LV_Add("", "Anchor position", SendMsg(2009) + 1) ; SCI_GETANCHOR + LV_Add("", "Selection start", SendMsg(2143) + 1) ; SCI_GETSELECTIONSTART + LV_Add("", "Selection end", SendMsg(2145) + 1) ; SCI_GETSELECTIONEND + LV_Add("", "Selected text length", SelSize) ; SCI_GETSELTEXT + LV_Add("", "Selection mode", SendMsg(2423)) ; SCI_GETSELECTIONMODE + LV_Add("", "Selection is rectangular", SendMsg(2372) ? "True" : "False") ; SCI_SELECTIONISRECTANGLE + LV_Add("", "Virtual space options", SendMsg(2597)) ; SCI_GETVIRTUALSPACEOPTIONS + LV_Add("", "Rectangular selection modifier", SendMsg(2599)) ; SCI_GETRECTANGULARSELECTIONMODIFIER + ; SCI_GETMOUSESELECTIONRECTANGULARSWITCH + LV_Add("", "Mouse rectangular selection", SendMsg(2669) ? "True" : "False") + LV_Add("", "Selection start line position", SendMsg(2424, Line) + 1) ; SCI_GETLINESELSTARTPOSITION + LV_Add("", "Selection end line position", SendMsg(2425, Line) + 1) ; SCI_GETLINESELENDPOSITION + LV_Add("", "Multiple selection", SendMsg(2564) ? "True" : "False") ; SCI_GETMULTIPLESELECTION + ; SCI_GETADDITIONALSELECTIONTYPING + LV_Add("", "Additional selection typing", SendMsg(2566) ? "True" : "False") + LV_Add("", "Multipaste", SendMsg(2615)) ; SCI_GETMULTIPASTE + LV_Add("", "Line height", SendMsg(2279, Line)) ; SCI_TEXTHEIGHT + LV_Add("", "Baseline extra ascent", SendMsg(2526)) ; SCI_GETEXTRAASCENT + LV_Add("", "Baseline extra descent", SendMsg(2528)) ; SCI_GETEXTRADESCENT + LV_Add("", "Lines on screen", SendMsg(2370)) ; SCI_LINESONSCREEN + LV_Add("", "First visible line", SendMsg(2152) + 1) ; SCI_GETFIRSTVISIBLELINE + LV_Add("", "Current line wrap count", SendMsg(2235, Line)) ; SCI_WRAPCOUNT + LV_Add("", "Mouse hover time", SendMsg(2265)) ; SCI_GETMOUSEDWELLTIME + LV_Add("", "Word start position", SendMsg(2266, Pos, 1) + 1) ; SCI_WORDSTARTPOSITION + LV_Add("", "Word end position", SendMsg(2267, Pos, 1) + 1) ; SCI_WORDENDPOSITION + LV_Add("", "Autocomplete ignore case", SendMsg(2116) ? "True" : "False") ; SCI_AUTOCGETIGNORECASE + LV_Add("", "Autocomplete list presorted", SendMsg(2661)) ; SCI_AUTOCGETORDER + LV_Add("", "Autocomplete list max rows", SendMsg(2211)) ; SCI_AUTOCGETMAXHEIGHT + LV_Add("", "Position before", SendMsg(2417, Pos) + 1) ; SCI_POSITIONBEFORE + LV_Add("", "Position after", SendMsg(2418, Pos) + 1) ; SCI_POSITIONAFTER + LV_Add("", "Current indicator", SendMsg(2501)) ; SCI_GETINDICATORCURRENT + LV_Add("", "Target start", SendMsg(2191) + 1) ; SCI_GETTARGETSTART + LV_Add("", "Target end", SendMsg(2193) + 1) ; SCI_GETTARGETEND + LV_Add("", "Search flags", SendMsg(2199)) ; SCI_GETSEARCHFLAGS + LV_Add("", "Error status", SendMsg(2383)) ; SCI_GETSTATUS + LV_Add("", "Font quality", SendMsg(2612)) ; SCI_GETFONTQUALITY + LV_Add("", "Technology (drawing API)", SendMsg(2631)) ; SCI_GETTECHNOLOGY + LV_Add("", "Buffered drawing", SendMsg(2034) ? "True" : "False") ; SCI_GETBUFFEREDDRAW + LV_Add("", "Zoom factor", SendMsg(2374)) ; SCI_GETZOOM + LV_Add("", "Edge mode", SendMsg(2362)) ; SCI_GETEDGEMODE + LV_Add("", "Edge column", SendMsg(2360) + 1) ; SCI_GETEDGECOLUMN + LV_Add("", "Scroll width", SendMsg(2275)) ; SCI_GETSCROLLWIDTH + LV_Add("", "Scroll width tracking", SendMsg(2517) ? "True" : "False") ; SCI_GETSCROLLWIDTHTRACKING + LV_Add("", "End at last line", SendMsg(2278) ? "True" : "False") ; SCI_GETENDATLASTLINE + LV_Add("", "View white space", SendMsg(2020)) ; SCI_GETVIEWWS + LV_Add("", "White space size", SendMsg(2087)) ; SCI_GETWHITESPACESIZE + LV_Add("", "View EOL characters", SendMsg(2355) ? "True" : "False") ; SCI_GETVIEWEOL + LV_Add("", "Caret width", SendMsg(2189)) ; SCI_GETCARETWIDTH + LV_Add("", "Caret blinking rate", SendMsg(2075) . " ms") ; SCI_GETCARETPERIOD + LV_Add("", "Markers in current line", SendMsg(2046, Line)) ; SCI_MARKERGET + LV_Add("", "Automatic fold", SendMsg(2664)) ; SCI_GETAUTOMATICFOLD + LV_Add("", "All lines visible", SendMsg(2236) ? "True" : "False") ; SCI_GETALLLINESVISIBLE + ;LV_Add("", "", SendMsg()) ; + + Loop 5 { ; The maximum number of margins + i := A_Index - 1 + LV_Add("", "Margin " . A_Index . " - type, width, mask" + , SendMsg(2241, i) . ", " . SendMsg(2243, i) . ", " . SendMsg(2245, i)) + ; SCI_GETMARGINTYPEN, SCI_GETMARGINWIDTHN, SCI_GETMARGINMASKN + } + + } + Else If (Class == "ToolbarWindow32") { + + LV_InsertCol(1, "41", "Index") + LV_InsertCol(2, "85", "Command ID") + LV_InsertCol(3, "212", "Button Text") + + Items := GetToolbarItems(g_hWnd) + For Each, Item in Items { + LV_Add("", A_Index, Item.ID, Item.String) + } + } + Else If (Class == "SysHeader32") { + + LV_InsertCol(1, "42", "Index") + LV_InsertCol(2, "48", "Width") + LV_InsertCol(3, "248", "Text") + + Items := GetHeaderInfo(g_hWnd) + For Each, Item in Items { + LV_Add("", A_Index, Item.Width, Item.Text) + } + } + Else If (Class == "msctls_progress32") { + + LV_InsertCol(1, "169", "Property") + LV_InsertCol(2, "169", "Value") + + LV_Add("", "Range", SendMsg(0x407, 1) . " - " . SendMsg(0x407, 0)) ; PBM_GETRANGE + LV_Add("", "Position", SendMsg(0x408)) ; PBM_GETPOS + LV_Add("", "Step increment", SendMsg(0x40D)) ; PBM_GETSTEP + LV_Add("", "State", {1: "Normal", 2: "Error", 3: "Paused"}[SendMsg(0x411)]) ; PBM_GETSTATE + } + Else If (Class ~= "ListBox" || Class ~= "ComboBox") { + + LV_InsertCol(1, "38", "Line") + LV_InsertCol(2, "300", "Text") + + ControlGet ItemList, List,,, ahk_id %g_hWnd% + Loop Parse, ItemList, `n + { + LV_Add("", A_Index, A_LoopField) + } + } + Else If (Class == "msctls_statusbar32") { + + LV_InsertCol(1, "38", "Part") + LV_InsertCol(2, "300", "Text") + + SB_Text := GetStatusBarText(g_hWnd) + Loop Parse, SB_Text, | + { + LV_Add("", A_Index, A_LoopField) + } + } + Else If (Class == "SysTabControl32") { + + LV_InsertCol(1, "42", "Index") + LV_InsertCol(2, "296", "Text") + + Tabs := ControlGetTabs(g_hWnd) + Loop % Tabs.Length() { + LV_Add("", A_Index, Tabs[A_Index]) + } + } + Else If (Class == "SysListView32") { + + SendMessage 0x101F, 0, 0,, ahk_id %g_hWnd% ; LVM_GETHEADER + hHeader := ErrorLevel + SendMessage 0x1200, 0, 0,, ahk_id %hHeader% ; HDM_GETITEMCOUNT + Columns := ErrorLevel + 1 + + Loop %Columns% { + ColTitle := A_Index == 1 ? "Index" : "Column " . A_Index - 1 + LV_InsertCol(A_Index, "", ColTitle) + } + + ControlGet ItemList, List,,, ahk_id %g_hWnd% + Loop Parse, ItemList, `n + { + Items := StrSplit(A_LoopField, A_Tab) + LV_Add("", A_Index, Items*) + } + + Loop %Columns% { + LV_ModifyCol(A_Index, "AutoHdr") + } + } + + ; GetMenu return value: If the window is a child window, the return value is undefined. + If (!IsChild(g_hWnd) && hMenu := GetMenu(g_hWnd)) { + GuiControl Enable, %hBtnMenu% + } Else { + GuiControl Disable, %hBtnMenu% + } +Return + +SendMsg(Message, wParam := 0, lParam := 0) { + SendMessage %Message%, %wParam%, %lParam%,, ahk_id %g_hWnd% + Return ErrorLevel +} + +Screenshot: + If (!WinExist("ahk_id" . g_hWnd)) { + Gui Spy: +OwnDialogs + MsgBox 0x40010, Error, Window no longer exists. + Return + } + + If (IsChild(g_hWnd)) { + WinActivate % "ahk_id" . GetAncestor(g_hWnd) + Sleep 100 + If (g_ShowBorder) { + ShowBorder(g_hWnd, -1, g_BorderColor, g_BorderWidth) + Sleep 100 + Send !{PrintScreen} + Sleep 200 + } Else { + CaptureWindow(hSpyWnd, g_hWnd) + } + } Else { + WinActivate ahk_id %g_hWnd% + Sleep 100 + Send !{PrintScreen} + } + + Loop 4 { + Index := A_Index + 90 + Gui %Index%: Destroy + } + + WinActivate ahk_id %hSpyWnd% + Gui Spy: +OwnDialogs + MsgBox 0x40040, %AppName%, Content copied to the clipboard. +Return + +CaptureWindow(hwndOwner, hwnd) { + VarSetCapacity(RECT, 16, 0) + DllCall("GetWindowRect", "Ptr", hwnd, "Ptr", &RECT) + width := NumGet(RECT, 8, "Int") - NumGet(RECT, 0, "Int") + height := NumGet(RECT, 12, "Int") - NumGet(RECT, 4, "Int") + + hdc := DllCall("GetDC", "Ptr", 0, "Ptr") + hdcMem := DllCall("CreateCompatibleDC", "Ptr", hdc, "UPtr") + hBmp := DllCall("CreateCompatibleBitmap", "Ptr", hdc, "Int", width, "Int", height, "UPtr") + hdcOld := DllCall("SelectObject", "Ptr", hdcMem, "Ptr", hBmp) + + DllCall("BitBlt", "Ptr", hdcMem + , "Int", 0, "Int", 0, "Int", width, "Int", height + , "Ptr", hdc, "Int", Numget(RECT, 0, "Int"), "Int", Numget(RECT, 4, "Int") + , "UInt", 0x00CC0020) ; SRCCOPY + + DllCall("SelectObject", "Ptr", hdcMem, "Ptr", hdcOld) + + DllCall("OpenClipboard", "Ptr", hwndOwner) ; Clipboard owner + DllCall("EmptyClipboard") + DllCall("SetClipboardData", "UInt", 0x2, "Ptr", hBmp) ; CF_BITMAP + DllCall("CloseClipboard") + + DllCall("ReleaseDC", "Ptr", 0, "Ptr", hdc) + + Return True +} + +GetToolbarItems(hToolbar) { + WinGet PID, PID, ahk_id %hToolbar% + + If !(hProc := DllCall("OpenProcess", "UInt", 0x438, "Int", False, "UInt", PID, "Ptr")) { + Return + } + + If (A_Is64bitOS) { + Try DllCall("IsWow64Process", "Ptr", hProc, "Int*", Is32bit := true) + } Else { + Is32bit := True + } + + RPtrSize := Is32bit ? 4 : 8 + TBBUTTON_SIZE := 8 + (RPtrSize * 3) + + SendMessage 0x418, 0, 0,, ahk_id %hToolbar% ; TB_BUTTONCOUNT + ButtonCount := ErrorLevel + + IDs := [] ; Command IDs + Loop %ButtonCount% { + Address := DllCall("VirtualAllocEx", "Ptr", hProc, "Ptr", 0, "UPtr", TBBUTTON_SIZE, "UInt", 0x1000, "UInt", 4, "Ptr") + + SendMessage 0x417, % A_Index - 1, Address,, ahk_id %hToolbar% ; TB_GETBUTTON + If (ErrorLevel == 1) { + VarSetCapacity(TBBUTTON, TBBUTTON_SIZE, 0) + DllCall("ReadProcessMemory", "Ptr", hProc, "Ptr", Address, "Ptr", &TBBUTTON, "UPtr", TBBUTTON_SIZE, "Ptr", 0) + IDs.Push(NumGet(&TBBUTTON, 4, "Int")) + } + + DllCall("VirtualFreeEx", "Ptr", hProc, "Ptr", Address, "UPtr", 0, "UInt", 0x8000) ; MEM_RELEASE + } + + ToolbarItems := [] + Loop % IDs.Length() { + ButtonID := IDs[A_Index] + ;SendMessage 0x44B, %ButtonID% , 0,, ahk_id %hToolbar% ; TB_GETBUTTONTEXTW + ;BufferSize := ErrorLevel * 2 + BufferSize := 128 + + Address := DllCall("VirtualAllocEx", "Ptr", hProc, "Ptr", 0, "UPtr", BufferSize, "UInt", 0x1000, "UInt", 4, "Ptr") + + SendMessage 0x44B, %ButtonID%, Address,, ahk_id %hToolbar% ; TB_GETBUTTONTEXTW + + VarSetCapacity(Buffer, BufferSize, 0) + DllCall("ReadProcessMemory", "Ptr", hProc, "Ptr", Address, "Ptr", &Buffer, "UPtr", BufferSize, "Ptr", 0) + + ToolbarItems.Push({"ID": IDs[A_Index], "String": Buffer}) + + DllCall("VirtualFreeEx", "Ptr", hProc, "Ptr", Address, "UPtr", 0, "UInt", 0x8000) ; MEM_RELEASE + } + + DllCall("CloseHandle", "Ptr", hProc) + + Return ToolbarItems +} + +LoadWindowsTab: + GoSub LoadChildList + GoSub LoadSiblingList + + hParent := GetParent(g_hWnd) + ParentClass := (hParent) ? " (" GetClassName(hParent) . ")" : "" + ParentLink := "" . Format("0x{:08X}", hParent) . "" . ParentClass + GuiControl, Spy:, ParentLink, %ParentLink% + + hOwner := GetOwner(g_hWnd) + OwnerClass := (hOwner) ? " (" GetClassName(hOwner) . ")" : "" + OwnerLink := "" . Format("0x{:08X}", hOwner) . "" . OwnerClass + GuiControl, Spy:, OwnerLink, %OwnerLink% +Return + +LinkToHandle: + GuiControlGet LinkText, Spy:, %A_GuiControl% + If (RegExMatch(LinkText, "(0x\w+)", Match)) { + ShowWindowInfoIfExist(Match) + } +Return + +WindowsTabHandler: + If (A_GuiEvent == "N") { + Code := NumGet(A_EventInfo + 0, A_PtrSize * 2, "Int") + If (Code == -551) { ; TCN_SELCHANGE + SendMessage 0x130B, 0, 0,, ahk_id %hWindowsTab% ; TCM_GETCURSEL + nTab := Errorlevel + 1 + + If (nTab == 1) { + GuiControl Hide, %hSiblingList% + GuiControl Show, %hChildList% + } Else { + GuiControl Hide, %hChildList% + GuiControl Show, %hSiblingList% + } + } + } +Return + +LoadChildList: + Gui Spy: ListView, %hChildList% + LV_Delete() + + WinGet ChildList, ControlListHwnd, ahk_id %g_hWnd% + Loop Parse, ChildList, `n + { + If (GetParent(A_LoopField) != g_hWnd) { + Continue + } + + WinGetClass Class, ahk_id %A_LoopField% + ControlGetText Text,, ahk_id %A_LoopField% + LV_Add("", Format("0x{:08X}", A_LoopField), Class, Text) + } +Return + +LoadSiblingList: + Gui Spy: ListView, %hSiblingList% + LV_Delete() + + hParent := GetParent(g_hWnd) + + If (IsChild(g_hWnd)) { + WinGet SiblingList, ControlListHwnd, ahk_id %hParent% + Loop Parse, SiblingList, `n + { + If (A_LoopField == g_hWnd) { + Continue + } + + If (GetParent(A_LoopField) != hParent) { + Continue + } + + WinGetClass Class, ahk_id %A_LoopField% + ControlGetText Text,, ahk_id %A_LoopField% + LV_Add("", Format("0x{:08X}", A_LoopField), Class, Text) + } + + } Else { + WinGet WinList, List, % (hParent == 0) ? "" : "ahk_id " . hParent + Loop %WinList% { + hWnd := WinList%A_Index% + + If (hWnd == g_hWnd) { + Continue + } + + WinGetClass Class, ahk_id %hWnd% + WinGetTitle Text, ahk_id %hWnd% + LV_Add("", Format("0x{:08X}", hWnd), Class, Text) + } + } +Return + +ChildListHandler: +SiblingListHandler: + Gui Spy: ListView, % (A_ThisLabel == "ChildListHandler") ? hChildList : hSiblingList + If (A_GuiEvent != "ColClick") { + LV_GetText(hWnd, LV_GetNext()) + ShowWindowInfoIfExist(hWnd) + } +Return + +OnWM_KEYDOWN(wParam, lParam, msg, hWnd) { + Global + + If (wParam == 112) { ; F1 + GoSub ShowHelp + + } Else If (wParam == 113) { ; F2 + If (hParent := GetParent(g_hWnd)) { + g_hWnd := hParent + ShowWindowInfo() + } + + } Else If (wParam == 114) { ; F3 + GoSub ShowFindDlg + + } Else If (wParam == 115) { ; F4 + GoSub ShowTree + + } Else If (wParam == 116) { ; F5 + If (WinActive("ahk_id" . hTreeWnd)) { + Return + } + + Gui Spy: Submit, NoHide + ShowWindowInfoIfExist(EdtHandle) + + } Else If (wParam == 117) { ; F6 + GoSub FlashWindow + + } Else If (wParam == 118) { ; F7 + GoSub ShowXYWHDlg + + } Else If (wParam == 119) { ; F8 + GoSub CopyToClipboard + + } Else If (wParam == 120) { ; F9 + GoSub Screenshot + } +} + +UpdateTitleBar: + WinGetClass Class, ahk_id %g_hWnd% + hWnd := Format("0x{:X}", g_hWnd) + WinSetTitle ahk_id %hSpyWnd%,, %AppName% [%hWnd%`, %Class%] +Return + +; https://autohotkey.com/board/topic/70727-ahk-l-controlgettabs/ +ControlGetTabs(hTab) { + Static MAX_TEXT_LENGTH := 260 + , MAX_TEXT_SIZE := MAX_TEXT_LENGTH * (A_IsUnicode ? 2 : 1) + + WinGet PID, PID, ahk_id %hTab% + + ; Open the process for read/write and query info. + ; PROCESS_VM_READ | PROCESS_VM_WRITE | PROCESS_VM_OPERATION | PROCESS_QUERY_INFORMATION + If !(hProc := DllCall("OpenProcess", "UInt", 0x438, "Int", False, "UInt", PID, "Ptr")) { + Return + } + + ; Should we use the 32-bit struct or the 64-bit struct? + If (A_Is64bitOS) { + Try DllCall("IsWow64Process", "Ptr", hProc, "Int*", Is32bit := true) + } Else { + Is32bit := True + } + + RPtrSize := Is32bit ? 4 : 8 + TCITEM_SIZE := 16 + RPtrSize * 3 + + ; Allocate a buffer in the (presumably) remote process. + remote_item := DllCall("VirtualAllocEx", "Ptr", hProc, "Ptr", 0 + , "uPtr", TCITEM_SIZE + MAX_TEXT_SIZE + , "UInt", 0x1000, "UInt", 4, "Ptr") ; MEM_COMMIT, PAGE_READWRITE + remote_text := remote_item + TCITEM_SIZE + + ; Prepare the TCITEM structure locally. + VarSetCapacity(TCITEM, TCITEM_SIZE, 0) + NumPut(1, TCITEM, 0, "UInt") ; mask (TCIF_TEXT) + NumPut(remote_text, TCITEM, 8 + RPtrSize) ; pszText + NumPut(MAX_TEXT_LENGTH, TCITEM, 8 + RPtrSize * 2, "Int") ; cchTextMax + + ; Write the local structure into the remote buffer. + DllCall("WriteProcessMemory", "Ptr", hProc, "Ptr", remote_item, "Ptr", &TCITEM, "UPtr", TCITEM_SIZE, "Ptr", 0) + + Tabs := [] + VarSetCapacity(TabText, MAX_TEXT_SIZE) + + SendMessage 0x1304, 0, 0,, ahk_id %hTab% ; TCM_GETITEMCOUNT + Loop % (ErrorLevel != "FAIL") ? ErrorLevel : 0 { + ; Retrieve the item text. + SendMessage, % (A_IsUnicode) ? 0x133C : 0x1305, A_Index - 1, remote_item,, ahk_id %hTab% ; TCM_GETITEM + If (ErrorLevel == 1) { ; Success + DllCall("ReadProcessMemory", "Ptr", hProc, "Ptr", remote_text, "Ptr", &TabText, "UPtr", MAX_TEXT_SIZE, "Ptr", 0) + } Else { + TabText := "" + } + + Tabs[A_Index] := TabText + } + + ; Release the remote memory and handle. + DllCall("VirtualFreeEx", "Ptr", hProc, "Ptr", remote_item, "UPtr", 0, "UInt", 0x8000) ; MEM_RELEASE + DllCall("CloseHandle", "Ptr", hProc) + + Return Tabs +} + +SetDHW: + g_DetectHidden := !g_DetectHidden +Return + +SetMinimize: + g_Minimize := !g_Minimize +Return + +SetExplorerTheme(hWnd) { + DllCall("UxTheme.dll\SetWindowTheme", "Ptr", hWnd, "WStr", "Explorer", "Ptr", 0) +} + +SetButtonIcon(hButton, File, Index := 1) { + himl := DllCall("ImageList_Create", "Int", 16, "Int", 16, "UInt", 0x20, "Int", 1, "Int", 1, "Ptr") ; ILC_COLOR32 + IL_Add(himl, File, Index) + VarSetCapacity(BUTTON_IMAGELIST, 20 + A_PtrSize, 0) + NumPut(himl, BUTTON_IMAGELIST, 0, "Ptr") + NumPut(4, BUTTON_IMAGELIST, 16 + A_PtrSize, "UInt") ; Alignment (BUTTON_IMAGELIST_ALIGN_CENTER) + SendMessage 0x1602, 0, &BUTTON_IMAGELIST,, ahk_id %hButton% ; BCM_SETIMAGELIST + Return ErrorLevel +} + +ShowXYWHDlg: + Gui XYWH: New, LabelXYWH + Gui Font, s9, Segoe UI + Gui Color, White + + Gui Add, GroupBox, x10 y6 w145 h105, Relative to: + Gui Add, Radio, vClientCoords gSetXYWH x25 y27 w120 h23 +Checked, Client area + Gui Add, Radio, vWindowCoords gSetXYWH x25 y51 w120 h23, Window border + Gui Add, Radio, vScreenCoords gSetXYWH x25 y75 w120 h23, Screen coords + + Gui Add, GroupBox, x166 y5 w253 h105 + Gui Add, Text, x182 y31 w26 h23 +0x200, X: + Gui Add, Edit, vEdtX x209 y31 w70 h21 + Gui Add, UpDown, gMoveWindow Range-64000-64000 +0x80 + Gui Add, Text, x303 y31 w26 h23 +0x200, Y: + Gui Add, Edit, vEdtY x330 y31 w70 h21 + Gui Add, UpDown, gMoveWindow Range-64000-64000 +0x80 + Gui Add, Text, x182 y69 w26 h23 +0x200, W: + Gui Add, Edit, vEdtW x209 y69 w70 h21 + Gui Add, UpDown, gMoveWindow Range-64000-64000 +0x80 + Gui Add, Text, x303 y69 w26 h23 +0x200, H: + Gui Add, Edit, vEdtH x330 y69 w70 h21 + Gui Add, UpDown, gMoveWindow Range-64000-64000 +0x80 + + Gui Add, Text, x-1 y121 w460 h49 +0x200 -Background +Border + Gui Add, Button, gResetXYWH x9 y133 w88 h25, &Reset + Gui Add, Button, gMoveWindow x235 y133 w88 h25 +Default, &Apply + Gui Add, Button, gXYWHClose x331 y133 w88 h25, &Close + + Gui Show, w429 h170, Position and Size + + g_NewXYWH := True + GoSub SetXYWH + + If (IsChild(g_hWnd)) { + GuiControl Enable, ClientCoords + GuiControl Enable, WindowCoords + GuiControl Enable, ScreenCoords + } Else { + GuiControl Disable, ClientCoords + GuiControl Disable, WindowCoords + GuiControl Disable, ScreenCoords + GuiControl,, ScreenCoords, 1 + } +Return + +XYWHEscape: +XYWHClose: + Gui XYWH: Destroy +Return + +SetXYWH: + Gui XYWH: Submit, NoHide + + If (IsChild(g_hWnd)) { + If (ClientCoords) { + GetWindowPos(g_hWnd, X, Y, W, H) + } Else If (WindowCoords) { + ControlGetPos X, Y, W, H,, ahk_id %g_hWnd% + } Else If (ScreenCoords) { + WinGetPos X, Y, W, H, ahk_id %g_hWnd% + } + } Else { ; Top-level window + WinGetPos X, Y, W, H, ahk_id %g_hWnd% + } + + GuiControl, XYWH:, EdtX, %X% + GuiControl, XYWH:, EdtY, %Y% + GuiControl, XYWH:, EdtW, %W% + GuiControl, XYWH:, EdtH, %H% + + If (g_NewXYWH) { + g_BackupXYWH := [X, Y, W, H] + g_NewXYWH := False + } +Return + +MoveWindow: + Gui XYWH: Submit, NoHide + + If (IsChild(g_hWnd)) { + + If (ClientCoords) { + SetWindowPos(g_hWnd, EdtX, EdtY, EdtW, EdtH, 0, 0x14) ; SWP_NOACTIVATE | SWP_NOZORDER + } Else If (WindowCoords) { + ControlMove,, %EdtX%, %EdtY%, %EdtW%, %EdtH%, ahk_id %g_hWnd% + } Else If (ScreenCoords) { + VarSetCapacity(POINT, 8, 0) + NumPut(EdtX, POINT, 0) + NumPut(EdtY, POINT, 4) + DllCall("ScreenToClient", "Ptr", GetParent(g_hWnd), "Ptr", &POINT) ; PARENT + X := NumGet(POINT, 0) + Y := NumGet(POINT, 4) + SetWindowPos(g_hWnd, X, Y, EdtW, EdtH, 0, 0x14) ; SWP_NOACTIVATE | SWP_NOZORDER + } + } Else { + WinMove ahk_id %g_hWnd%,, %EdtX%, %EdtY%, %EdtW%, %EdtH% + } + + WinSet Redraw,, ahk_id %g_hWnd% +Return + +ResetXYWH: + Gui XYWH: Submit, NoHide + + If (IsChild(g_hWnd)) { + GuiControl, XYWH:, ClientCoords, 1 + } + + GuiControl,, EdtX, % g_BackupXYWH[1] + GuiControl,, EdtY, % g_BackupXYWH[2] + GuiControl,, EdtW, % g_BackupXYWH[3] + GuiControl,, EdtH, % g_BackupXYWH[4] + GoSub MoveWindow +Return + +OnWM_RBUTTONDOWN(wParam, lParam, msg, hWnd) { + Global + If (hWnd == hLbxStyles || hWnd == hLbxExStyles || hWnd == hLbxExtraStyles) { + SendMessage 0x1A9, 0, lParam,, ahk_id %hWnd% ; LB_ITEMFROMPOINT + Index := ErrorLevel + SendMessage 0x18A, %Index%, 0,, ahk_id %hWnd% ; LB_GETTEXTLEN + Len := ErrorLevel + VarSetCapacity(LB_Text, Len << !!A_IsUnicode, 0) + SendMessage 0x189, %Index%, % &LB_Text,, ahk_id %hWnd% ; LB_GETTEXT + Const := StrSplit(StrGet(&LB_Text, Len), "`t")[1] + Desc := StrReplace(oStyles[Const].Desc, "\n", "`n") + GuiControl,, GrpDesc, %Const% + GuiControl,, TxtDesc, %Desc% + } +} + +ShowWindowInfoIfExist(hWnd) { + If (IsWindow(hWnd)) { + g_hWnd := hWnd + ShowWindowInfo() + } Else { + Gui Spy: +OwnDialogs + MsgBox 0x40010, %AppName%, Invalid window handle. + } +} + +; Returns an object containing the text and width of each item of a remote SysHeader32 control +GetHeaderInfo(hHeader) { + Static MAX_TEXT_LENGTH := 260 + , MAX_TEXT_SIZE := MAX_TEXT_LENGTH * (A_IsUnicode ? 2 : 1) + + WinGet PID, PID, ahk_id %hHeader% + + ; Open the process for read/write and query info. + ; PROCESS_VM_READ | PROCESS_VM_WRITE | PROCESS_VM_OPERATION | PROCESS_QUERY_INFORMATION + If !(hProc := DllCall("OpenProcess", "UInt", 0x438, "Int", False, "UInt", PID, "Ptr")) { + Return + } + + ; Should we use the 32-bit struct or the 64-bit struct? + If (A_Is64bitOS) { + Try DllCall("IsWow64Process", "Ptr", hProc, "Int*", Is32bit := True) + } Else { + Is32bit := True + } + + RPtrSize := Is32bit ? 4 : 8 + cbHDITEM := (4 * 6) + (RPtrSize * 6) + + ; Allocate a buffer in the remote process. + remote_item := DllCall("VirtualAllocEx", "Ptr", hProc, "Ptr", 0 + , "UPtr", cbHDITEM + MAX_TEXT_SIZE + , "UInt", 0x1000, "UInt", 4, "Ptr") ; MEM_COMMIT, PAGE_READWRITE + remote_text := remote_item + cbHDITEM + + ; Prepare the HDITEM structure locally. + VarSetCapacity(HDITEM, cbHDITEM, 0) + NumPut(0x3, HDITEM, 0, "UInt") ; mask (HDI_WIDTH | HDI_TEXT) + NumPut(remote_text, HDITEM, 8, "Ptr") ; pszText + NumPut(MAX_TEXT_LENGTH, HDITEM, 8 + RPtrSize * 2, "Int") ; cchTextMax + + ; Write the local structure into the remote buffer. + DllCall("WriteProcessMemory", "Ptr", hProc, "Ptr", remote_item, "Ptr", &HDITEM, "UPtr", cbHDITEM, "Ptr", 0) + + HDInfo := {} + VarSetCapacity(HDText, MAX_TEXT_SIZE) + + SendMessage 0x1200, 0, 0,, ahk_id %hHeader% ; HDM_GETITEMCOUNT + Loop % (ErrorLevel != "FAIL") ? ErrorLevel : 0 { + ; Retrieve the item text. + SendMessage, % (A_IsUnicode) ? 0x120B : 0x1203, A_Index - 1, remote_item,, ahk_id %hHeader% ; HDM_GETITEMW + If (ErrorLevel == 1) { ; Success + DllCall("ReadProcessMemory", "Ptr", hProc, "Ptr", remote_item, "Ptr", &HDITEM, "UPtr", cbHDITEM, "Ptr", 0) + DllCall("ReadProcessMemory", "Ptr", hProc, "Ptr", remote_text, "Ptr", &HDText, "UPtr", MAX_TEXT_SIZE, "Ptr", 0) + } Else { + HDText := "" + } + + HDInfo.Push({"Width": NumGet(HDITEM, 4, "UInt"), "Text": HDText}) + } + + ; Release the remote memory and handle. + DllCall("VirtualFreeEx", "Ptr", hProc, "Ptr", remote_item, "UPtr", 0, "UInt", 0x8000) ; MEM_RELEASE + DllCall("CloseHandle", "Ptr", hProc) + + Return HDInfo +} + +SetMouseCoordMode: + GuiControlGet g_MouseCoordMode, Spy:, MouseCoordMode +Return + +GetClientCoords(hWnd, ByRef x, ByRef y) { + VarSetCapacity(POINT, 8, 0) + NumPut(x, POINT, 0, "Int") + NumPut(y, POINT, 4, "Int") + hParent := GetParent(hWnd) + DllCall("ScreenToClient", "Ptr", (hParent == 0 ? hWnd : hParent), "Ptr", &POINT) + x := NumGet(POINT, 0, "Int") + y := NumGet(POINT, 4, "Int") +} + +GetWindowCoords(hWnd, ByRef x, ByRef y) { + hParent := GetParent(hWnd) + WinGetPos px, py,,, % "ahk_id" . (hParent == 0 ? hWnd : hParent) + x := x - px + y := y - py +} + +; fnbar: 0 = horizontal, 1 = vertical, 2 = hWnd is a scroll bar +GetScrollInfo(hWnd, fnBar := 1) { + Local o := {} + NumPut(VarSetCapacity(SCROLLINFO, 28, 0), SCROLLINFO, 0, "UInt") + NumPut(0x1F, SCROLLINFO, 4, "UInt") ; fMask: SIF_ALL + DllCall("GetScrollInfo", "Ptr", hWnd, "Int", fnBar, "Ptr", &SCROLLINFO) + o.Min := NumGet(SCROLLINFO, 8, "Int") + o.Max := NumGet(SCROLLINFO, 12, "Int") + o.Page := NumGet(SCROLLINFO, 16, "UInt") + o.Pos := NumGet(SCROLLINFO, 20, "Int") + Return o +} + +ShowScrollBarInfo: + V := H := "No" + WinGet Style, Style, ahk_id %g_hWnd% + WinGetClass Class, ahk_id %g_hWnd% + + If (Class == "ScrollBar") { + If (Style & 1) { ; SBS_VERT + V := "Yes" + VSB := GetScrollInfo(g_hWnd, 2) + } Else { + H := "Yes" + HSB := GetScrollInfo(g_hWnd, 2) + } + } Else { + If (Style & 0x200000) { ; WS_VSCROLL + V := "Yes" + } + If (Style & 0x100000) { ; WS_HSCROLL + H := "Yes" + } + + HSB := GetScrollInfo(g_hWnd, 0) + VSB := GetScrollInfo(g_hWnd, 1) + } + + HPercent := (HSB.Pos) ? " (" . Round(HSB.Pos / (HSB.Max - HSB.Min) * 100) . "%)" : "" + VPercent := (VSB.Pos) ? " (" . Round(VSB.Pos / (VSB.Max - VSB.Min) * 100) . "%)" : "" + + Gui ScrollInfo: New, LabelScrollInfo hWndhScrollInfo -MinimizeBox OwnerSpy + SetWindowIcon(hScrollInfo, ResDir . "\TreeIcons.icl", 31) + Gui Font, s9, Segoe UI + Gui Color, White + Gui Add, CheckBox, w0 y0 + + Gui Add, GroupBox, x15 y13 w148 h152, Horizontal Scrollbar + Gui Add, Text, x24 y32 w60 h23 +0x200, Visible: + Gui Add, Edit, x86 y36 w60 h21 -E0x200, %H% + Gui Add, Text, x24 y57 w60 h23 +0x200, Minimum: + Gui Add, Edit, x86 y61 w60 h21 -E0x200, % HSB.Min + Gui Add, Text, x24 y82 w60 h23 +0x200, Maximum: + Gui Add, Edit, x86 y86 w60 h21 -E0x200, % HSB.Max + Gui Add, Text, x24 y107 w60 h23 +0x200, Position: + Gui Add, Edit, x86 y111 w70 h21 -E0x200, % HSB.Pos . HPercent + Gui Add, Text, x24 y132 w60 h23 +0x200, Page size: + Gui Add, Edit, x86 y136 w60 h21 -E0x200, % HSB.Page + + Gui Add, GroupBox, x178 y13 w148 h152, Vertical Scrollbar + Gui Add, Text, x188 y32 w56 h23 +0x200, Visible: + Gui Add, Edit, x250 y36 w60 h21 -E0x200, %V% + Gui Add, Text, x188 y57 w56 h23 +0x200, Minimum: + Gui Add, Edit, x250 y61 w60 h21 -E0x200, % VSB.Min + Gui Add, Text, x188 y82 w56 h23 +0x200, Maximum: + Gui Add, Edit, x250 y86 w60 h21 -E0x200, % VSB.Max + Gui Add, Text, x188 y107 w56 h23 +0x200, Position: + Gui Add, Edit, x250 y111 w70 h21 -E0x200, % VSB.Pos . VPercent + Gui Add, Text, x188 y132 w56 h23 +0x200, Page size: + Gui Add, Edit, x250 y136 w60 h21 -E0x200, % VSB.Page + + Gui Add, Text, x-1 y180 w343 h50 -Background +Border + Gui Add, Button, gScrollInfoClose x247 y193 w84 h24 +Default, &OK + + WinGetPos, X, Y,,, ahk_id %hSpyWnd% + x += 30 + y += 109 + Gui Show, x%x% y%y% w341 h229, Scrollbars +Return + +ScrollInfoEscape: +ScrollInfoClose: + Gui ScrollInfo: Destroy +Return + +GetSysColorName(Value) { + Static SysColors := {0: "COLOR_SCROLLBAR" + , 1: "COLOR_BACKGROUND" + , 2: "COLOR_ACTIVECAPTION" + , 3: "COLOR_INACTIVECAPTION" + , 4: "COLOR_MENU" + , 5: "COLOR_WINDOW" + , 6: "COLOR_WINDOWFRAME" + , 7: "COLOR_MENUTEXT" + , 8: "COLOR_WINDOWTEXT" + , 9: "COLOR_CAPTIONTEXT" + , 10: "COLOR_ACTIVEBORDER" + , 11: "COLOR_INACTIVEBORDER" + , 12: "COLOR_APPWORKSPACE" + , 13: "COLOR_HIGHLIGHT" + , 14: "COLOR_HIGHLIGHTTEXT" + , 15: "COLOR_BTNFACE" + , 16: "COLOR_BTNSHADOW" + , 17: "COLOR_GRAYTEXT" + , 18: "COLOR_BTNTEXT" + , 19: "COLOR_INACTIVECAPTIONTEXT" + , 20: "COLOR_BTNHIGHLIGHT" + , 21: "COLOR_3DDKSHADOW" + , 22: "COLOR_3DLIGHT" + , 23: "COLOR_INFOTEXT" + , 24: "COLOR_INFOBK" + , 26: "COLOR_HOTLIGHT" + , 27: "COLOR_GRADIENTACTIVECAPTION" + , 28: "COLOR_GRADIENTINACTIVECAPTION" + , 29: "COLOR_MENUHILIGHT" + , 30: "COLOR_MENUBAR"} + + Color := SysColors[Value] + Return (Color == "") ? Value : Color +} + +GetWindowPos(hWnd, ByRef X, ByRef Y, ByRef W, ByRef H) { + VarSetCapacity(RECT, 16, 0) + DllCall("GetWindowRect", "Ptr", hWnd, "Ptr", &RECT) + DllCall("MapWindowPoints", "Ptr", 0, "Ptr", GetParent(hWnd), "Ptr", &RECT, "UInt", 2) + X := NumGet(RECT, 0, "Int") + Y := NumGet(RECT, 4, "Int") + w := NumGet(RECT, 8, "Int") - X + H := NumGet(RECT, 12, "Int") - Y +} + +FindToolHandler: + If (g_Minimize) { + WinMove ahk_id %hSpyWnd%,,,,, 78 + g_Minimized := True + } + + Dragging := True + + GuiControl,, %hFindTool%, %Bitmap2% + + DllCall("SetCapture", "Ptr", hSpyWnd) + hOldCursor := DllCall("SetCursor", "Ptr", hCrossHair, "Ptr") +Return + +OnWM_MOUSEMOVE(wParam, lParam, msg, hWnd) { + Static hOldWnd := 0 + + If (Dragging) { + MouseGetPos x, y, hWin, hCtl, 2 + + g_hWnd := (hCtl == "") ? hWin : hCtl + + If (g_MouseCoordMode != "Screen") { + SendMessage 0x84, 0, % y << 16 | x,, ahk_id %hWnd% ; WM_NCHITTEST + HitTest := ErrorLevel + + If (HitTest == 1 || hCtl != "") { ; 1 = HTCLIENT + If (g_MouseCoordMode == "Client") { + GetClientCoords(g_hWnd, x, y) + } Else If (g_MouseCoordMode == "Window") { + GetWindowCoords(g_hWnd, x, y) + } + } + } + + GuiControl, Spy:, EdtCursor, %x%, %y% + + If (g_DetectHidden) { + g_hWnd := ControlFromPoint(x, y, g_hWnd) + } + + If (g_hWnd != hOldWnd && !IsBorder(g_hWnd)) { + ShowBorder(g_hWnd, -1) + If (IsChild(g_hWnd)) { + MouseGetPos,,,, ClassNN + LoadControlInfo(ClassNN) + } Else { + LoadWindowInfo() + } + GoSub UpdateTitleBar + } + + hOldWnd := g_hWnd + } +} + +OnWM_LBUTTONUP(wParam, lParam, msg, hWnd) { + If (Dragging) { + Dragging := False + + DllCall("ReleaseCapture") + DllCall("SetCursor", "Ptr", hOldCursor) + GuiControl,, %hFindTool%, %Bitmap1% + + Loop 4 { + Index := A_Index + 90 + Gui %Index%: Destroy + } + + MouseGetPos,,,, ClassNN + ShowWindowInfo() + + If (g_Minimized) { + If (Workaround) { + SendMessage 0x130C, 1, 0,, ahk_id %hTab% ; TCM_SETCURSEL + SendMessage 0x1330, 0, 0,, ahk_id %hTab% ; TCM_SETCURFOCUS + Sleep 0 + SendMessage 0x130C, 0, 0,, ahk_id %hTab% ; TCM_SETCURSEL + Workaround := False + } + + WinMove ahk_id %hSpyWnd%,,,,, 493 + } + } +} + +SetWindowIcon(hWnd, Filename, Index := 1) { + Local hSmIcon := LoadPicture(Filename, "w16 Icon" . Index, ErrorLevel) + SendMessage 0x80, 0, hSmIcon,, ahk_id %hWnd% ; WM_SETICON, ICON_SMALL + Return ErrorLevel +} + +GetWindowPlacement(hWnd) { + VarSetCapacity(WINDOWPLACEMENT, 44, 0) + NumPut(44, WINDOWPLACEMENT) + DllCall("GetWindowPlacement", "Ptr", hWnd, "Ptr", &WINDOWPLACEMENT) + Result := {} + Result.x := NumGet(WINDOWPLACEMENT, 7 * 4, "UInt") + Result.y := NumGet(WINDOWPLACEMENT, 8 * 4, "UInt") + Result.w := NumGet(WINDOWPLACEMENT, 9 * 4, "UInt") - Result.x + Result.h := NumGet(WINDOWPLACEMENT, 10 * 4, "UInt") - Result.y + Result.showCmd := NumGet(WINDOWPLACEMENT, 8, "UInt") + ; 1 = normal, 2 = minimized, 3 = maximized + Return Result +} + +GetWindowInfo(hWnd) { + NumPut(VarSetCapacity(WINDOWINFO, 60, 0), WINDOWINFO) + DllCall("GetWindowInfo", "Ptr", hWnd, "Ptr", &WINDOWINFO) + wi := Object() + wi.WindowX := NumGet(WINDOWINFO, 4, "Int") + wi.WindowY := NumGet(WINDOWINFO, 8, "Int") + wi.WindowW := NumGet(WINDOWINFO, 12, "Int") - wi.WindowX + wi.WindowH := NumGet(WINDOWINFO, 16, "Int") - wi.WindowY + wi.ClientX := NumGet(WINDOWINFO, 20, "Int") + wi.ClientY := NumGet(WINDOWINFO, 24, "Int") + wi.ClientW := NumGet(WINDOWINFO, 28, "Int") - wi.ClientX + wi.ClientH := NumGet(WINDOWINFO, 32, "Int") - wi.ClientY + wi.Style := NumGet(WINDOWINFO, 36, "UInt") + wi.ExStyle := NumGet(WINDOWINFO, 40, "UInt") + wi.Active := NumGet(WINDOWINFO, 44, "UInt") + wi.BorderW := NumGet(WINDOWINFO, 48, "UInt") + wi.BorderH := NumGet(WINDOWINFO, 52, "UInt") + wi.Atom := NumGet(WINDOWINFO, 56, "UShort") + wi.Version := NumGet(WINDOWINFO, 58, "UShort") + Return wi +} + +GetParent(hWnd) { + Return DllCall("GetParent", "Ptr", hWnd, "Ptr") +} + +GetOwner(hWnd) { + Return DllCall("GetWindow", "Ptr", hWnd, "UInt", 4, "Ptr") ; GW_OWNER +} + +ShowWindow(hWnd, nCmdShow := 1) { + DllCall("ShowWindow", "Ptr", hWnd, "Int", nCmdShow) +} + +IsWindow(hWnd) { + Return DllCall("IsWindow", "Ptr", hWnd) +} + +IsWindowVisible(hWnd) { + Return DllCall("IsWindowVisible", "Ptr", hWnd) +} + +GetMenu(hWnd) { + Return DllCall("GetMenu", "Ptr", hWnd, "Ptr") +} + +GetSubMenu(hMenu, nPos) { + Return DllCall("GetSubMenu", "Ptr", hMenu, "Int", nPos, "Ptr") +} + +GetMenuItemCount(hMenu) { + Return DllCall("GetMenuItemCount", "Ptr", hMenu) +} + +GetMenuItemID(hMenu, nPos) { + Return DllCall("GetMenuItemID", "Ptr", hMenu, "Int", nPos) +} + +GetMenuString(hMenu, uIDItem) { + ; uIDItem: the zero-based relative position of the menu item + Local lpString, MenuItemID + VarSetCapacity(lpString, 4096) + If !(DllCall("GetMenuString", "Ptr", hMenu, "UInt", uIDItem, "Str", lpString, "Int", 4096, "UInt", 0x400)) { + MenuItemID := GetMenuItemID(hMenu, uIDItem) + If (MenuItemID > -1) { + Return "SEPARATOR" + } Else { + Return (GetSubMenu(hMenu, uIDItem)) ? "SUBMENU" : "ERROR" + } + } + Return lpString +} + +GetClassName(hWnd) { + WinGetClass Class, ahk_id %hWnd% + Return Class +} + +GetFileIcon(File, SmallIcon := 1) { + VarSetCapacity(SHFILEINFO, cbFileInfo := A_PtrSize + 688) + If (DllCall("Shell32.dll\SHGetFileInfoW" + , "WStr", File + , "UInt", 0 + , "Ptr" , &SHFILEINFO + , "UInt", cbFileInfo + , "UInt", 0x100 | SmallIcon)) { ; SHGFI_ICON + Return NumGet(SHFILEINFO, 0, "Ptr") + } +} + +SetWindowPos(hWnd, x, y, w, h, hWndInsertAfter := 0, uFlags := 0x40) { ; SWP_SHOWWINDOW + Return DllCall("SetWindowPos", "Ptr", hWnd, "Ptr", hWndInsertAfter, "Int", x, "Int", y, "Int", w, "Int", h, "UInt", uFlags) +} + +ShowSettingsDlg: + Gui Settings: New, LabelSettings hWndhSettingsDlg -MinimizeBox OwnerSpy + SetWindowIcon(hSettingsDlg, ResDir . "\Settings.ico") + Gui Font, s9, Segoe UI + Gui Color, White + + Gui Add, GroupBox, x8 y7 w319 h56, %AppName% + Gui Add, CheckBox, vg_AlwaysOnTop x20 y27 w291 h23 Checked%g_AlwaysOnTop%, Show the window always on top + + Gui Add, GroupBox, x8 y69 w319 h152, Screenshot + Gui Add, Radio, % "x20 y88 w290 h23 " . (!g_ShowBorder ? "Checked" : "") + , Capture the contents of the control only + Gui Add, Radio, vg_ShowBorder x20 y118 w290 h23 Checked%g_ShowBorder% + , Display a border around the control + Gui Add, Text, x36 y150 w78 h23 +0x200, Border color: + Gui Add, Progress, vBorderColorPreview x119 y151 w23 h23 +0x800000 c%g_BorderColor%, 100 + Gui Add, Button, gChooseBorderColor x150 y150 w80 h24, Choose + Gui Add, Text, x36 y183 w79 h23 +0x200, Border width: + Gui Add, Edit, vg_BorderWidth x119 y184 w42 h21 + Gui Add, UpDown, x159 y184 w18 h21, %g_BorderWidth% + + Gui Add, Text, x-1 y231 w338 h48 -Background +Border + Gui Add, Button, gApplySettings x152 y243 w84 h24 +Default, &OK + Gui Add, Button, gSettingsClose x243 y243 w84 h24, &Cancel + Gui Show, w335 h278, Settings +Return + +SettingsEscape: +SettingsClose: + Gui Settings: Destroy +Return + +ApplySettings: + Gui Settings: Submit + WinSet AlwaysOnTop, % g_AlwaysOnTop ? "On" : "Off", ahk_id %hSpyWnd% + g_ShowBorder := (g_ShowBorder == 2) ? 1 : 0 + g_BorderColor := g_BorderColorTemp +Return + +ChooseBorderColor: + g_BorderColorTemp := g_BorderColor + If (ChooseColor(g_BorderColorTemp, hSettingsDlg)) { + GuiControl, Settings: +c%g_BorderColorTemp%, BorderColorPreview + } +Return + +ChooseColor(ByRef Color, hOwner := 0) { + rgbResult := ((Color & 0xFF) << 16) + (Color & 0xFF00) + ((Color >> 16) & 0xFF) + + VarSetCapacity(CUSTOM, 64, 0) + NumPut(VarSetCapacity(CHOOSECOLOR, A_PtrSize * 9, 0), CHOOSECOLOR, 0) + NumPut(hOwner, CHOOSECOLOR, A_PtrSize) + NumPut(rgbResult, CHOOSECOLOR, A_PtrSize * 3) + NumPut(&CUSTOM, CHOOSECOLOR, A_PtrSize * 4) ; COLORREF *lpCustColors + NumPut(0x103, CHOOSECOLOR, A_PtrSize * 5) ; Flags: CC_ANYCOLOR | CC_RGBINIT | CC_FULLOPEN + + RetVal := DllCall("comdlg32\ChooseColorA", "Str", CHOOSECOLOR) + If (ErrorLevel != 0 || RetVal == 0) { + Return False + } + + rgbResult := NumGet(CHOOSECOLOR, A_PtrSize * 3) + Color := (rgbResult & 0xFF00) + ((rgbResult & 0xFF0000) >> 16) + ((rgbResult & 0xFF) << 16) + Color := Format("0x{:06X}", Color) + Return True +} + +OnWM_SYSCOMMAND(wParam, lParam, msg, hWnd) { + If (wParam == 0xC0DE) { + Gui Spy: +OwnDialogs + MsgBox 0x40040, About, %AppName% %Version%`nWindow information tool`n`nCredits:`n - J Brown (WinSpy++ developer)`n - Lexicos (AutoHotkey developer) + } +} + +ShowFindDlg: + If (FindDlgExist) { + Gui Find: Show + } Else { + Gui Find: New, LabelFind hWndhFindDlg + Gui Font, s9, Segoe UI + Gui Color, White + + Gui Add, Text, x15 y16 w81 h23 +0x200, Text or Title: + Gui Add, Edit, hWndhEdtFindByText vEdtFindByText gFindWindow x144 y17 w286 h21 + Gui Add, CheckBox, vChkFindRegEx x441 y16 w120 h23, Regular Expression + Gui Add, Text, x15 y54 w79 h23 +0x200, Class Name: + Gui Add, ComboBox, vCbxFindByClass gFindWindow x144 y54 w286 + Gui Add, Text, x15 y93 w110 h23 +0x200, Process ID or Name: + Gui Add, ComboBox, vCbxFindByProcess gFindWindow x144 y93 w286 + + Gui Add, ListView, hWndhFindList gFindListHandler x10 y130 w554 h185 +LV0x14000 + , hWnd|Class|Text|Process + LV_ModifyCol(1, 0) + LV_ModifyCol(2, 133) + LV_ModifyCol(3, 285) + LV_ModifyCol(4, 112) + + Gui Add, Text, x-1 y329 w576 h49 +Border -Background + Gui Add, Button, gFindOK x381 y342 w88 h25 Default, &OK + Gui Add, Button, gFindClose x477 y342 w88 h25, &Cancel + + Gui Show, w574 h377, Find Window + SetExplorerTheme(hFindList) + + FindDlgExist := True + } + + ; Unique class names + Global Classes := [] + WinGet WinList, List + Loop %WinList% { + hThisWnd := WinList%A_Index% + WinGetClass WClass, ahk_id %hThisWnd% + AddUniqueClass(WClass) + + WinGet ControlList, ControlListHwnd, ahk_id %hThisWnd% + Loop Parse, ControlList, `n + { + WinGetClass CClass, ahk_id %A_LoopField% + AddUniqueClass(CClass) + } + } + + ClassList := "" + Loop % Classes.Length() { + ClassList .= Classes[A_Index] . "|" + } + + GuiControl,, CbxFindByClass, %ClassList% + + ; Unique process names + Processes := [] + For Process in ComObjGet("winmgmts:").ExecQuery("Select * from Win32_Process") { + If (Process.ProcessID < 10) { + Continue + } + + Unique := True + Loop % Processes.Length() { + If (Process.Name == Processes[A_Index]) { + Unique := False + Break + } + } + + If (Unique) { + Processes.Push(Process.Name) + } + } + + ProcList := "" + MaxItems := Processes.Length() + Loop %MaxItems% { + ProcList .= Processes[MaxItems - A_Index + 1] . "|" + } + + GuiControl,, CbxFindByProcess, %ProcList% +Return + +AddUniqueClass(ClassName) { + Local Unique := True + Loop % Classes.Length() { + If (ClassName == Classes[A_Index]) { + Unique := False + Break + } + } + + If (Unique) { + Classes.Push(ClassName) + } +} + +FindEscape: +FindClose: + Gui Find: Hide +Return + +FindWindow: + Gui Find: Submit, NoHide + + Gui ListView, %hFindList% + GuiControl -Redraw, %hFindList% + LV_Delete() + + WinGet WinList, List + Loop %WinList% { + hThisWnd := WinList%A_Index% + If (hThisWnd == hFindDlg) { + Continue + } + + WinGetClass WClass, ahk_id %hThisWnd% + WinGetTitle WTitle, ahk_id %hThisWnd% + WinGet WProcess, ProcessName, ahk_id %hThisWnd% + WinGet WProcPID, PID, ahk_id %hThisWnd% + + If (MatchCriteria(WTitle, WClass, IsNumber(CbxFindByProcess) ? WProcPID : WProcess)) { + LV_Add("", hThisWnd, WClass, WTitle, WProcess) + } + + WinGet ControlList, ControlListHwnd, ahk_id %hThisWnd% + Loop Parse, ControlList, `n + { + ControlGetText CText,, ahk_id %A_LoopField% + WinGetClass CClass, ahk_id %A_LoopField% + WinGet CProcess, ProcessName, ahk_id %A_LoopField% + WinGet CProcPID, PID, ahk_id %A_LoopField% + + If (MatchCriteria(CText, CClass, IsNumber(CbxFindByProcess) ? CProcPID : CProcess)) { + LV_Add("", A_LoopField, CClass, CText, CProcess) + } + } + } + + GuiControl +Redraw, %hFindList% +Return + +MatchCriteria(Text, Class, Process) { + Global + + If (EdtFindByText != "") { + If (ChkFindRegEx) { + If (RegExMatch(Text, EdtFindByText) < 1) { + Return False + } + } Else { + If (!InStr(Text, EdtFindByText)) { + Return False + } + } + } + + If (CbxFindByClass != "" && !InStr(Class, CbxFindByClass)) { + Return False + } + + If (CbxFindByProcess != "") { + Return IsNumber(Process) ? CbxFindByProcess == Process : InStr(Process, CbxFindByProcess) + } + + Return True +} + +FindOK: + Gui ListView, %hFindList% + LV_GetText(hWnd, LV_GetNext()) + GuiControl, Spy:, EdtHandle, %hWnd% + WinActivate ahk_id %hSpyWnd% + Gui Find: Hide +Return + +FindListHandler: + If (A_GuiEvent == "DoubleClick") { + GoSub FindOK + } +Return + +CreateImageList() { + ImageList := IL_Create(32) + IL_Add(ImageList, TreeIcons, 1) ; Generic window icon + IL_Add(ImageList, TreeIcons, 2) ; Desktop (#32769) + IL_Add(ImageList, TreeIcons, 3) ; Dialog (#32770) + IL_Add(ImageList, TreeIcons, 4) ; Button + IL_Add(ImageList, TreeIcons, 5) ; CheckBox + IL_Add(ImageList, TreeIcons, 6) ; ComboBox + IL_Add(ImageList, TreeIcons, 7) ; DateTime + IL_Add(ImageList, TreeIcons, 8) ; Edit + IL_Add(ImageList, TreeIcons, 9) ; GroupBox + IL_Add(ImageList, TreeIcons, 10) ; Hotkey + IL_Add(ImageList, TreeIcons, 11) ; Icon + IL_Add(ImageList, TreeIcons, 12) ; Link + IL_Add(ImageList, TreeIcons, 13) ; ListBox + IL_Add(ImageList, TreeIcons, 14) ; ListView + IL_Add(ImageList, TreeIcons, 15) ; MonthCal + IL_Add(ImageList, TreeIcons, 16) ; Picture + IL_Add(ImageList, TreeIcons, 17) ; Progress + IL_Add(ImageList, TreeIcons, 18) ; Radio + IL_Add(ImageList, TreeIcons, 19) ; RichEdit + IL_Add(ImageList, TreeIcons, 20) ; Separator + IL_Add(ImageList, TreeIcons, 21) ; Slider + IL_Add(ImageList, TreeIcons, 22) ; Status bar + IL_Add(ImageList, TreeIcons, 23) ; Tab + IL_Add(ImageList, TreeIcons, 24) ; Text + IL_Add(ImageList, TreeIcons, 25) ; Toolbar + IL_Add(ImageList, TreeIcons, 26) ; Tooltips + IL_Add(ImageList, TreeIcons, 27) ; TreeView + IL_Add(ImageList, TreeIcons, 28) ; UpDown + IL_Add(ImageList, TreeIcons, 29) ; IE + IL_Add(ImageList, TreeIcons, 30) ; Scintilla + IL_Add(ImageList, TreeIcons, 31) ; ScrollBar + IL_Add(ImageList, TreeIcons, 32) ; SysHeader + Return ImageList +} + +ShowTree: + If (WinExist("ahk_id" . hTreeWnd)) { + Gui Tree: Show + SetWindowIcon(hTreeWnd, "shell32.dll", 42) + } Else { + Gui Tree: New, LabelTree hWndhTreeWnd +Resize + SetWindowIcon(hTreeWnd, "shell32.dll", 42) + + Menu TreeMenu, Add, &Reload`tF5, LoadTree + Menu TreeMenu, Add + Menu TreeMenu, Add, E&xit`tEsc, TreeClose + Menu MenuBar, Add, &Tree, :TreeMenu + Menu ViewMenu, Add, Show &Hidden Windows, ToggleHiddenWindows + Menu ViewMenu, Add + Menu ViewMenu, Add, &Flash Window`tF6, FlashWindow + Menu ViewMenu, Add + Menu ViewMenu, Add, E&xpand All Nodes, ExpandAll + Menu ViewMenu, Add, &Collapse All Nodes, CollapseAll + Menu MenuBar, Add, &View, :ViewMenu + Gui Tree: Menu, MenuBar + + Gui Font, s9, Segoe UI + Gui Add, TreeView, hWndhTree gTreeHandler x0 y0 w681 h445 -Lines +0x9000 + + Gui Show, w681 h445, %AppName% - Tree + + TV_SetImageList(CreateImageList()) + SetExplorerTheme(hTree) + } + + GoSub LoadTree +Return + +TreeEscape: +TreeClose: + Gui Tree: Hide +Return + +TreeSize: + If (A_EventInfo == 1) { ; Minimized + Return + } + + AutoXYWH("wh", hTree) +Return + +LoadTree: + Global TreeIDs := {} + + Gui Tree: Default + TV_Delete() + + RootID := TV_Add("Desktop", 0, "Icon2") + TreeIDs[RootID] := DllCall("GetDesktopWindow", "Ptr") + + WinGet WinList, List + Loop %WinList% { + hWnd := WinList%A_Index% + + WinGetClass Class, ahk_id %hWnd% + WinGetTitle Title, ahk_id %hWnd% + If (Title != "") { + Title := " - " . Title + } + + Invisible := !IsWindowVisible(hWnd) + + If (!g_TreeShowAll && Invisible) { + Continue + } + + If (Invisible) { + Title .= " (hidden)" + } + + Icon := GetWindowIcon(hWnd, Class, True) + + ID := TV_Add(Class . Title, RootID, "Icon" . Icon) + TreeIDs[ID] := hWnd + Tree(hWnd, ID) + } + + TV_Modify(RootID, "+Expand") + + For Key, Value in TreeIDs { + If (g_hWnd == Value) { + TV_Modify(Key, "Select") + } + } +Return + +Tree(hParentWnd, ParentID) { + WinGet WinList, ControlListHwnd, ahk_id %hParentWnd% + Loop Parse, WinList, `n + { + If (GetParent(A_LoopField) != hParentWnd) { + Continue + } + + WinGetClass Class, ahk_id %A_LoopField% + If (IsChild(A_LoopField)) { + ControlGetText Text,, ahk_id %A_LoopField% + } Else { + WinGetTitle Text,, ahk_id %A_LoopField% + } + + If (Text != "") { + Text := " - " . Text + } + + Invisible := !IsWindowVisible(A_LoopField) + + If (!g_TreeShowAll && Invisible) { + Continue + } + + If (Invisible) { + Text .= " (hidden)" + } + + Icon := GetWindowIcon(A_LoopField, Class) + + ID := TV_Add(Class . Text, ParentID, "Icon" . Icon) + TreeIDs[ID] := A_LoopField + Tree(A_LoopField, ID) + } +} + +TreeHandler: + If (A_GuiEvent == "DoubleClick") { + g_hWnd := TreeIDs[A_EventInfo] + ShowWindowInfo() + } +Return + +GetWindowIcon(hWnd, Class, TopLevel := False) { + Static Classes := {0:0 + , "#32770": 3 + , "Button": 4 + , "CheckBox": 5 + , "ComboBox": 6 + , "SysDateTimePick32": 7 + , "Edit": 8 + , "GroupBox": 9 + , "msctls_hotkey32": 10 + , "Icon": 11 + , "SysLink": 12 + , "ListBox": 13 + , "SysListView32": 14 + , "SysMonthCal32": 15 + , "Picture": 16 + , "msctls_progress32": 17 + , "Radio": 18 + , "RebarWindow32": 25 + , "RichEdit": 19 + , "Separator": 20 + , "msctls_trackbar32": 21 + , "msctls_statusbar32": 22 + , "SysTabControl32": 23 + , "Static": 24 + , "ToolbarWindow32": 25 + , "tooltips_class32": 26 + , "SysTreeView32": 27 + , "msctls_updown32": 28 + , "Internet Explorer_Server": 29 + , "Scintilla": 30 + , "ScrollBar": 31 + , "SysHeader32": 32} + + If (Class == "Button") { + WinGet Style, Style, ahk_id %hWnd% + Type := Style & 0xF + If (Type == 7) { + Class := "GroupBox" + } Else If (Type ~= "2|3|5|6") { + Class := "CheckBox" + } Else If (Type ~= "4|9") { + Class := "Radio" + } Else { + Class := "Button" + } + } Else If (Class == "Static") { + WinGet Style, Style, ahk_id %hWnd% + Type := Style & 0x1F ; SS_TYPEMASK + If (Type == 3) { + Class := "Icon" + } Else If (Type == 14) { + Class := "Picture" + } Else If (Type == 0x10) { + Class := "Separator" + } Else { + Class := "Static" + } + } Else If (InStr(Class, "RICHED", True) == 1) { + Class := "RichEdit" ; RICHEDIT50W + } + + Icon := Classes[Class] + If (Icon != "") { + Return Icon + } + + SendMessage 0x7F, 2, 0,, ahk_id %hWnd% ; WM_GETICON, ICON_SMALL2 + hIcon := ErrorLevel + + If (hIcon == 0 && TopLevel) { + WinGet ProcessPath, ProcessPath, ahk_id %hWnd% + hIcon := GetFileIcon(ProcessPath) + } + + IconIndex := (hIcon) ? IL_Add(ImageList, "HICON: " . hIcon) : 1 + Return IconIndex +} + +ToggleHiddenWindows: + g_TreeShowAll := !g_TreeShowAll + GoSub LoadTree + Menu ViewMenu, ToggleCheck, Show &Hidden Windows +Return + +CollapseAll: +ExpandAll: + Expand := (A_ThisLabel == "ExpandAll") ? "+Expand" : "-Expand" + + ItemID := 0 + Loop { + ItemID := TV_GetNext(ItemID, "Full") + If (!ItemID) { + Break + } + + TV_Modify(ItemID, Expand) + } +Return + +FlashWindow: + If (A_Gui == "Tree") { + hWnd := TreeIDs[TV_GetSelection()] + } Else { + hWnd := g_hWnd + } + + ShowBorder(hWnd, 200, 0xFF0000) + Sleep 200 + ShowBorder(hWnd, 200, 0xFF0000) + Sleep 200 + ShowBorder(hWnd, 200, 0xFF0000) +Return + +; Based on a script written by Lexicos +ShowMenuViewer: + If (MenuViewerExist) { + Gui MenuViewer: Show + } Else { + Gui MenuViewer: New, +LabelMenuViewer +hWndhMenuViewer +Resize + Gui Font, s9, Segoe UI + Gui Color, 0xF1F5FB + + Gui Add, ListView, hWndhMenuList vLVMenu x0 y0 w600 h400 +LV0x14000, Menu Item String|Keyboard|Menu ID + LV_ModifyCol(1, 410) + LV_ModifyCol(2, 103) + LV_ModifyCol(3, "65 Integer") + SetExplorerTheme(hMenuList) + + Gui Add, Edit, hWndhEdtMenuSearch vEdtMenuSearch gSearchMenu x8 y408 w200 h23 +0x2000000 ; WS_CLIPCHILDREN + DllCall("SendMessage", "Ptr", hEdtMenuSearch, "UInt", 0x1501, "Ptr", 1, "WStr", "Search") + + Gui Add, Picture, hWndhSearchIcon x178 y1 w16 h16, %ResDir%\Search.ico + DllCall("SetParent", "Ptr", hSearchIcon, "Ptr", hEdtMenuSearch) + WinSet Style, -0x40000000, ahk_id %hSearchIcon% ; -WS_CHILD + ControlFocus,, ahk_id %hEdtMenuSearch% + + NoAmpersands := True + Gui Add, CheckBox, vNoAmpersands gShowMenuItems x220 y408 w167 h23 Checked%NoAmpersands% + , Remove Ampersands (&&) + Gui Add, Button, vBtnMenuCopy gCopyMenuList x466 y407 w125 h25, Copy to Clipboard + Gui Show, w600 h440, Menu Viewer + MenuViewerExist := True + } + + GoSub ShowMenuItems +Return + +ShowMenuItems: + Gui MenuViewer: Default + Gui Submit, NoHide + + LV_Delete() + hMenu := GetMenu(g_hWnd) + If (hMenu) { + MenuItems := [] + GetMenuItems(hMenu, "", "") + } +Return + +GetMenuItems(hMenu, Prefix, ByRef Commands) { + Global + ItemCount := GetMenuItemCount(hMenu) + + Loop %ItemCount% { + ItemString := GetMenuString(hMenu, A_Index - 1) + ItemID := GetMenuItemID(hMenu, A_Index - 1) + + RegExMatch(ItemString, "\t(.+)", Keyboard) + ItemString := RegExReplace(ItemString, "\t.*") + If (ItemString == "SEPARATOR") { + ItemString := "----------------------------" + } + + MenuItems.Push([ItemString, Keyboard1, ItemID]) + + If (NoAmpersands) { + ItemString := StrReplace(ItemString, "&") + } + + LV_Add("", Prefix . ItemString, Keyboard1, ItemID) + + If (ItemID == -1) { ; Submenu + hSubMenu := GetSubMenu(hMenu, A_Index - 1) + If (hSubMenu) { + Prefix .= " " + GetMenuItems(hSubMenu, Prefix, Commands) + Prefix := StrReplace(Prefix, " ", "",, 1) + Continue + } + } + } +} + +SearchMenu: + Gui MenuViewer: Submit, NoHide + + Gui ListView, %hMenuList% + LV_Delete() + + Loop % MenuItems.Length() { + MenuItem := MenuItems[A_Index][1] + Keyboard := MenuItems[A_Index][2] + MenuID := MenuItems[A_Index][3] + + If (NoAmpersands) { + MenuItem := StrReplace(MenuItem, "&") + } + + If (InStr(MenuItem, EdtMenuSearch) + || InStr(Keyboard, EdtMenuSearch) + || InStr(MenuID, EdtMenuSearch)) { + LV_Add("", MenuItem, Keyboard, MenuID) + } + } +Return + +CopyMenuList: + Gui MenuViewer: Default + ControlGet MenuList, List,,, ahk_id %hMenuList% + Clipboard := StrReplace(MenuList, " ", "`t") +Return + +MenuViewerEscape: +MenuViewerClose: + Gui MenuViewer: Hide +Return + +MenuViewerSize: + If (A_EventInfo == 1) { ; Minimized + Return + } + + AutoXYWH("wh", hMenuList) + AutoXYWH("y", hEdtMenuSearch) + AutoXYWH("y", hSearchIcon) + AutoXYWH("y", "NoAmpersands") + AutoXYWH("xy", "BtnMenuCopy") +Return + +MenuViewerContextMenu: + Row := LV_GetNext() + LV_GetText(MenuString, Row, 1) + LV_GetText(MenuID, Row, 3) + + If (A_GuiControl == "LVMenu" && MenuID > 0 && !InStr(MenuString, "-----")) { + Menu MenuMenu, Add, Invoke Menu Command, InvokeMenuCommand + Menu MenuMenu, Show + } +Return + +InvokeMenuCommand: + PostMessage 0x111, %MenuID%,,, ahk_id %g_hWnd% +Return + +LoadProcessProperties: + Gui Spy: Submit, NoHide + + WinGet PID, PID, ahk_id %g_hWnd% + + StrQuery := "SELECT * FROM Win32_Process WHERE ProcessId=" . PID + Enum := ComObjGet("winmgmts:").ExecQuery(StrQuery)._NewEnum + If (Enum[Process]) { + ExePath := Process.ExecutablePath + + hIcon := GetFileIcon(ExePath, 0) + If (!hIcon || ExePath == "") { + hIcon := DllCall("LoadIcon", "Ptr", 0, "UInt", 32512, "Ptr") ; IDI_APPLICATION + } + + GuiControl,, ProgIcon, % "HICON:" . hIcon + GuiControl,, ProgName, % Process.Name + FileGetVersion ProgVer, %ExePath% + GuiControl,, ProgVer, %ProgVer% + + Gui ListView, %hProcInfo% + LV_Delete() + LV_Add("", "Path", ExePath) + LV_Add("", "Command line", Process.CommandLine) + LV_Add("", "Process ID", Process.ProcessId) + LV_Add("", "Thread ID", DllCall("GetWindowThreadProcessId", "Ptr", g_hWnd, "Ptr", 0)) + CreationDate := Process.CreationDate + SubStr(CreationDate, 1, InStr(CreationDate, ".") - 1) + FormatTime CreationDate, %CreationDate% D1 T0 ; Short date and time with seconds + LV_Add("", "Started", CreationDate) + LV_Add("", "Working Size", FormatBytes(Process.WorkingSetSize, Sep)) + LV_Add("", "Virtual Size", FormatBytes(Process.VirtualSize, Sep)) + LV_Add("", "Image Type", GetImageType(PID)) + } +Return + +GetImageType(PID) { + ; PROCESS_QUERY_INFORMATION + hProc := DllCall("OpenProcess", "UInt", 0x400, "Int", False, "UInt", PID, "Ptr") + If (!hProc) { + Return "N/A" + } + + If (A_Is64bitOS) { + ; Determines whether the specified process is running under WOW64. + Try DllCall("IsWow64Process", "Ptr", hProc, "Int*", Is32Bit := True) + } Else { + Is32Bit := True + } + + DllCall("CloseHandle", "Ptr", hProc) + + Return (Is32Bit) ? "32-bit" : "64-bit" +} + +EndProcess: + GuiControlGet Filename,, ProgName + If (Filename == "N/A") { + Return + } + + Gui Spy: +OwnDialogs + MsgBox 0x40031, %AppName%, Are you sure you want to exit %Filename%? + IfMsgBox OK, { + WinGet PID, PID, ahk_id %g_hWnd% + Process Close, %PID% + If (ErrorLevel == 0) { + Gui Spy: +OwnDialogs + MsgBox 0x40010, Error, The process named %Filename% with PID %PID% could not be ended. + } + } +Return + +OpenFolder: + Gui ListView, %hProcInfo% + LV_GetText(ExePath, 1, 2) + If (ExePath != "") { + Run *open explorer.exe /select`,"%ExePath%" + } +Return + +FormatBytes(Value, sThousand := ".", Unit := -1, ShowUnit := True) { + If ((Unit == -1 && Value > 999) || Unit == "K") { + Value /= 1024 + Unit := ShowUnit ? " K" : "" + } Else { + Unit := ShowUnit ? " B" : "" + } + + a := "" + Loop % StrLen(Value) { + a .= SubStr(Value, 1 - A_Index, 1) + If (Mod(A_Index, 3) == 0) { + a .= sThousand + } + } + + a := RTrim(a, sThousand) + + b := "" + Loop % StrLen(a) { + b .= SubStr(a, 1 - A_Index, 1) + } + + Return b . Unit +} + +; http://ahkscript.org/boards/viewtopic.php?t=1079 +AutoXYWH(DimSize, cList*) { + Static cInfo := {} + + If (DimSize = "reset") { + Return cInfo := {} + } + + For i, ctrl in cList { + ctrlID := A_Gui ":" ctrl + If (cInfo[ctrlID].x = "") { + GuiControlGet i, %A_Gui%: Pos, %ctrl% + MMD := InStr(DimSize, "*") ? "MoveDraw" : "Move" + fx := fy := fw := fh := 0 + For i, dim in (a := StrSplit(RegExReplace(DimSize, "i)[^xywh]"))) { + If (!RegExMatch(DimSize, "i)" . dim . "\s*\K[\d.-]+", f%dim%)) { + f%dim% := 1 + } + } + cInfo[ctrlID] := {x: ix, fx: fx, y: iy, fy: fy, w: iw, fw: fw, h: ih, fh: fh, gw: A_GuiWidth, gh: A_GuiHeight, a: a, m: MMD} + } Else If (cInfo[ctrlID].a.1) { + dgx := dgw := A_GuiWidth - cInfo[ctrlID].gw, dgy := dgh := A_GuiHeight - cInfo[ctrlID].gh + Options := "" + For i, dim in cInfo[ctrlID]["a"] { + Options .= dim . (dg%dim% * cInfo[ctrlID]["f" . dim] + cInfo[ctrlID][dim]) . A_Space + } + GuiControl, % A_Gui ":" cInfo[ctrlID].m, % ctrl, % Options + } + } +} + +IsBorder(hWnd) { + Loop % g_Borders.Length() { + If (g_Borders[A_Index] == hWnd) { + Return True + } + } + Return False +} + +IsNumber(n) { + If n Is Number + Return True + Return False +} + +ShowHelp: +Gui Spy: +OwnDialogs +MsgBox 0x40, %AppName% Keyboard Shortcuts, +( +F2: Go to the parent window +F3: Show the Find dialog +F4: Show the hierarchical window tree +F5: Reload window information +F6: Highlight window location +F7: Position and Size dialog +F8: Copy information to the clipboard +F9: Copy screenshot to the clipboard +) +Return