GUI Constants - updated on 2015-04-26

Post your working scripts, libraries and tools
just me
Posts: 7857
Joined: 02 Oct 2013, 08:51
Location: Germany

Re: GUI Constants

13 Sep 2014, 06:10

Const_Toolbar - constants for toolbar controls (not built-in).

Code: Select all

; ======================================================================================================================
; Function:         Constants for Toolbar controls
; AHK version:      1.1.05+
; Language:         English
; Version:          1.0.00.00/2012-05-05/just me
; Remarks:          Although not a built-in AHK GUI control it might be useful anyway.
; ======================================================================================================================
; TBN_FIRST = -700
; WM_USER   = 0x0400
; ======================================================================================================================
; Class ================================================================================================================
Global WC_TOOLBAR               := "ToolbarWindow32"
; Messages =============================================================================================================
Global TB_ADDBITMAP             := 0x0413 ; (WM_USER + 19)
Global TB_ADDBUTTONSA           := 0x0414 ; (WM_USER + 20)
Global TB_ADDBUTTONSW           := 0x0444 ; (WM_USER + 68)
Global TB_ADDSTRINGA            := 0x041C ; (WM_USER + 28)
Global TB_ADDSTRINGW            := 0x044D ; (WM_USER + 77)
Global TB_AUTOSIZE              := 0x0421 ; (WM_USER + 33)
Global TB_BUTTONCOUNT           := 0x0418 ; (WM_USER + 24)
Global TB_BUTTONSTRUCTSIZE      := 0x041E ; (WM_USER + 30)
Global TB_CHANGEBITMAP          := 0x042B ; (WM_USER + 43)
Global TB_CHECKBUTTON           := 0x0402 ; (WM_USER + 2)
Global TB_COMMANDTOINDEX        := 0x0419 ; (WM_USER + 25)
Global TB_CUSTOMIZE             := 0x041B ; (WM_USER + 27)
Global TB_DELETEBUTTON          := 0x0416 ; (WM_USER + 22)
Global TB_ENABLEBUTTON          := 0x0401 ; (WM_USER + 1)
Global TB_GETANCHORHIGHLIGHT    := 0x044A ; (WM_USER + 74)
Global TB_GETBITMAP             := 0x042C ; (WM_USER + 44)
Global TB_GETBUTTON             := 0x0417 ; (WM_USER + 23)
Global TB_GETBUTTONINFOA        := 0x0441 ; (WM_USER + 65)
Global TB_GETBUTTONINFOW        := 0x043F ; (WM_USER + 63)
Global TB_GETBUTTONSIZE         := 0x043A ; (WM_USER + 58)
Global TB_GETBUTTONTEXTA        := 0x042D ; (WM_USER + 45)
Global TB_GETBUTTONTEXTW        := 0x044B ; (WM_USER + 75)
Global TB_GETCOLORSCHEME        := 0x2003 ; CCM_GETCOLORSCHEME   // fills in COLORSCHEME pointed to by lParam
Global TB_GETDISABLEDIMAGELIST  := 0x0437 ; (WM_USER + 55)
Global TB_GETEXTENDEDSTYLE      := 0x0455 ; (WM_USER + 85)       // For TBSTYLE_EX_*
Global TB_GETHOTIMAGELIST       := 0x0435 ; (WM_USER + 53)
Global TB_GETHOTITEM            := 0x0447 ; (WM_USER + 71)
Global TB_GETIDEALSIZE          := 0x0463 ; (WM_USER + 99)       // wParam == fHeight, lParam = psize
Global TB_GETIMAGELIST          := 0x0431 ; (WM_USER + 49)
Global TB_GETIMAGELISTCOUNT     := 0x0462 ; (WM_USER + 98)
Global TB_GETINSERTMARK         := 0x044F ; (WM_USER + 79)       // lParam == LPTBINSERTMARK
Global TB_GETINSERTMARKCOLOR    := 0x0459 ; (WM_USER + 89)
Global TB_GETITEMDROPDOWNRECT   := 0x0467 ; (WM_USER + 103)      >= Vista // Rect of item's drop down button
Global TB_GETITEMRECT           := 0x041D ; (WM_USER + 29)
Global TB_GETMAXSIZE            := 0x0453 ; (WM_USER + 83)       // lParam == LPSIZE
Global TB_GETMETRICS            := 0x0465 ; (WM_USER + 101)
Global TB_GETOBJECT             := 0x043E ; (WM_USER + 62)       // wParam == IID, lParam void **ppv
Global TB_GETPADDING            := 0x0456 ; (WM_USER + 86)
Global TB_GETPRESSEDIMAGELIST   := 0x0469 ; (WM_USER + 105)      >= Vista
Global TB_GETRECT               := 0x0433 ; (WM_USER + 51)       // wParam is the Cmd instead of index
Global TB_GETROWS               := 0x0428 ; (WM_USER + 40)
Global TB_GETSTATE              := 0x0412 ; (WM_USER + 18)
Global TB_GETSTRINGA            := 0x045C ; (WM_USER + 92)
Global TB_GETSTRINGW            := 0x045B ; (WM_USER + 91)
Global TB_GETSTYLE              := 0x0439 ; (WM_USER + 57)
Global TB_GETTEXTROWS           := 0x043D ; (WM_USER + 61)
Global TB_GETTOOLTIPS           := 0x0423 ; (WM_USER + 35)
Global TB_GETUNICODEFORMAT      := 0x2005 ; CCM_GETUNICODEFORMAT
Global TB_HIDEBUTTON            := 0x0404 ; (WM_USER + 4)
Global TB_HITTEST               := 0x0445 ; (WM_USER + 69)
Global TB_INDETERMINATE         := 0x0405 ; (WM_USER + 5)
Global TB_INSERTBUTTONA         := 0x0415 ; (WM_USER + 21)
Global TB_INSERTBUTTONW         := 0x0443 ; (WM_USER + 67)
Global TB_INSERTMARKHITTEST     := 0x0451 ; (WM_USER + 81)       // wParam == LPPOINT lParam == LPTBINSERTMARK
Global TB_ISBUTTONCHECKED       := 0x040A ; (WM_USER + 10)
Global TB_ISBUTTONENABLED       := 0x0409 ; (WM_USER + 9)
Global TB_ISBUTTONHIDDEN        := 0x040C ; (WM_USER + 12)
Global TB_ISBUTTONHIGHLIGHTED   := 0x040E ; (WM_USER + 14)
Global TB_ISBUTTONINDETERMINATE := 0x040D ; (WM_USER + 13)
Global TB_ISBUTTONPRESSED       := 0x040B ; (WM_USER + 11)
Global TB_LOADIMAGES            := 0x0432 ; (WM_USER + 50)
Global TB_MAPACCELERATORA       := 0x044E ; (WM_USER + 78)       // wParam == ch, lParam int * pidBtn
Global TB_MAPACCELERATORW       := 0x045A ; (WM_USER + 90)       // wParam == ch, lParam int * pidBtn
Global TB_MARKBUTTON            := 0x0406 ; (WM_USER + 6)
Global TB_MOVEBUTTON            := 0x0452 ; (WM_USER + 82)
Global TB_PRESSBUTTON           := 0x0403 ; (WM_USER + 3)
Global TB_REPLACEBITMAP         := 0x042E ; (WM_USER + 46)
Global TB_SAVERESTOREA          := 0x041A ; (WM_USER + 26)
Global TB_SAVERESTOREW          := 0x044C ; (WM_USER + 76)
Global TB_SETANCHORHIGHLIGHT    := 0x0449 ; (WM_USER + 73)       // wParam == TRUE/FALSE
Global TB_SETBITMAPSIZE         := 0x0420 ; (WM_USER + 32)
Global TB_SETBUTTONINFOA        := 0x0442 ; (WM_USER + 66)
Global TB_SETBUTTONINFOW        := 0x0440 ; (WM_USER + 64)
Global TB_SETBUTTONSIZE         := 0x041F ; (WM_USER + 31)
Global TB_SETBUTTONWIDTH        := 0x043B ; (WM_USER + 59)
Global TB_SETCMDID              := 0x042A ; (WM_USER + 42)
Global TB_SETCOLORSCHEME        := 0x2002 ; CCM_SETCOLORSCHEME   // lParam is color scheme
Global TB_SETDISABLEDIMAGELIST  := 0x0436 ; (WM_USER + 54)
Global TB_SETDRAWTEXTFLAGS      := 0x0446 ; (WM_USER + 70)       // wParam == mask lParam == bit values
Global TB_SETEXTENDEDSTYLE      := 0x0454 ; (WM_USER + 84)       // For TBSTYLE_EX_*
Global TB_SETHOTIMAGELIST       := 0x0434 ; (WM_USER + 52)
Global TB_SETHOTITEM            := 0x0448 ; (WM_USER + 72)       // wParam == iHotItem
Global TB_SETHOTITEM2           := 0x045E ; (WM_USER + 94)       // wParam == iHotItem,  lParam = dwFlags
Global TB_SETIMAGELIST          := 0x0430 ; (WM_USER + 48)
Global TB_SETINDENT             := 0x042F ; (WM_USER + 47)
Global TB_SETINSERTMARK         := 0x0450 ; (WM_USER + 80)       // lParam == LPTBINSERTMARK
Global TB_SETINSERTMARKCOLOR    := 0x0458 ; (WM_USER + 88)
Global TB_SETLISTGAP            := 0x0460 ; (WM_USER + 96)
Global TB_SETMAXTEXTROWS        := 0x043C ; (WM_USER + 60)
Global TB_SETMETRICS            := 0x0466 ; (WM_USER + 102)
Global TB_SETPADDING            := 0x0457 ; (WM_USER + 87)
Global TB_SETPARENT             := 0x0425 ; (WM_USER + 37)
Global TB_SETPRESSEDIMAGELIST   := 0x0468 ; (WM_USER + 104)      >= Vista
Global TB_SETROWS               := 0x0427 ; (WM_USER + 39)
Global TB_SETSTATE              := 0x0411 ; (WM_USER + 17)
Global TB_SETSTYLE              := 0x0438 ; (WM_USER + 56)
Global TB_SETTOOLTIPS           := 0x0424 ; (WM_USER + 36)
Global TB_SETUNICODEFORMAT      := 0x2004 ; CCM_SETUNICODEFORMAT
Global TB_SETWINDOWTHEME        := 0x200B ; CCM_SETWINDOWTHEME
Global TB_TRANSLATEACCELERATOR  := 0x200A ; ??? -> CCM_TRANSLATEACCELERATOR (not defined !!!)
; Notifications ========================================================================================================
Global TBN_BEGINADJUST     := -703 ; (TBN_FIRST - 3)
Global TBN_BEGINDRAG       := -701 ; (TBN_FIRST - 1)
Global TBN_CUSTHELP        := -709 ; (TBN_FIRST - 9)
Global TBN_DELETINGBUTTON  := -715 ; (TBN_FIRST - 15) // uses TBNOTIFY
Global TBN_DRAGOUT         := -714 ; (TBN_FIRST - 14) // this is sent when the user clicks down on a button then drags off the button
Global TBN_DRAGOVER        := -727 ; (TBN_FIRST - 27)
Global TBN_DROPDOWN        := -710 ; (TBN_FIRST - 10)
Global TBN_DUPACCELERATOR  := -725 ; (TBN_FIRST - 25)
Global TBN_ENDADJUST       := -704 ; (TBN_FIRST - 4)
Global TBN_ENDDRAG         := -702 ; (TBN_FIRST - 2)
Global TBN_GETBUTTONINFOA  := -700 ; (TBN_FIRST - 0)
Global TBN_GETBUTTONINFOW  := -720 ; (TBN_FIRST - 20)
Global TBN_GETDISPINFOA    := -716 ; (TBN_FIRST - 16) // This is sent when the toolbar needs some display information
Global TBN_GETDISPINFOW    := -717 ; (TBN_FIRST - 17) // This is sent when the toolbar needs some display information
Global TBN_GETINFOTIPA     := -718 ; (TBN_FIRST - 18)
Global TBN_GETINFOTIPW     := -719 ; (TBN_FIRST - 19)
Global TBN_GETOBJECT       := -712 ; (TBN_FIRST - 12)
Global TBN_HOTITEMCHANGE   := -713 ; (TBN_FIRST - 13)
Global TBN_INITCUSTOMIZE   := -723 ; (TBN_FIRST - 23)
Global TBN_MAPACCELERATOR  := -728 ; (TBN_FIRST - 28)
Global TBN_QUERYDELETE     := -707 ; (TBN_FIRST - 7)
Global TBN_QUERYINSERT     := -706 ; (TBN_FIRST - 6)
Global TBN_RESET           := -705 ; (TBN_FIRST - 5)
Global TBN_RESTORE         := -721 ; (TBN_FIRST - 21)
Global TBN_SAVE            := -722 ; (TBN_FIRST - 22)
Global TBN_TOOLBARCHANGE   := -708 ; (TBN_FIRST - 8)
Global TBN_WRAPACCELERATOR := -726 ; (TBN_FIRST - 26)
Global TBN_WRAPHOTITEM     := -724 ; (TBN_FIRST - 24)
; Styles ===============================================================================================================
Global TBSTYLE_ALTDRAG      := 0x0400
Global TBSTYLE_CUSTOMERASE  := 0x2000
Global TBSTYLE_FLAT         := 0x0800
Global TBSTYLE_LIST         := 0x1000
Global TBSTYLE_REGISTERDROP := 0x4000
Global TBSTYLE_TOOLTIPS     := 0x0100
Global TBSTYLE_TRANSPARENT  := 0x8000
Global TBSTYLE_WRAPABLE     := 0x0200
; ExStyles =============================================================================================================
Global TBSTYLE_EX_DOUBLEBUFFER       := 0x80 ; // Double Buffer the toolbar
Global TBSTYLE_EX_DRAWDDARROWS       := 0x01
Global TBSTYLE_EX_HIDECLIPPEDBUTTONS := 0x10 ; // don't show partially obscured buttons
Global TBSTYLE_EX_MIXEDBUTTONS       := 0x08
Global TBSTYLE_EX_MULTICOLUMN        := 0x02 ; // Intended for internal use; not recommended for use in applications.
Global TBSTYLE_EX_VERTICAL           := 0x04 ; // Intended for internal use; not recommended for use in applications.
; Button styles ========================================================================================================
Global BTNS_BUTTON        := 0x00 ; TBSTYLE_BUTTON
Global BTNS_SEP           := 0x01 ; TBSTYLE_SEP
Global BTNS_CHECK         := 0x02 ; TBSTYLE_CHECK
Global BTNS_GROUP         := 0x04 ; TBSTYLE_GROUP
Global BTNS_CHECKGROUP    := 0x06 ; TBSTYLE_CHECKGROUP  // (TBSTYLE_GROUP | TBSTYLE_CHECK)
Global BTNS_DROPDOWN      := 0x08 ; TBSTYLE_DROPDOWN
Global BTNS_AUTOSIZE      := 0x10 ; TBSTYLE_AUTOSIZE    // automatically calculate the cx of the button
Global BTNS_NOPREFIX      := 0x20 ; TBSTYLE_NOPREFIX    // this button should not have accel prefix
Global BTNS_SHOWTEXT      := 0x40 ; // ignored unless TBSTYLE_EX_MIXEDBUTTONS is set
Global BTNS_WHOLEDROPDOWN := 0x80 ; // draw drop-down arrow, but without split arrow section
; Button states ========================================================================================================
Global TBSTATE_CHECKED       := 0x01
Global TBSTATE_ELLIPSES      := 0x40
Global TBSTATE_ENABLED       := 0x04
Global TBSTATE_HIDDEN        := 0x08
Global TBSTATE_INDETERMINATE := 0x10
Global TBSTATE_MARKED        := 0x80
Global TBSTATE_PRESSED       := 0x02
Global TBSTATE_WRAP          := 0x20
; Button standard image index values ===================================================================================
; HIST
Global IDB_HIST_SMALL_COLOR := 8
Global IDB_HIST_LARGE_COLOR := 9
Global IDB_HIST_NORMAL      := 12 ; >= Vista
Global IDB_HIST_HOT         := 13 ; >= Vista
Global IDB_HIST_DISABLED    := 14 ; >= Vista
Global IDB_HIST_PRESSED     := 15 ; >= Vista
Global HIST_ADDTOFAVORITES := 3
Global HIST_BACK           := 0
Global HIST_FAVORITES      := 2
Global HIST_FORWARD        := 1
Global HIST_VIEWTREE       := 4
; STD
Global IDB_STD_SMALL_COLOR := 0
Global IDB_STD_LARGE_COLOR := 1
Global STD_COPY            := 1
Global STD_CUT             := 0
Global STD_DELETE          := 5
Global STD_FILENEW         := 6
Global STD_FILEOPEN        := 7
Global STD_FILESAVE        := 8
Global STD_FIND            := 12
Global STD_HELP            := 11
Global STD_PASTE           := 2
Global STD_PRINT           := 14
Global STD_PRINTPRE        := 9
Global STD_PROPERTIES      := 10
Global STD_REDOW           := 4
Global STD_REPLACE         := 13
Global STD_UNDO            := 3
; VIEW
Global IDB_VIEW_SMALL_COLOR := 4
Global IDB_VIEW_LARGE_COLOR := 5
Global VIEW_DETAILS         := 3
Global VIEW_LARGEICONS      := 0
Global VIEW_LIST            := 2
Global VIEW_NETCONNECT      := 9
Global VIEW_NETDISCONNECT   := 10
Global VIEW_NEWFOLDER       := 11
Global VIEW_PARENTFOLDER    := 8
Global VIEW_SMALLICONS      := 1
Global VIEW_SORTDATE        := 6
Global VIEW_SORTNAME        := 4
Global VIEW_SORTSIZE        := 5
Global VIEW_SORTTYPE        := 7
Global VIEW_VIEWMENU        := 12
; Others ===============================================================================================================
; Toolbar custom draw return flags
Global TBCDRF_BLENDICON      := 0x200000 ; // Use ILD_BLEND50 on the icon image
Global TBCDRF_HILITEHOTTRACK := 0x020000 ; // Use color of the button bk when hottracked
Global TBCDRF_NOBACKGROUND   := 0x400000 ; // Use ILD_BLEND50 on the icon image
Global TBCDRF_NOEDGES        := 0x010000 ; // Don't draw button edges
Global TBCDRF_NOETCHEDEFFECT := 0x100000 ; // Don't draw etched effect for disabled items
Global TBCDRF_NOMARK         := 0x080000 ; // Don't draw default highlight of image/text for TBSTATE_MARKED
Global TBCDRF_NOOFFSET       := 0x040000 ; // Don't offset button if pressed
Global TBCDRF_USECDCOLORS    := 0x800000 ; >= Vista // Use CustomDrawColors to RenderText regardless of VisualStyle
; TB_GETINSERTMARK
Global TBIMHT_AFTER      := 0x01 ; // TRUE = insert After iButton, otherwise before
Global TBIMHT_BACKGROUND := 0x02 ; // TRUE iff missed buttons completely
; TB_GETBITMAPFLAGS
Global TBBF_LARGE   := 0x00000001
Global TBIF_BYINDEX := 0x80000000 ; // this specifies that the wparam in Get/SetButtonInfo is an index, not id
Global TBIF_COMMAND := 0x00000020
Global TBIF_IMAGE   := 0x00000001
Global TBIF_LPARAM  := 0x00000010
Global TBIF_SIZE    := 0x00000040
Global TBIF_STATE   := 0x00000004
Global TBIF_STYLE   := 0x00000008
Global TBIF_TEXT    := 0x00000002
; TB_GETMETRICS
Global TBMF_BARPAD        := 0x02
Global TBMF_BUTTONSPACING := 0x04
Global TBMF_PAD           := 0x01
; Hot item change flags
Global HICF_ACCELERATOR    := 0x0004 ; // Triggered by accelerator
Global HICF_ARROWKEYS      := 0x0002 ; // Triggered by arrow keys
Global HICF_DUPACCEL       := 0x0008 ; // This accelerator is not unique
Global HICF_ENTERING       := 0x0010 ; // idOld is invalid
Global HICF_LEAVING        := 0x0020 ; // idNew is invalid
Global HICF_LMOUSE         := 0x0080 ; // left mouse button selected
Global HICF_MOUSE          := 0x0001 ; // Triggered by mouse
Global HICF_OTHER          := 0x0000
Global HICF_RESELECT       := 0x0040 ; // hot item reselected
Global HICF_TOGGLEDROPDOWN := 0x0100 ; // Toggle button's dropdown state
; TBN_INITCUSTOMIZE
Global TBNRF_ENDCUSTOMIZE := 0x02
Global TBNRF_HIDEHELP     := 0x01
; TBN_GET/SETDISPINFO
Global TBNF_DI_SETITEM := 0x10000000
Global TBNF_IMAGE      := 0x00000001
Global TBNF_TEXT       := 0x00000002
; Return codes for TBN_DROPDOWN
Global TBDDRET_DEFAULT      := 0
Global TBDDRET_NODEFAULT    := 1
Global TBDDRET_TREATPRESSED := 2 ; // Treat as a standard press button
; ======================================================================================================================
Edit: Replaced wrong code.
Last edited by just me on 18 Sep 2014, 04:21, edited 1 time in total.
just me
Posts: 7857
Joined: 02 Oct 2013, 08:51
Location: Germany

