Re: AutoGUI - GUI Designer and Script Editor
Posted: 26 Apr 2017, 19:38
New tool added in version 1.4.1: COM Inspector - information about COM classes. Based on CLSID Registry Scanner and iTypeInfo.
Download
Download
Let's help each other out
https://www.autohotkey.com/boards/
https://www.autohotkey.com/boards/viewtopic.php?f=90&t=10157
1. imo the shortcut ctrl+down is expected to move a line down as ctrl+up moves a line up.Alguimist wrote:Thanks for your suggestions, Asmodeus. The keyboard shortcut to duplicate a line is Ctrl + Down arrow.
I guess I found a bug:Rorqual wrote:I added code folding to the autogui editor[/code]
Code: Select all
d::
SendInput Hello you.{Return}
Return
All you need to know is how to configure the compiler path and batch files for 32 and 64-bit. Going to Settings > Help, you can see some examples. If you have the Windows SDK or Visual Studio, the compiler path is the path to CL.EXE. The batch files are vcvars32.bat and vcvars64.bat or vcvarsx86_amd64.bat.TheDewd wrote:Can we get a tutorial on how to use Structor?
The Users menu of Process Explorer is created when the menu is activated.Asmodeus wrote:cloning proc ex leads to submenu does not exist.
how i make re-clone ?Alguimist wrote:There's no undo for the GUI designer yet, but (as a workaround) you can undo in the script editor and then re-clone the GUI.
Any reason for that?Redpr0star wrote:can you make it so that it is not a 7-Zip file
See this example:Maasq wrote:Is it possible to have toolbars running in different windows? I have my main GUI, and then a child GUI launches when I press a button. I'd like this window to have its own toolbar.
Code: Select all
#NoEnv
#SingleInstance Force
SetWorkingDir %A_ScriptDir%
SetBatchLines -1
;#Include %A_ScriptDir%\Toolbar.ahk
Gui Show, w481 h381, Main Window
hMainToolbar := CreateToolBar()
Return
GuiEscape:
GuiClose:
ExitApp
CreateToolbar() {
ImageList := IL_Create(1)
IL_Add(ImageList, "shell32.dll", 3)
Buttons =
(LTrim
New Window,,, SHOWTEXT
)
Return ToolbarCreate("OnToolbar", Buttons, ImageList, "Flat List Tooltips")
}
OnToolbar(hWnd, Event, Text, Pos, Id) {
If (Event != "Click") {
Return
}
If (Text == "New Window") {
GoSub NewWindow
}
}
NewWindow:
Gui NewGUI: New, +LabelNewGUI
Gui Show, w383 h252, New Window
ImageList := IL_Create(1)
IL_Add(ImageList, "shell32.dll", 4)
Buttons =
(LTrim
Open
)
hNewToolbar := ToolbarCreate("OnToolbar2", Buttons, ImageList, "Flat List Tooltips")
Return
NewGUIEscape:
NewGUIClose:
Gui NewGUI: Destroy
Return
OnToolbar2(hWnd, Event, Text, Pos, Id) {
If (Event != "Click") {
Return
}
If (Text == "Open") {
MsgBox
}
}
; Toolbar.ahk
ToolbarCreate(Handler, Buttons, ImageList := "", Options := "Flat List ToolTips", Pos := "") {
Static TOOLTIPS := 0x100, WRAPABLE := 0x200, FLAT := 0x800, LIST := 0x1000, TABSTOP := 0x10000, BORDER := 0x800000, TEXTONLY := 0
Static BOTTOM := 0x3, ADJUSTABLE := 0x20, NODIVIDER := 0x40, VERTICAL := 0x80
Static CHECKED := 1, HIDDEN := 8, WRAP := 32, DISABLED := 0 ; States
Static CHECK := 2, CHECKGROUP := 6, DROPDOWN := 8, AUTOSIZE := 16, NOPREFIX := 32, SHOWTEXT := 64, WHOLEDROPDOWN := 128 ; Styles
StrReplace(Options, "SHOWTEXT", "", fShowText, 1)
fTextOnly := InStr(Options, "TEXTONLY")
Styles := 0
Loop Parse, Options, %A_Tab%%A_Space%, %A_Tab%%A_Space% ; Parse toolbar styles
IfEqual A_LoopField,, Continue
Else Styles |= A_LoopField + 0 ? A_LoopField : %A_LoopField%
If (Pos != "") {
Styles |= 0x4C ; CCS_NORESIZE | CCS_NOPARENTALIGN | CCS_NODIVIDER
}
Gui Add, Custom, ClassToolbarWindow32 hWndhWnd g@ToolbarHandler -Tabstop %Pos% %Styles%
@ToolbarStorage(hWnd, Handler)
TBBUTTON_Size := A_PtrSize == 8 ? 32 : 20
Buttons := StrSplit(Buttons, "`n")
cButtons := Buttons.Length()
VarSetCapacity(TBBUTTONS, TBBUTTON_Size * cButtons , 0)
Index := 0
Loop %cButtons% {
Button := StrSplit(Buttons[A_Index], ",", " `t")
If (Button[1] == "-") {
iBitmap := 0
idCommand := 0
fsState := 0
fsStyle := 1 ; BTNS_SEP
iString := -1
} Else {
Index++
iBitmap := (fTextOnly) ? -1 : (Button[2] != "" ? Button[2] - 1 : Index - 1)
idCommand := (Button[5]) ? Button[5] : 10000 + Index
fsState := InStr(Button[3], "DISABLED") ? 0 : 4 ; TBSTATE_ENABLED
Loop Parse, % Button[3], %A_Tab%%A_Space%, %A_Tab%%A_Space% ; Parse button states
IfEqual A_LoopField,, Continue
Else fsState |= %A_LoopField%
fsStyle := fTextOnly || fShowText ? SHOWTEXT : 0
Loop Parse, % Button[4], %A_Tab%%A_Space%, %A_Tab%%A_Space% ; Parse button styles
IfEqual A_LoopField,, Continue
Else fsStyle |= %A_LoopField%
iString := &(ButtonText%Index% := Button[1])
}
Offset := (A_Index - 1) * TBBUTTON_Size
NumPut(iBitmap, TBBUTTONS, Offset, "Int")
NumPut(idCommand, TBBUTTONS, Offset + 4, "Int")
NumPut(fsState, TBBUTTONS, Offset + 8, "UChar")
NumPut(fsStyle, TBBUTTONS, Offset + 9, "UChar")
NumPut(iString, TBBUTTONS, Offset + (A_PtrSize == 8 ? 24 : 16), "Ptr")
}
ExtendedStyle := 0x89 ; (mixed buttons, draw DD arrows, double buffer)
SendMessage 0x454, 0, %ExtendedStyle%,, ahk_id %hWnd% ; TB_SETEXTENDEDSTYLE
SendMessage 0x430, 0, %ImageList%,, ahk_id %hWnd% ; TB_SETIMAGELIST
SendMessage % A_IsUnicode ? 0x444 : 0x414, %cButtons%, % &TBBUTTONS,, ahk_id %hWnd% ; TB_ADDBUTTONS
If (InStr(Options, "VERTICAL")) {
VarSetCapacity(SIZE, 8, 0)
SendMessage 0x453, 0, &SIZE,, ahk_id %hWnd% ; TB_GETMAXSIZE
} Else {
SendMessage 0x421, 0, 0,, ahk_id %hWnd% ;TB_AUTOSIZE
}
Return hWnd
}
@ToolbarStorage(hWnd, Callback := "") {
Static o := {}
Return (o[hWnd] != "") ? o[hWnd] : o[hWnd] := Callback
}
@ToolbarHandler(hWnd) {
Static n := {-2: "Click", -5: "RightClick", -20: "LDown", -713: "Hot", -710: "DropDown"}
Handler := @ToolbarStorage(hWnd)
Code := NumGet(A_EventInfo + 0, A_PtrSize * 2, "Int")
If (Code != -713) {
ButtonId := NumGet(A_EventInfo + (3 * A_PtrSize))
} Else {
ButtonId := NumGet(A_EventInfo, A_PtrSize == 8 ? 28 : 16, "Int") ; NMTBHOTITEM idNew
}
SendMessage 0x419, ButtonId,,, ahk_id %hWnd% ; TB_COMMANDTOINDEX
Pos := ErrorLevel + 1
VarSetCapacity(Text, 128)
SendMessage % A_IsUnicode ? 0x44B : 0x42D, ButtonId, &Text,, ahk_id %hWnd% ; TB_GETBUTTONTEXT
Event := (n[Code] != "") ? n[Code] : Code
%Handler%(hWnd, Event, Text, Pos, ButtonId)
}