Make AutoHotkey Help window open always maximized and / or remember its last state

Discuss the future of the AutoHotkey language
User avatar
A Keymaker
Posts: 461
Joined: 31 May 2022, 13:46
Location: Donjon du Château de Mérovingien

Make AutoHotkey Help window open always maximized and / or remember its last state

06 Jul 2023, 12:36

I propose making the AutoHotkey Help window to be always opened in a maximized form, because it does not remember being opened maximized the previous time it was opened

[And this viewtopic.php?f=76&t=113468#p528691 although does alleviate this annoying issues, is nevertheless merely a workaround bearing implications]
Last edited by A Keymaker on 09 Jul 2023, 05:02, edited 1 time in total.
User avatar
boiler
Posts: 17706
Joined: 21 Dec 2014, 02:44

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

06 Jul 2023, 20:40

A Keymaker wrote: I propose making the AutoHotkey Help window to be always opened in a maximized form
Not that I expect this to get any serious consideration, but I would absolutely hate this. I can’t think of any serious programs that do this or would consider doing this.

Open it in a non-maximized state that is sized to fill your monitor, and it will remember that.
lexikos
Posts: 9780
Joined: 30 Sep 2013, 04:07
Contact:

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

06 Jul 2023, 21:12

This is not what the Development subforum is for.
AutoHotkey Development
Discuss the future of the AutoHotkey language
Source: AutoHotkey Community - Index page
This is the sort of complaint that such a change would be likely to generate:
WHY does AHK Help Open Maximized? - AutoHotkey Community

If you want it to open maximized, just open it maximized.

Code: Select all

#Requires AutoHotkey v2
Run A_AhkPath "\..\AutoHotkey.chm",, "Max"
You can override the tray menu like so with v2:

Code: Select all

#Requires AutoHotkey v2
Persistent
A_TrayMenu.Add "&Help", open_help_maximized
open_help_maximized(*) {
	Run A_AhkPath "\..\AutoHotkey.chm",, "Max"
}
The Help option in the main window can only be overridden with OnMessage.

As for v1, you can use OnMessage with message 0x111 and wParam = 65411 (main window menu) or 65301 (tray menu). As a user of v1, you should not expect any further development unless you are doing it yourself.
User avatar
A Keymaker
Posts: 461
Joined: 31 May 2022, 13:46
Location: Donjon du Château de Mérovingien

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

07 Jul 2023, 03:35

boiler wrote:
06 Jul 2023, 20:40
[...]
Open it in a non-maximized state that is sized to fill your monitor, and it will remember that.
In V1 it does not. It is always opened in window with size of almost maximized one
lexikos
Posts: 9780
Joined: 30 Sep 2013, 04:07
Contact:

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

07 Jul 2023, 03:58

v1 or v2 is irrelevant. The help file is displayed by a built-in Windows program, hh.exe. It usually does remember the window position, but that can fail if the file in which it stores this information (%APPDATA%\Microsoft\HTML Help\hh.dat) is corrupt. You can try deleting it.
User avatar
A Keymaker
Posts: 461
Joined: 31 May 2022, 13:46
Location: Donjon du Château de Mérovingien

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

09 Jul 2023, 05:09

In its location

C:\Users\YOUR-USER-NAME\AppData\Roaming\Microsoft\HTML Help

I have also found AutoHotkey.chw file. But despite deleting both of them [and making sure my docked at top Winamp is turned off] it still does not work

To be precise: the size and placement of AutoHotkey Help window did get a default small size and placement in upper left area of screen; and after resizing it / and or moving around and then closing and re-opening of it that window was in the same state. But still if I maximize it then this state will be "half-remembered" as it will be almost 100% upon next opening

So this tells us that the hh.dat file does remember also the maximized state - but my hh.exe is unable to push this command all the way through for the AutoHotkey Help window
User avatar
boiler
Posts: 17706
Joined: 21 Dec 2014, 02:44

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

09 Jul 2023, 05:55

A Keymaker wrote: after resizing it / and or moving around and then closing and re-opening of it that window was in the same state.
Then it sounds like this will now work:
boiler wrote: Open it in a non-maximized state that is sized to fill your monitor, and it will remember that.
User avatar
A Keymaker
Posts: 461
Joined: 31 May 2022, 13:46
Location: Donjon du Château de Mérovingien

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

09 Jul 2023, 06:43

This is just a lame band-aid

I do not wish to see an edge of potentially distracting content behind a window with help content [for any program] because if I am reading such thing then it means I am in some kind predicament and thus I need to have 100% focus

Plus its get destroyed, i.e. moves down, every time I unfold my thin bar of docked Winamp to a larger size


And there must be other users who dock also other programs - thus also not being able to use such workaround without constantly correcting it [which then has no sense as it is easier and quicker to once more maximize the window by using its proper mini-icon from its bar with title]
User avatar
boiler
Posts: 17706
Joined: 21 Dec 2014, 02:44

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

09 Jul 2023, 06:50

Sorry to hear you are so easily distracted. This is an AHK forum, not a Windows forum, so I made a suggestion to try to help you given the way that Windows program apparently works. Sorry you consider it lame. I will make it a point not to suggest anything else to you going forward.
User avatar
A Keymaker
Posts: 461
Joined: 31 May 2022, 13:46
Location: Donjon du Château de Mérovingien

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

10 Jul 2023, 05:20

Understood. AutoHotkey is suppose to work in a vacuum and not a Microsoft environment. Stupid me
neogna2
Posts: 619
Joined: 15 Sep 2016, 15:44

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

10 Jul 2023, 05:28

@a keymaker: sarcasm is not useful.
Did you try this?
lexikos wrote:
06 Jul 2023, 21:12
If you want it to open maximized, just open it maximized.

Code: Select all

#Requires AutoHotkey v2
Run A_AhkPath "\..\AutoHotkey.chm",, "Max"
Run a script with that line whenever you want to start the help file maximized.
Or make a shortcut to AutoHotkey.chm and edit the shortcut's properties to start maximized.
Problem solved?
User avatar
A Keymaker
Posts: 461
Joined: 31 May 2022, 13:46
Location: Donjon du Château de Mérovingien

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

10 Jul 2023, 06:05

neogna2 wrote:
10 Jul 2023, 05:28
[...]
Did you try this?
[...]
Thank you, but I already have a workaround
A Keymaker wrote:
06 Jul 2023, 12:36
[...]
[And this viewtopic.php?f=76&t=113468#p528691 although does alleviate this annoying issues, is nevertheless merely a workaround bearing implications]
nd this topic is about averting a need to use one

So the answer to your question
neogna2 wrote:
10 Jul 2023, 05:28
Problem solved?
is yes - with a workaround in form of a global AHK script


But nevertheless thank your for your ideas
User avatar
boiler
Posts: 17706
Joined: 21 Dec 2014, 02:44

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

10 Jul 2023, 06:53

A Keymaker wrote: Understood. AutoHotkey is suppose to work in a vacuum and not a Microsoft environment. Stupid me
But you made it clear that an AHK workaround isn’t what you are looking for. You are expecting a fix for the application itself which is not an AHK issue as you were told by the definitive source.
User avatar
A Keymaker
Posts: 461
Joined: 31 May 2022, 13:46
Location: Donjon du Château de Mérovingien

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

10 Jul 2023, 08:28

But my point is that every AHK file by default is able to produce e.g. [if applicable] a pop-up box saying
The hotkey £ will not be active because it does not exist in the current keyboard layout.
if £ key is used within its script. And where does it come from? From Bill Gates or from its source?


Thus my proposition in this topic is to make every AHK by default behave like when a user runs a workaround solution like this viewtopic.php?f=76&t=113468#p528691
neogna2
Posts: 619
Joined: 15 Sep 2016, 15:44

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

10 Jul 2023, 11:22

I never maximize the Autohotkey .chm window and I'm against the suggested change to (in some way or other) make it default to open maximized.
I like the current situation where each user can super easily choose themselves if they want .chm to open maximized or not.
User avatar
V2User
Posts: 222
Joined: 30 Apr 2021, 04:04

Re: Make AutoHotkey Help window open always maximized and / or remember its last state

13 Jul 2023, 02:16

It is a matter of changing a readers for chm files. There are many chm readers who can satisfy your demand, maybe 'sumatra pdf' etc.
Ironically, the software for reading chm on MAC is even much better than Win. It's much more than just reading chm but also annotating it.

Return to “AutoHotkey Development”

Who is online

Users browsing this forum: No registered users and 3 guests