Re: GUI Constants

13 Sep 2014, 06:12

Const_ToolTip - constants for ToolTip controls.

Code: Select all

; ======================================================================================================================
; Function:         Constants for Tooltip controls
; AHK version:      1.1.05+
; Language:         English
; Version:          1.0.00.00/2012-04-01/just me
; Remarks:          Although not a built-in AHK GUI control it might be useful to create Tooltips for the built-in.
; ======================================================================================================================
; CCM_FIRST = 0x2000
; TTN_FIRST = -520
; WM_USER   = 0x0400
; ======================================================================================================================
; Class ================================================================================================================
Global WC_TOOLTIP          := "tooltips_class32"
; Messages =============================================================================================================
Global TTM_ACTIVATE        := 0x0401 ; (WM_USER + 1)
Global TTM_ADDTOOLA        := 0x0404 ; (WM_USER + 4)
Global TTM_ADDTOOLW        := 0x0432 ; (WM_USER + 50)
Global TTM_ADJUSTRECT      := 0x041F ; (WM_USER + 31)
Global TTM_DELTOOLA        := 0x0405 ; (WM_USER + 5)
Global TTM_DELTOOLW        := 0x0433 ; (WM_USER + 51)
Global TTM_ENUMTOOLSA      := 0x040E ; (WM_USER + 14)
Global TTM_ENUMTOOLSW      := 0x043A ; (WM_USER + 58)
Global TTM_GETBUBBLESIZE   := 0x041E ; (WM_USER + 30)
Global TTM_GETCURRENTTOOLA := 0x040F ; (WM_USER + 15)
Global TTM_GETCURRENTTOOLW := 0x043B ; (WM_USER + 59)
Global TTM_GETDELAYTIME    := 0x0415 ; (WM_USER + 21)
Global TTM_GETMARGIN       := 0x041B ; (WM_USER + 27) lParam = lprc
Global TTM_GETMAXTIPWIDTH  := 0x0419 ; (WM_USER + 25)
Global TTM_GETTEXTA        := 0x040B ; (WM_USER + 11)
Global TTM_GETTEXTW        := 0x0438 ; (WM_USER + 56)
Global TTM_GETTIPBKCOLOR   := 0x0416 ; (WM_USER + 22)
Global TTM_GETTIPTEXTCOLOR := 0x0417 ; (WM_USER + 23)
Global TTM_GETTITLE        := 0x0423 ; (WM_USER + 35) wParam = 0, lParam = TTGETTITLE*
Global TTM_GETTOOLCOUNT    := 0x040D ; (WM_USER + 13)
Global TTM_GETTOOLINFOA    := 0x0408 ; (WM_USER + 8)
Global TTM_GETTOOLINFOW    := 0x0435 ; (WM_USER + 53)
Global TTM_HITTESTA        := 0x040A ; (WM_USER + 10)
Global TTM_HITTESTW        := 0x0437 ; (WM_USER + 55)
Global TTM_NEWTOOLRECTA    := 0x0406 ; (WM_USER + 6)
Global TTM_NEWTOOLRECTW    := 0x0434 ; (WM_USER + 52)
Global TTM_POP             := 0x041C ; (WM_USER + 28)
Global TTM_POPUP           := 0x0422 ; (WM_USER + 34)
Global TTM_RELAYEVENT      := 0x0407 ; (WM_USER + 7)  Win7: wParam = GetMessageExtraInfo() when relaying WM_MOUSEMOVE
Global TTM_SETDELAYTIME    := 0x0403 ; (WM_USER + 3)
Global TTM_SETMARGIN       := 0x041A ; (WM_USER + 26) lParam = lprc
Global TTM_SETMAXTIPWIDTH  := 0x0418 ; (WM_USER + 24)
Global TTM_SETTIPBKCOLOR   := 0x0413 ; (WM_USER + 19)
Global TTM_SETTIPTEXTCOLOR := 0x0414 ; (WM_USER + 20)
Global TTM_SETTITLEA       := 0x0420 ; (WM_USER + 32) wParam = TTI_*, lParam = char* szTitle
Global TTM_SETTITLEW       := 0x0421 ; (WM_USER + 33) wParam = TTI_*, lParam = wchar* szTitle
Global TTM_SETTOOLINFOA    := 0x0409 ; (WM_USER + 9)
Global TTM_SETTOOLINFOW    := 0x0636 ; (WM_USER + 54)
Global TTM_SETWINDOWTHEME  := 0x200B ; (CCM_FIRST + 0xB) CCM_SETWINDOWTHEME
Global TTM_TRACKACTIVATE   := 0x0411 ; (WM_USER + 17) wParam = TRUE/FALSE start end  lparam = LPTOOLINFO
Global TTM_TRACKPOSITION   := 0x0412 ; (WM_USER + 18) lParam = dwPos
Global TTM_UPDATE          := 0x041D ; (WM_USER + 29)
Global TTM_UPDATETIPTEXTA  := 0x040C ; (WM_USER + 12)
Global TTM_UPDATETIPTEXTW  := 0x0439 ; (WM_USER + 57)
Global TTM_WINDOWFROMPOINT := 0x0410 ; (WM_USER + 16)
; Notifications ========================================================================================================
Global TTN_GETDISPINFOA    := -520   ; (TTN_FIRST - 0)
Global TTN_GETDISPINFOW    := -530   ; (TTN_FIRST - 10)
Global TTN_LINKCLICK       := -523   ; (TTN_FIRST - 3)
Global TTN_NEEDTEXTA       := -520   ; TTN_GETDISPINFOA
Global TTN_NEEDTEXTW       := -530   ; TTN_GETDISPINFOW
Global TTN_POP             := -522   ; (TTN_FIRST - 2)
Global TTN_SHOW            := -521   ; (TTN_FIRST - 1)
; Styles ===============================================================================================================
Global TTS_ALWAYSTIP       := 0x0001
Global TTS_BALLOON         := 0x0040
Global TTS_CLOSE           := 0x0080
Global TTS_NOANIMATE       := 0x0010
Global TTS_NOFADE          := 0x0020
Global TTS_NOPREFIX        := 0x0002
Global TTS_USEVISUALSTYLE  := 0x0100   ; >= Vista: use themed hyperlinks
; Others ===============================================================================================================
; TOOLINFO uFlags
; Use TTF_CENTERTIP to center around trackpoint in trackmode -OR- to center around tool in normal mode.
; Use TTF_ABSOLUTE to place the tip exactly at the track coords when in tracking mode.
; TTF_ABSOLUTE can be used in conjunction with TTF_CENTERTIP to center the tip absolutely about the track point.
Global TTF_ABSOLUTE        := 0x0080
Global TTF_CENTERTIP       := 0x0002
Global TTF_DI_SETITEM      := 0x8000 ; valid only on the TTN_NEEDTEXT callback
Global TTF_IDISHWND        := 0x0001
Global TTF_PARSELINKS      := 0x1000
Global TTF_RTLREADING      := 0x0004
Global TTF_SUBCLASS        := 0x0010
Global TTF_TRACK           := 0x0020
Global TTF_TRANSPARENT     := 0x0100
; TTMSETDELAYTIME
Global TTDT_AUTOMATIC      := 0
Global TTDT_AUTOPOP        := 2
Global TTDT_INITIAL        := 3
Global TTDT_RESHOW         := 1
; TTM_SETTITLE Tooltip icons
Global TTI_ERROR           := 3
Global TTI_ERROR_LARGE     := 6      ; >= Vista
Global TTI_INFO            := 1
Global TTI_INFO_LARGE      := 4      ; >= Vista
Global TTI_NONE            := 0
Global TTI_WARNING         := 2
Global TTI_WARNING_LARGE   := 5      ; >= Vista
; ======================================================================================================================
just me
Posts: 7857
Joined: 02 Oct 2013, 08:51
Location: Germany

