Feedback

Discuss Autohotkey related topics here. Not a place to share code.
Forum rules
Discuss Autohotkey related topics here. Not a place to share code.
000
Posts: 11
Joined: 20 May 2018, 16:51

Feedback

Post by 000 » 21 Apr 2023, 16:56

[Moderator's note: Topic moved from Bug Reports.]

Here are all the issues i found while creating functional scripts:

1

Code: Select all

mygui := gui()
mygui.opt("-maximizebox")
mygui.show("w210")
maximizebox doesn't work
minimizebox removes both window buttons

2

Code: Select all

mygui := gui()
mygui.add("edit", "number")
mygui.show()
negative sign is not allowed

3

Code: Select all

mygui := gui()
mygui.add("pic", "icon2", "shell32")
mygui.show()
.dll file extension is not required
also applies to trayseticon()

4

Code: Select all

mygui := gui()
picture := mygui.add("pic",, "32x32.png")
mygui.show()

esc::
{
picture.value := ""
picture.value := "16x16.png"
}
when you add a picture control, then set the filename to blank, and load a new image of a different size, the control is also resized. if the filename is empty, the size of the control should not be affected so that the new image will scale to the original size instead of its actual size

5

wingetpos

the width and height of windows are inaccurate, also affecting the x coordinate (e.g. file explorer, run), because it includes the resize border which is 7px all around except for the top, regardless of whether the window is resizable or not

6

winmove

need SW_RESTORE parameter from showCmd using SetWindowPlacement

7

the Start in field of a shortcut to a script doesn't work for loading files from the relative path of the working directory

User avatar
Delta Pythagorean
Posts: 627
Joined: 13 Feb 2017, 13:44
Location: Somewhere in the US
Contact:

Re: Feedback

Post by Delta Pythagorean » 09 May 2023, 09:01

  1. That's windows itself. If the maximize box is disabled and the minimize box is hidden, both buttons are hidden. However if the maximize button is enabled (such as using +Resize), the minimize button is hidden but the maximize button is still shown.
  2. Again, windows itself controls this. I did find this thread you may follow for more control (however it is v1, so translating to v2 is required.): viewtopic.php?t=55594
  3. I don't see the issue. Are you complaining that the dll extension should be required?
  4. This is because when adding the image control, it sets the size of the control to the image's size. To change this, enforce a size to the control when it is added to the Gui to avoid the control resizing.
  5. It seems the documentation for WinGetPos within the Remarks section may shed some light onto this:
    https://www.autohotkey.com/docs/v2/lib/WinGetPos.htm#Remarks wrote: As the coordinates returned by this function include the window's title bar, menu and borders, they may be dependent on OS version and theme. To get more consistent values across different systems, consider using WinGetClientPos instead.
  6. I don't really know what to say about this.
  7. You lost me. What is that and what purpose does it server?

[AHK]......: v2.0.12 | 64-bit
[OS].......: Windows 11 | 23H2 (OS Build: 22621.3296)
[GITHUB]...: github.com/DelPyth
[PAYPAL]...: paypal.me/DelPyth
[DISCORD]..: tophatcat


000
Posts: 11
Joined: 20 May 2018, 16:51

Re: Feedback

Post by 000 » 25 May 2023, 18:43

1. my mistake. i misunderstood the effect of using maximizebox. it disables, not removes the window button
2. feature request
3. yes, the same as all other types
4. adding h32 w32 doesn't work either
5. unfortunately wingetclientpos is not any better
6. to be able to move a maximized window without having to use dllcall
7. it turns out a_workingdir defaults to a_scriptdir regardless of how the script was launched, i.e. a_initialworkingdir. an example use case is if you have a shortcut to a script where the Start in directory (which is different than the script) contains a file which is accessed using loop read "example.txt". the only solution is to use setworkingdir

Post Reply

Return to “General Discussion”