Re: GUI Constants

13 Sep 2014, 06:13

Const_Trackbar - constants for Slider controls.

Code: Select all

; ======================================================================================================================
; Function:         Constants for Trackbar controls (Slider)
; AHK version:      1.1.05 +
; Language:         English
; Version:          1.0.00.00/2012-04-01/just me
; ======================================================================================================================
; CCM_FIRST  = 0x2000
; TRBN_FIRST = -1501    ; trackbar (>= Vista)
; WM_USER    = 0x0400
; Class ================================================================================================================
Global WC_TRACKBAR             := "msctls_trackbar32"
; Messages =============================================================================================================
Global TBM_CLEARSEL            := 0x0413   ; (WM_USER + 19)
Global TBM_CLEARTICS           := 0x0409   ; (WM_USER + 9)
Global TBM_GETBUDDY            := 0x0421   ; (WM_USER + 33)    ; wparam = BOOL fLeft (or right)
Global TBM_GETCHANNELRECT      := 0x041A   ; (WM_USER + 26)
Global TBM_GETLINESIZE         := 0x0418   ; (WM_USER + 24)
Global TBM_GETNUMTICS          := 0x0410   ; (WM_USER + 16)
Global TBM_GETPAGESIZE         := 0x0416   ; (WM_USER + 22)
Global TBM_GETPOS              := 0x0400   ; (WM_USER)
Global TBM_GETPTICS            := 0x040E   ; (WM_USER + 14)
Global TBM_GETRANGEMAX         := 0x0402   ; (WM_USER + 2)
Global TBM_GETRANGEMIN         := 0x0401   ; (WM_USER + 1)
Global TBM_GETSELEND           := 0x0412   ; (WM_USER + 18)
Global TBM_GETSELSTART         := 0x0411   ; (WM_USER + 17)
Global TBM_GETTHUMBLENGTH      := 0x041C   ; (WM_USER + 28)
Global TBM_GETTHUMBRECT        := 0x0419   ; (WM_USER + 25)
Global TBM_GETTIC              := 0x0403   ; (WM_USER + 3)
Global TBM_GETTICPOS           := 0x040F   ; (WM_USER + 15)
Global TBM_GETTOOLTIPS         := 0x041E   ; (WM_USER + 30)
Global TBM_GETUNICODEFORMAT    := 0x2006   ; (CCM_FIRST + 6)   ; CCM_GETUNICODEFORMAT
Global TBM_SETBUDDY            := 0x0420   ; (WM_USER + 32)    ; wparam = BOOL fLeft (or right)
Global TBM_SETLINESIZE         := 0x0417   ; (WM_USER + 23)
Global TBM_SETPAGESIZE         := 0x0415   ; (WM_USER + 21)
Global TBM_SETPOS              := 0x0405   ; (WM_USER + 5)
Global TBM_SETPOSNOTIFY        := 0x0422   ; (WM_USER + 34)
Global TBM_SETRANGE            := 0x0406   ; (WM_USER + 6)
Global TBM_SETRANGEMAX         := 0x0408   ; (WM_USER + 8)
Global TBM_SETRANGEMIN         := 0x0407   ; (WM_USER + 7)
Global TBM_SETSEL              := 0x040A   ; (WM_USER + 10)
Global TBM_SETSELEND           := 0x040C   ; (WM_USER + 12)
Global TBM_SETSELSTART         := 0x040B   ; (WM_USER + 11)
Global TBM_SETTHUMBLENGTH      := 0x041B   ; (WM_USER + 27)
Global TBM_SETTIC              := 0x0404   ; (WM_USER + 4)
Global TBM_SETTICFREQ          := 0x0414   ; (WM_USER + 20)
Global TBM_SETTIPSIDE          := 0x041F   ; (WM_USER + 31)
Global TBM_SETTOOLTIPS         := 0x041D   ; (WM_USER + 29)
Global TBM_SETUNICODEFORMAT    := 0x2005   ; (CCM_FIRST + 5)   ; CCM_SETUNICODEFORMAT
; Notifications ========================================================================================================
Global TRBN_THUMBPOSCHANGING   := -1502    ; (TRBN_FIRST-1)    ; >= Vista
; Styles ===============================================================================================================
Global TBS_AUTOTICKS           := 0x0001
Global TBS_BOTH                := 0x0008
Global TBS_BOTTOM              := 0x0000
Global TBS_DOWNISLEFT          := 0x0400  ; Down=Left and Up=Right (default is Down=Right and Up=Left)
Global TBS_ENABLESELRANGE      := 0x0020
Global TBS_FIXEDLENGTH         := 0x0040
Global TBS_HORZ                := 0x0000
Global TBS_LEFT                := 0x0004
Global TBS_NOTHUMB             := 0x0080
Global TBS_NOTICKS             := 0x0010
Global TBS_NOTIFYBEFOREMOVE    := 0x0800  ; >= Vista : Trackbar should notify parent before repositioning the slider
;                                           due touser action (enables snapping)
Global TBS_REVERSED            := 0x0200  ; Accessibility hint: the smaller number (usually the min value) means "high"
;                                           andthe larger number (usually the max value) means "low"
Global TBS_RIGHT               := 0x0000
Global TBS_TOOLTIPS            := 0x0100
Global TBS_TOP                 := 0x0004
Global TBS_TRANSPARENTBKGND    := 0x1000  ; >= Vista : Background is painted by the parent via WM_PRINTCLIENT
Global TBS_VERT                := 0x0002
; Others ===============================================================================================================
; Custom draw item specs
Global TBCD_CHANNEL            := 0x0003
Global TBCD_THUMB              := 0x0002
Global TBCD_TICS               := 0x0001
; Interaction notification codes
Global TB_BOTTOM               := 7
Global TB_ENDTRACK             := 8
Global TB_LINEDOWN             := 1
Global TB_LINEUP               := 0
Global TB_PAGEDOWN             := 3
Global TB_PAGEUP               := 2
Global TB_THUMBPOSITION        := 4
Global TB_THUMBTRACK           := 5
Global TB_TOP                  := 6
; ======================================================================================================================
just me
Posts: 7857
Joined: 02 Oct 2013, 08:51
Location: Germany

Re: GUI Constants

13 Sep 2014, 06:14

Const_TreeView - constants for TreeView controls.

Code: Select all

; ======================================================================================================================
; Function:         Constants for TreeView controls
; AHK version:      1.1.05+
; Language:         English
; Version:          1.0.00.00/2012-04-01/just me
; ======================================================================================================================
; CCM_FIRST = 0x2000
; TV_FIRST  = 0x1100
; TVN_FIRST = -400
; ======================================================================================================================
; Class ================================================================================================================
Global WC_TREEVIEW             := "SysTreeView32"
; Messages =============================================================================================================
Global TVM_CREATEDRAGIMAGE     := 0x1112 ; (TV_FIRST + 18)
Global TVM_DELETEITEM          := 0x1101 ; (TV_FIRST + 1)
Global TVM_EDITLABELA          := 0x110E ; (TV_FIRST + 14)
Global TVM_EDITLABELW          := 0x1141 ; (TV_FIRST + 65)
Global TVM_ENDEDITLABELNOW     := 0x1116 ; (TV_FIRST + 22)
Global TVM_ENSUREVISIBLE       := 0x1114 ; (TV_FIRST + 20)
Global TVM_EXPAND              := 0x1102 ; (TV_FIRST + 2)
Global TVM_GETBKCOLOR          := 0x112F ; (TV_FIRST + 31)
Global TVM_GETCOUNT            := 0x1105 ; (TV_FIRST + 5)
Global TVM_GETEDITCONTROL      := 0x110F ; (TV_FIRST + 15)
Global TVM_GETEXTENDEDSTYLE    := 0x112D ; (TV_FIRST + 45)
Global TVM_GETIMAGELIST        := 0x1108 ; (TV_FIRST + 8)
Global TVM_GETINDENT           := 0x1106 ; (TV_FIRST + 6)
Global TVM_GETINSERTMARKCOLOR  := 0x1126 ; (TV_FIRST + 38)
Global TVM_GETISEARCHSTRINGA   := 0x1117 ; (TV_FIRST + 23)
Global TVM_GETISEARCHSTRINGW   := 0x1140 ; (TV_FIRST + 64)
Global TVM_GETITEMA            := 0x110C ; (TV_FIRST + 12)
Global TVM_GETITEMHEIGHT       := 0x111C ; (TV_FIRST + 28)
Global TVM_GETITEMPARTRECT     := 0x1148 ; (TV_FIRST + 72) ; >= Vista
Global TVM_GETITEMRECT         := 0x1104 ; (TV_FIRST + 4)
Global TVM_GETITEMSTATE        := 0x1127 ; (TV_FIRST + 39)
Global TVM_GETITEMW            := 0x113E ; (TV_FIRST + 62)
Global TVM_GETLINECOLOR        := 0x1129 ; (TV_FIRST + 41)
Global TVM_GETNEXTITEM         := 0x110A ; (TV_FIRST + 10)
Global TVM_GETSCROLLTIME       := 0x1122 ; (TV_FIRST + 34)
Global TVM_GETSELECTEDCOUNT    := 0x1146 ; (TV_FIRST + 70) ; >= Vista
Global TVM_GETTEXTCOLOR        := 0x1120 ; (TV_FIRST + 32)
Global TVM_GETTOOLTIPS         := 0x1119 ; (TV_FIRST + 25)
Global TVM_GETUNICODEFORMAT    := 0x2006 ; (CCM_FIRST + 6) CCM_GETUNICODEFORMAT
Global TVM_GETVISIBLECOUNT     := 0x1110 ; (TV_FIRST + 16)
Global TVM_HITTEST             := 0x1111 ; (TV_FIRST + 17)
Global TVM_INSERTITEMA         := 0x1100 ; (TV_FIRST + 0)
Global TVM_INSERTITEMW         := 0x1142 ; (TV_FIRST + 50)
Global TVM_MAPACCIDTOHTREEITEM := 0x112A ; (TV_FIRST + 42)
Global TVM_MAPHTREEITEMTOACCID := 0x112B ; (TV_FIRST + 43)
Global TVM_SELECTITEM          := 0x110B ; (TV_FIRST + 11)
Global TVM_SETAUTOSCROLLINFO   := 0x113B ; (TV_FIRST + 59)
Global TVM_SETBKCOLOR          := 0x111D ; (TV_FIRST + 29)
Global TVM_SETEXTENDEDSTYLE    := 0x112C ; (TV_FIRST + 44)
Global TVM_SETIMAGELIST        := 0x1109 ; (TV_FIRST + 9)
Global TVM_SETINDENT           := 0x1107 ; (TV_FIRST + 7)
Global TVM_SETINSERTMARK       := 0x111A ; (TV_FIRST + 26)
Global TVM_SETINSERTMARKCOLOR  := 0x1125 ; (TV_FIRST + 37)
Global TVM_SETITEMA            := 0x110D ; (TV_FIRST + 13)
Global TVM_SETITEMHEIGHT       := 0x111B ; (TV_FIRST + 27)
Global TVM_SETITEMW            := 0x113F ; (TV_FIRST + 63)
Global TVM_SETLINECOLOR        := 0x1128 ; (TV_FIRST + 40)
Global TVM_SETSCROLLTIME       := 0x1121 ; (TV_FIRST + 33)
Global TVM_SETTEXTCOLOR        := 0x111E ; (TV_FIRST + 30)
Global TVM_SETTOOLTIPS         := 0x1118 ; (TV_FIRST + 24)
Global TVM_SETUNICODEFORMAT    := 0x2005 ; (CCM_FIRST + 5) ; CCM_SETUNICODEFORMAT
Global TVM_SHOWINFOTIP         := 0x1147 ; (TV_FIRST + 71) ; >= Vista
Global TVM_SORTCHILDREN        := 0x1113 ; (TV_FIRST + 19)
Global TVM_SORTCHILDRENCB      := 0x1115 ; (TV_FIRST + 21)
; Notifications ========================================================================================================
Global TVN_ASYNCDRAW           := -420 ; (TVN_FIRST - 20) >= Vista
Global TVN_BEGINDRAGA          := -407 ; (TVN_FIRST - 7)
Global TVN_BEGINDRAGW          := -456 ; (TVN_FIRST - 56)
Global TVN_BEGINLABELEDITA     := -410 ; (TVN_FIRST - 10)
Global TVN_BEGINLABELEDITW     := -456 ; (TVN_FIRST - 59)
Global TVN_BEGINRDRAGA         := -408 ; (TVN_FIRST - 8)
Global TVN_BEGINRDRAGW         := -457 ; (TVN_FIRST - 57)
Global TVN_DELETEITEMA         := -409 ; (TVN_FIRST - 9)
Global TVN_DELETEITEMW         := -458 ; (TVN_FIRST - 58)
Global TVN_ENDLABELEDITA       := -411 ; (TVN_FIRST - 11)
Global TVN_ENDLABELEDITW       := -460 ; (TVN_FIRST - 60)
Global TVN_GETDISPINFOA        := -403 ; (TVN_FIRST - 3)
Global TVN_GETDISPINFOW        := -452 ; (TVN_FIRST - 52)
Global TVN_GETINFOTIPA         := -412 ; (TVN_FIRST - 13)
Global TVN_GETINFOTIPW         := -414 ; (TVN_FIRST - 14)
Global TVN_ITEMCHANGEDA        := -418 ; (TVN_FIRST - 18) ; >= Vista
Global TVN_ITEMCHANGEDW        := -419 ; (TVN_FIRST - 19) ; >= Vista
Global TVN_ITEMCHANGINGA       := -416 ; (TVN_FIRST - 16) ; >= Vista
Global TVN_ITEMCHANGINGW       := -417 ; (TVN_FIRST - 17) ; >= Vista
Global TVN_ITEMEXPANDEDA       := -406 ; (TVN_FIRST - 6)
Global TVN_ITEMEXPANDEDW       := -455 ; (TVN_FIRST - 55)
Global TVN_ITEMEXPANDINGA      := -405 ; (TVN_FIRST - 5)
Global TVN_ITEMEXPANDINGW      := -454 ; (TVN_FIRST - 54)
Global TVN_KEYDOWN             := -412 ; (TVN_FIRST - 12)
Global TVN_SELCHANGEDA         := -402 ; (TVN_FIRST - 2)
Global TVN_SELCHANGEDW         := -451 ; (TVN_FIRST - 51)
Global TVN_SELCHANGINGA        := -401 ; (TVN_FIRST - 1)
Global TVN_SELCHANGINGW        := -450 ; (TVN_FIRST - 50)
Global TVN_SETDISPINFOA        := -404 ; (TVN_FIRST - 4)
Global TVN_SETDISPINFOW        := -453 ; (TVN_FIRST - 53)
Global TVN_SINGLEEXPAND        := -415 ; (TVN_FIRST - 15)
; Styles ===============================================================================================================
Global TVS_CHECKBOXES          := 0x0100
Global TVS_DISABLEDRAGDROP     := 0x0010
Global TVS_EDITLABELS          := 0x0008
Global TVS_FULLROWSELECT       := 0x1000
Global TVS_HASBUTTONS          := 0x0001
Global TVS_HASLINES            := 0x0002
Global TVS_INFOTIP             := 0x0800
Global TVS_LINESATROOT         := 0x0004
Global TVS_NOHSCROLL           := 0x8000 ; TVS_NOSCROLL overrides this
Global TVS_NONEVENHEIGHT       := 0x4000
Global TVS_NOSCROLL            := 0x2000
Global TVS_NOTOOLTIPS          := 0x0080
Global TVS_RTLREADING          := 0x0040
Global TVS_SHOWSELALWAYS       := 0x0020
Global TVS_SINGLEEXPAND        := 0x0400
Global TVS_TRACKSELECT         := 0x0200
; Exstyles =============================================================================================================
Global TVS_EX_AUTOHSCROLL         := 0x0020 ; >= Vista
Global TVS_EX_DIMMEDCHECKBOXES    := 0x0200 ; >= Vista
Global TVS_EX_DOUBLEBUFFER        := 0x0004 ; >= Vista
Global TVS_EX_DRAWIMAGEASYNC      := 0x0400 ; >= Vista
Global TVS_EX_EXCLUSIONCHECKBOXES := 0x0100 ; >= Vista
Global TVS_EX_FADEINOUTEXPANDOS   := 0x0040 ; >= Vista
Global TVS_EX_MULTISELECT         := 0x0002 ; >= Vista - Not supported. Do not use.
Global TVS_EX_NOINDENTSTATE       := 0x0008 ; >= Vista
Global TVS_EX_NOSINGLECOLLAPSE    := 0x0001 ; >= Vista - Intended for internal use; not recommended for use in applications.
Global TVS_EX_PARTIALCHECKBOXES   := 0x0080 ; >= Vista
Global TVS_EX_RICHTOOLTIP         := 0x0010 ; >= Vista
; Others ===============================================================================================================
; Item flags
Global TVIF_CHILDREN           := 0x0040
Global TVIF_DI_SETITEM         := 0x1000
Global TVIF_EXPANDEDIMAGE      := 0x0200 ; >= Vista
Global TVIF_HANDLE             := 0x0010
Global TVIF_IMAGE              := 0x0002
Global TVIF_INTEGRAL           := 0x0080
Global TVIF_PARAM              := 0x0004
Global TVIF_SELECTEDIMAGE      := 0x0020
Global TVIF_STATE              := 0x0008
Global TVIF_STATEEX            := 0x0100 ; >= Vista
Global TVIF_TEXT               := 0x0001
; Item states
Global TVIS_BOLD               := 0x0010
Global TVIS_CUT                := 0x0004
Global TVIS_DROPHILITED        := 0x0008
Global TVIS_EXPANDED           := 0x0020
Global TVIS_EXPANDEDONCE       := 0x0040
Global TVIS_EXPANDPARTIAL      := 0x0080
Global TVIS_OVERLAYMASK        := 0x0F00
Global TVIS_SELECTED           := 0x0002
Global TVIS_STATEIMAGEMASK     := 0xF000
Global TVIS_USERMASK           := 0xF000
; TVITEMEX uStateEx
Global TVIS_EX_ALL             := 0x0002 ; not documented
Global TVIS_EX_DISABLED        := 0x0002 ; >= Vista
Global TVIS_EX_FLAT            := 0x0001
; TVINSERTSTRUCT hInsertAfter
Global TVI_FIRST               := -65535 ; (-0x0FFFF)
Global TVI_LAST                := -65534 ; (-0x0FFFE)
Global TVI_ROOT                := -65536 ; (-0x10000)
Global TVI_SORT                := -65533 ; (-0x0FFFD)
; TVM_EXPAND wParam
Global TVE_COLLAPSE            := 0x0001
Global TVE_COLLAPSERESET       := 0x8000
Global TVE_EXPAND              := 0x0002
Global TVE_EXPANDPARTIAL       := 0x4000
Global TVE_TOGGLE              := 0x0003
; TVM_GETIMAGELIST wParam
Global TVSIL_NORMAL            := 0
Global TVSIL_STATE             := 2
; TVM_GETNEXTITEM wParam
Global TVGN_CARET              := 0x0009
Global TVGN_CHILD              := 0x0004
Global TVGN_DROPHILITE         := 0x0008
Global TVGN_FIRSTVISIBLE       := 0x0005
Global TVGN_LASTVISIBLE        := 0x000A
Global TVGN_NEXT               := 0x0001
Global TVGN_NEXTSELECTED       := 0x000B ; >= Vista (MSDN)     
Global TVGN_NEXTVISIBLE        := 0x0006
Global TVGN_PARENT             := 0x0003
Global TVGN_PREVIOUS           := 0x0002
Global TVGN_PREVIOUSVISIBLE    := 0x0007
Global TVGN_ROOT               := 0x0000
; TVM_SELECTITEM wParam
Global TVSI_NOSINGLEEXPAND     := 0x8000 ; Should not conflict with TVGN flags.
; TVHITTESTINFO flags
Global TVHT_ABOVE              := 0x0100
Global TVHT_BELOW              := 0x0200
Global TVHT_NOWHERE            := 0x0001
Global TVHT_ONITEMBUTTON       := 0x0010
Global TVHT_ONITEMICON         := 0x0002
Global TVHT_ONITEMINDENT       := 0x0008
Global TVHT_ONITEMLABEL        := 0x0004
Global TVHT_ONITEMRIGHT        := 0x0020
Global TVHT_ONITEMSTATEICON    := 0x0040
Global TVHT_TOLEFT             := 0x0800
Global TVHT_TORIGHT            := 0x0400
Global TVHT_ONITEM             := 0x0046 ; (TVHT_ONITEMICON | TVHT_ONITEMLABEL | TVHT_ONITEMSTATEICON)
; TVGETITEMPARTRECTINFO partID (>= Vista)
Global TVGIPR_BUTTON           := 0x0001
; NMTREEVIEW action
Global TVC_BYKEYBOARD          := 0x0002
Global TVC_BYMOUSE             := 0x0001
Global TVC_UNKNOWN             := 0x0000
; TVN_SINGLEEXPAND return codes
Global TVNRET_DEFAULT          := 0
Global TVNRET_SKIPOLD          := 1
Global TVNRET_SKIPNEW          := 2
; ======================================================================================================================
just me
Posts: 7857
Joined: 02 Oct 2013, 08:51
Location: Germany

Re: GUI Constants

13 Sep 2014, 06:16

Const_UpDown - constants for UpDown controls.

Code: Select all

; ======================================================================================================================
; Function:         Constants for UpDown controls
; AHK version:      1.1.05+
; Language:         English
; Version:          1.0.00.00/2012-04-01/just me
; ======================================================================================================================
; WM_USER   = 0x400
; CCM_FIRST = 0x2000
; UDN_FIRST = -721
; ======================================================================================================================
; Class ================================================================================================================
Global WC_UPDOWN            := "msctls_updown32"
; Messages =============================================================================================================
Global UDM_GETACCEL         := 0x046C ; (WM_USER + 108)
Global UDM_GETBASE          := 0x046E ; (WM_USER + 110)
Global UDM_GETBUDDY         := 0x046A ; (WM_USER + 106)
Global UDM_GETPOS           := 0x0468 ; (WM_USER + 104)
Global UDM_GETPOS32         := 0x0472 ; (WM_USER + 114)
Global UDM_GETRANGE         := 0x0466 ; (WM_USER + 102)
Global UDM_GETRANGE32       := 0x0470 ; (WM_USER + 112) wParam & lParam are LPINT
Global UDM_GETUNICODEFORMAT := 0x2006 ; (CCM_FIRST + 6) CCM_GETUNICODEFORMAT
Global UDM_SETACCEL         := 0x046B ; (WM_USER + 107)
Global UDM_SETBASE          := 0x046D ; (WM_USER + 109)
Global UDM_SETBUDDY         := 0x0469 ; (WM_USER + 105)
Global UDM_SETPOS           := 0x0467 ; (WM_USER + 103)
Global UDM_SETPOS32         := 0x0471 ; (WM_USER + 113)
Global UDM_SETRANGE         := 0x0465 ; (WM_USER + 101)
Global UDM_SETRANGE32       := 0x046F ; (WM_USER + 111)
Global UDM_SETUNICODEFORMAT := 0x2005 ; (CCM_FIRST + 5) CCM_SETUNICODEFORMAT
; Notifications ========================================================================================================
Global UDN_DELTAPOS         := -722   ; (UDN_FIRST - 1)
; Styles ===============================================================================================================
Global UDS_ALIGNLEFT        := 0x0008
Global UDS_ALIGNRIGHT       := 0x0004
Global UDS_ARROWKEYS        := 0x0020
Global UDS_AUTOBUDDY        := 0x0010
Global UDS_HORZ             := 0x0040
Global UDS_HOTTRACK         := 0x0100
Global UDS_NOTHOUSANDS      := 0x0080
Global UDS_SETBUDDYINT      := 0x0002
Global UDS_WRAP             := 0x0001
; ======================================================================================================================
just me
Posts: 7857
Joined: 02 Oct 2013, 08:51
Location: Germany

Re: GUI Constants

13 Sep 2014, 06:20

Const_Windows - some common constants for windows.

Code: Select all

; ======================================================================================================================
; Function:         Constants for Windows
; AHK version:      1.1.05+
; Language:         English
; Version:          1.0.00.00/2012-04-01/just me
; Remarks:          Only messages, styles and exstyles are included here, otherwise I wouldn't know, where to stop.
; ======================================================================================================================
; Messages / notifications =============================================================================================
Global MN_GETHMENU                := 0x01E1
Global WM_ACTIVATE                := 0x0006
Global WM_ACTIVATEAPP             := 0x001C
Global WM_AFXFIRST                := 0x0360
Global WM_AFXLAST                 := 0x037F
Global WM_APP                     := 0x8000
Global WM_APPCOMMAND              := 0x0319
Global WM_ASKCBFORMATNAME         := 0x030C
Global WM_CANCELMODE              := 0x001F
Global WM_CAPTURECHANGED          := 0x0215
Global WM_CHANGECBCHAIN           := 0x030D
Global WM_CHANGEUISTATE           := 0x0127
Global WM_CHAR                    := 0x0102
Global WM_CHARTOITEM              := 0x002F
Global WM_CHILDACTIVATE           := 0x0022
Global WM_CLEAR                   := 0x0303
Global WM_CLIPBOARDUPDATE         := 0x031D
Global WM_CLOSE                   := 0x0010
Global WM_COMMAND                 := 0x0111
Global WM_COMMNOTIFY              := 0x0044 ; no longer suported
Global WM_COMPACTING              := 0x0041
Global WM_COMPAREITEM             := 0x0039
Global WM_CONTEXTMENU             := 0x007B
Global WM_COPY                    := 0x0301
Global WM_CREATE                  := 0x0001
Global WM_CTLCOLORBTN             := 0x0135
Global WM_CTLCOLORDLG             := 0x0136
Global WM_CTLCOLOREDIT            := 0x0133
Global WM_CTLCOLORLISTBOX         := 0x0134
Global WM_CTLCOLORMSGBOX          := 0x0132
Global WM_CTLCOLORSCROLLBAR       := 0x0137
Global WM_CTLCOLORSTATIC          := 0x0138
Global WM_CUT                     := 0x0300
Global WM_DEADCHAR                := 0x0103
Global WM_DELETEITEM              := 0x002D
Global WM_DESTROY                 := 0x0002
Global WM_DESTROYCLIPBOARD        := 0x0307
Global WM_DEVICECHANGE            := 0x0219
Global WM_DEVMODECHANGE           := 0x001B
Global WM_DISPLAYCHANGE           := 0x007E
Global WM_DRAWCLIPBOARD           := 0x0308
Global WM_DRAWITEM                := 0x002B
Global WM_DROPFILES               := 0x0233
Global WM_DWMCOLORIZATIONCOLORCHANGED    := 0x0320 ; >= Vista
Global WM_DWMCOMPOSITIONCHANGED          := 0x031E ; >= Vista
Global WM_DWMNCRENDERINGCHANGED          := 0x031F ; >= Vista
Global WM_DWMSENDICONICLIVEPREVIEWBITMAP := 0x0326 ; >= Win 7
Global WM_DWMSENDICONICTHUMBNAIL         := 0x0323 ; >= Win 7
Global WM_DWMWINDOWMAXIMIZEDCHANGE       := 0x0321 ; >= Vista
Global WM_ENABLE                  := 0x000A
Global WM_ENDSESSION              := 0x0016
Global WM_ENTERIDLE               := 0x0121
Global WM_ENTERMENULOOP           := 0x0211
Global WM_ENTERSIZEMOVE           := 0x0231
Global WM_ERASEBKGND              := 0x0014
Global WM_EXITMENULOOP            := 0x0212
Global WM_EXITSIZEMOVE            := 0x0232
Global WM_FONTCHANGE              := 0x001D
Global WM_GESTURE                 := 0x0119 ; >= Win 7
Global WM_GESTURENOTIFY           := 0x011A ; >= Win 7
Global WM_GETDLGCODE              := 0x0087
Global WM_GETFONT                 := 0x0031
Global WM_GETHOTKEY               := 0x0033
Global WM_GETICON                 := 0x007F
Global WM_GETMINMAXINFO           := 0x0024
Global WM_GETOBJECT               := 0x003D
Global WM_GETTEXT                 := 0x000D
Global WM_GETTEXTLENGTH           := 0x000E
Global WM_GETTITLEBARINFOEX       := 0x033F ; >= Vista
Global WM_HANDHELDFIRST           := 0x0358
Global WM_HANDHELDLAST            := 0x035F
Global WM_HELP                    := 0x0053
Global WM_HOTKEY                  := 0x0312
Global WM_HSCROLL                 := 0x0114
Global WM_HSCROLLCLIPBOARD        := 0x030E
Global WM_ICONERASEBKGND          := 0x0027
Global WM_IME_CHAR                := 0x0286
Global WM_IME_COMPOSITION         := 0x010F
Global WM_IME_COMPOSITIONFULL     := 0x0284
Global WM_IME_CONTROL             := 0x0283
Global WM_IME_ENDCOMPOSITION      := 0x010E
Global WM_IME_KEYDOWN             := 0x0290
Global WM_IME_KEYLAST             := 0x010F
Global WM_IME_KEYUP               := 0x0291
Global WM_IME_NOTIFY              := 0x0282
Global WM_IME_REQUEST             := 0x0288
Global WM_IME_SELECT              := 0x0285
Global WM_IME_SETCONTEXT          := 0x0281
Global WM_IME_STARTCOMPOSITION    := 0x010D
Global WM_INITDIALOG              := 0x0110
Global WM_INITMENU                := 0x0116
Global WM_INITMENUPOPUP           := 0x0117
Global WM_INPUT                   := 0x00FF
Global WM_INPUT_DEVICE_CHANGE     := 0x00FE
Global WM_INPUTLANGCHANGE         := 0x0051
Global WM_INPUTLANGCHANGEREQUEST  := 0x0050
Global WM_KEYDOWN                 := 0x0100
Global WM_KEYLAST                 := 0x0109
Global WM_KEYUP                   := 0x0101
Global WM_KILLFOCUS               := 0x0008
Global WM_LBUTTONDBLCLK           := 0x0203
Global WM_LBUTTONDOWN             := 0x0201
Global WM_LBUTTONUP               := 0x0202
Global WM_MBUTTONDBLCLK           := 0x0209
Global WM_MBUTTONDOWN             := 0x0207
Global WM_MBUTTONUP               := 0x0208
Global WM_MDIACTIVATE             := 0x0222
Global WM_MDICASCADE              := 0x0227
Global WM_MDICREATE               := 0x0220
Global WM_MDIDESTROY              := 0x0221
Global WM_MDIGETACTIVE            := 0x0229
Global WM_MDIICONARRANGE          := 0x0228
Global WM_MDIMAXIMIZE             := 0x0225
Global WM_MDINEXT                 := 0x0224
Global WM_MDIREFRESHMENU          := 0x0234
Global WM_MDIRESTORE              := 0x0223
Global WM_MDISETMENU              := 0x0230
Global WM_MDITILE                 := 0x0226
Global WM_MEASUREITEM             := 0x002C
Global WM_MENUCHAR                := 0x0120
Global WM_MENUCOMMAND             := 0x0126
Global WM_MENUDRAG                := 0x0123
Global WM_MENUGETOBJECT           := 0x0124
Global WM_MENURBUTTONUP           := 0x0122
Global WM_MENUSELECT              := 0x011F
Global WM_MOUSEACTIVATE           := 0x0021
Global WM_MOUSEHOVER              := 0x02A1
Global WM_MOUSEHWHEEL             := 0x020E ; >= Vista
Global WM_MOUSELEAVE              := 0x02A3
Global WM_MOUSEMOVE               := 0x0200
Global WM_MOUSEWHEEL              := 0x020A
Global WM_MOVE                    := 0x0003
Global WM_MOVING                  := 0x0216
Global WM_NCACTIVATE              := 0x0086
Global WM_NCCALCSIZE              := 0x0083
Global WM_NCCREATE                := 0x0081
Global WM_NCDESTROY               := 0x0082
Global WM_NCHITTEST               := 0x0084
Global WM_NCLBUTTONDBLCLK         := 0x00A3
Global WM_NCLBUTTONDOWN           := 0x00A1
Global WM_NCLBUTTONUP             := 0x00A2
Global WM_NCMBUTTONDBLCLK         := 0x00A9
Global WM_NCMBUTTONDOWN           := 0x00A7
Global WM_NCMBUTTONUP             := 0x00A8
Global WM_NCMOUSEHOVER            := 0x02A0
Global WM_NCMOUSELEAVE            := 0x02A2
Global WM_NCMOUSEMOVE             := 0x00A0
Global WM_NCPAINT                 := 0x0085
Global WM_NCRBUTTONDBLCLK         := 0x00A6
Global WM_NCRBUTTONDOWN           := 0x00A4
Global WM_NCRBUTTONUP             := 0x00A5
Global WM_NCXBUTTONDBLCLK         := 0x00AD
Global WM_NCXBUTTONDOWN           := 0x00AB
Global WM_NCXBUTTONUP             := 0x00AC
Global WM_NEXTDLGCTL              := 0x0028
Global WM_NEXTMENU                := 0x0213
Global WM_NOTIFY                  := 0x004E
Global WM_NOTIFYFORMAT            := 0x0055
Global WM_NULL                    := 0x0000
Global WM_PAINT                   := 0x000F
Global WM_PAINTCLIPBOARD          := 0x0309
Global WM_PAINTICON               := 0x0026
Global WM_PALETTECHANGED          := 0x0311
Global WM_PALETTEISCHANGING       := 0x0310
Global WM_PARENTNOTIFY            := 0x0210
Global WM_PASTE                   := 0x0302
Global WM_PENWINFIRST             := 0x0380
Global WM_PENWINLAST              := 0x038F
Global WM_POWER                   := 0x0048
Global WM_POWERBROADCAST          := 0x0218
Global WM_PRINT                   := 0x0317
Global WM_PRINTCLIENT             := 0x0318
Global WM_QUERYDRAGICON           := 0x0037
Global WM_QUERYENDSESSION         := 0x0011
Global WM_QUERYNEWPALETTE         := 0x030F
Global WM_QUERYOPEN               := 0x0013
Global WM_QUERYUISTATE            := 0x0129
Global WM_QUEUESYNC               := 0x0023
Global WM_QUIT                    := 0x0012
Global WM_RBUTTONDBLCLK           := 0x0206
Global WM_RBUTTONDOWN             := 0x0204
Global WM_RBUTTONUP               := 0x0205
Global WM_RENDERALLFORMATS        := 0x0306
Global WM_RENDERFORMAT            := 0x0305
Global WM_SETCURSOR               := 0x0020
Global WM_SETFOCUS                := 0x0007
Global WM_SETFONT                 := 0x0030
Global WM_SETHOTKEY               := 0x0032
Global WM_SETICON                 := 0x0080
Global WM_SETREDRAW               := 0x000B
Global WM_SETTEXT                 := 0x000C
Global WM_SETTINGCHANGE           := 0x001A ; WM_WININICHANGE
Global WM_SHOWWINDOW              := 0x0018
Global WM_SIZE                    := 0x0005
Global WM_SIZECLIPBOARD           := 0x030B
Global WM_SIZING                  := 0x0214
Global WM_SPOOLERSTATUS           := 0x002A
Global WM_STYLECHANGED            := 0x007D
Global WM_STYLECHANGING           := 0x007C
Global WM_SYNCPAINT               := 0x0088
Global WM_SYSCHAR                 := 0x0106
Global WM_SYSCOLORCHANGE          := 0x0015
Global WM_SYSCOMMAND              := 0x0112
Global WM_SYSDEADCHAR             := 0x0107
Global WM_SYSKEYDOWN              := 0x0104
Global WM_SYSKEYUP                := 0x0105
Global WM_TABLET_FIRST            := 0x02C0
Global WM_TABLET_LAST             := 0x02DF
Global WM_TCARD                   := 0x0052
Global WM_THEMECHANGED            := 0x031A
Global WM_TIMECHANGE              := 0x001E
Global WM_TIMER                   := 0x0113
Global WM_TOUCH                   := 0x0240 ; >= Win 7
Global WM_UNDO                    := 0x0304
Global WM_UNICHAR                 := 0x0109
Global WM_UNINITMENUPOPUP         := 0x0125
Global WM_UPDATEUISTATE           := 0x0128
Global WM_USER                    := 0x0400
Global WM_USERCHANGED             := 0x0054
Global WM_VKEYTOITEM              := 0x002E
Global WM_VSCROLL                 := 0x0115
Global WM_VSCROLLCLIPBOARD        := 0x030A
Global WM_WINDOWPOSCHANGED        := 0x0047
Global WM_WINDOWPOSCHANGING       := 0x0046
Global WM_WININICHANGE            := 0x001A
Global WM_WTSSESSION_CHANGE       := 0x02B1
Global WM_XBUTTONDBLCLK           := 0x020D
Global WM_XBUTTONDOWN             := 0x020B
Global WM_XBUTTONUP               := 0x020C
; Styles ===============================================================================================================
Global WS_BORDER                  := 0x00800000
Global WS_CAPTION                 := 0x00C00000 ; WS_BORDER|WS_DLGFRAME
Global WS_CHILD                   := 0x40000000
Global WS_CLIPCHILDREN            := 0x02000000
Global WS_CLIPSIBLINGS            := 0x04000000
Global WS_DISABLED                := 0x08000000
Global WS_DLGFRAME                := 0x00400000
Global WS_GROUP                   := 0x00020000
Global WS_HSCROLL                 := 0x00100000
Global WS_ICONIC                  := 0x20000000 ; WS_MINIMIZE
Global WS_MAXIMIZE                := 0x01000000
Global WS_MAXIMIZEBOX             := 0x00010000
Global WS_MINIMIZE                := 0x20000000
Global WS_MINIMIZEBOX             := 0x00020000
Global WS_OVERLAPPED              := 0x00000000
Global WS_POPUP                   := 0x80000000
Global WS_SIZEBOX                 := 0x00040000 ; WS_THICKFRAME
Global WS_SYSMENU                 := 0x00080000
Global WS_TABSTOP                 := 0x00010000
Global WS_THICKFRAME              := 0x00040000
Global WS_TILED                   := 0x00000000 ; WS_OVERLAPPED
Global WS_VISIBLE                 := 0x10000000
Global WS_VSCROLL                 := 0x00200000
; Common Window Styles
Global WS_CHILDWINDOW             := 0x40000000 ; WS_CHILD
Global WS_OVERLAPPEDWINDOW        := 0x00CF0000 ; WS_OVERLAPPED|CAPTION|SYSMENU|THICKFRAME|MINIMIZEBOX|MAXIMIZEBOX
Global WS_POPUPWINDOW             := 0x80880000 ; WS_POPUP|BORDER|SYSMENU
Global WS_TILEDWINDOW             := 0x00CF0000 ; WS_OVERLAPPEDWINDOW
; ExStyles =============================================================================================================
Global WS_EX_ACCEPTFILES          := 0x00000010
Global WS_EX_APPWINDOW            := 0x00040000
Global WS_EX_CLIENTEDGE           := 0x00000200
Global WS_EX_COMPOSITED           := 0x02000000
Global WS_EX_CONTEXTHELP          := 0x00000400
Global WS_EX_CONTROLPARENT        := 0x00010000
Global WS_EX_DLGMODALFRAME        := 0x00000001
Global WS_EX_LAYERED              := 0x00080000
Global WS_EX_LAYOUTRTL            := 0x00400000  ; Right to left mirroring
Global WS_EX_LEFT                 := 0x00000000
Global WS_EX_LEFTSCROLLBAR        := 0x00004000
Global WS_EX_LTRREADING           := 0x00000000
Global WS_EX_MDICHILD             := 0x00000040
Global WS_EX_NOACTIVATE           := 0x08000000
Global WS_EX_NOINHERITLAYOUT      := 0x00100000  ; Disable inheritence of mirroring by children
Global WS_EX_NOPARENTNOTIFY       := 0x00000004
Global WS_EX_RIGHT                := 0x00001000
Global WS_EX_RIGHTSCROLLBAR       := 0x00000000
Global WS_EX_RTLREADING           := 0x00002000
Global WS_EX_STATICEDGE           := 0x00020000
Global WS_EX_TOOLWINDOW           := 0x00000080
Global WS_EX_TOPMOST              := 0x00000008
Global WS_EX_TRANSPARENT          := 0x00000020
Global WS_EX_WINDOWEDGE           := 0x00000100
Global WS_EX_OVERLAPPEDWINDOW     := 0x00000300 ; WS_EX_WINDOWEDGE|EX_CLIENTEDGE
Global WS_EX_PALETTEWINDOW        := 0x00000188 ; WS_EX_WINDOWEDGE|EX_TOOLWINDOW|EX_TOPMOST
; ======================================================================================================================
just me
Posts: 7857
Joined: 02 Oct 2013, 08:51
Location: Germany

Re: GUI Constants

13 Sep 2014, 10:57

Ready, so far.
User avatar
hoppfrosch
Posts: 423
Joined: 07 Oct 2013, 04:05
GitHub: hoppfrosch
Location: Rhine-Maine-Area, Hesse, Germany
Contact:

Re: GUI Constants

18 Sep 2014, 04:16

Thx for your comprehensive work!
User avatar
jballi
Posts: 644
Joined: 29 Sep 2013, 17:34

Re: GUI Constants

24 Sep 2014, 07:57

Looks good. Thanks for the effort and for the index on the first post.

Things for me to do.
1. Bookmark this post.
2. When needed, remember that I bookmarked this post.
3. Find the bookmark for the post.
4. When that fails, do a search to find the post.
User avatar
joedf
Posts: 7932
Joined: 29 Sep 2013, 17:08
Facebook: J0EDF
Google: +joedf
GitHub: joedf
Location: Canada
Contact:

Re: GUI Constants

24 Sep 2014, 17:28

I suggest to sticky this topic... Yes no?
just me
Posts: 7857
Joined: 02 Oct 2013, 08:51
Location: Germany

Re: GUI Constants - updated on 2015-04-26

26 Apr 2015, 05:27

*bug fix on 2015-04-26, THX jNizM*
User avatar
TheArkive
Posts: 490
Joined: 05 Aug 2016, 08:06
GitHub: TheArkive

Re: GUI Constants - updated on 2015-04-26

08 May 2020, 09:10

could one use these to get dimensions of a control, with specific contents, before loading in an AHK gui?
User avatar
Epialis
Posts: 726
Joined: 02 Aug 2020, 22:44

Re: GUI Constants - updated on 2015-04-26

27 Dec 2020, 23:32

I'm still fairly new to AHK but eagerly learning and trying to understand everything. I'm not yet familiar with too many global variables or anything, so in laymen terms, how do we include or use these constants? Do we #include the file in our scripts? I know this is very basic, but it's how I learn. Thank you for extensive work.
just me
Posts: 7857
Joined: 02 Oct 2013, 08:51
Location: Germany

Re: GUI Constants - updated on 2015-04-26

28 Dec 2020, 05:26

The main purpose of this thread is to provide some of the numeric counterparts of the names used in the MSDN / Microsoft docs. You can do whatever you want, #Include complete files, copy the required definitions into your script, or just use the values on demand.

Return to “Scripts and Functions”

Who is online

Users browsing this forum: Chunjee, Joe Glines and 21 guests