AutoHotkey v2 Language Support, used in any editor that supports lsp

Scripting and setups with Visual Studio Code (vscode) and AutoHotkey.
vmech
Posts: 356
Joined: 25 Aug 2019, 13:03

Re: AutoHotkey v2 Language Support, used in any editor that supports lsp

Post by vmech » 20 Nov 2023, 07:44

thqby wrote:
20 Nov 2023, 06:29
Failed to load the picture.

Code: Select all

"C:\BIN\Autohotkey\v2\AutoHotkey32.exe" /Debug=127.0.0.1:9002 /ErrorStdOut demo.ahk
Debugger Adapter Version: 1.11.0
Debug Configuration (launch): AutoHotkey2 Debug
AutoHotkey Version: 2.0.10
Debugging stopped.
thqby wrote:
20 Nov 2023, 06:29
If you need custom functions, of course you need launch.json.
What you mean with custom functions ?
Please post your script code inside [code] ... [/code] block. Thank you.

User avatar
thqby
Posts: 408
Joined: 16 Apr 2021, 11:18
Contact:

Re: AutoHotkey v2 Language Support, used in any editor that supports lsp

Post by thqby » 20 Nov 2023, 08:15

As you mentioned, not outputting this information.

vmech
Posts: 356
Joined: 25 Aug 2019, 13:03

Re: AutoHotkey v2 Language Support, used in any editor that supports lsp

Post by vmech » 20 Nov 2023, 08:55

thqby wrote:
20 Nov 2023, 08:15
As you mentioned, not outputting this information.
Ok, I got it.
Please post your script code inside [code] ... [/code] block. Thank you.

Robt800
Posts: 31
Joined: 16 May 2023, 05:09

Re: AutoHotkey v2 Language Support, used in any editor that supports lsp

Post by Robt800 » 20 Nov 2023, 10:50

I've just started using this today - really like it. One thing I've found (and it could well be my vscode settings for all I know) - the region folding downwards arrow seems to move down to the
;#endregion
instead of being at the top
;#region
.

Please see pic:
Image

Thanks
Rob

vmech
Posts: 356
Joined: 25 Aug 2019, 13:03

Re: AutoHotkey v2 Language Support, used in any editor that supports lsp

Post by vmech » 21 Nov 2023, 00:52

@Robt800 you can use commented out braces instead.

Code: Select all

;{	<-- open brace for folding
  ... some code ...
;}	<-- close brace for folding
Please post your script code inside [code] ... [/code] block. Thank you.

Robt800
Posts: 31
Joined: 16 May 2023, 05:09

Re: AutoHotkey v2 Language Support, used in any editor that supports lsp

Post by Robt800 » 21 Nov 2023, 08:27

vmech wrote:
21 Nov 2023, 00:52
@Robt800 you can use commented out braces instead.

Code: Select all

;{	<-- open brace for folding
  ... some code ...
;}	<-- close brace for folding
Thanks very much for this tip. Interestingly I was still getting the issue intermittently. But what I found was that if I put an extra line above the end region and made it a comment (like below) - folding reverted back to where it should. Little weird - but easily livable with!
Thanks

Code: Select all

;{#region Variables ==============================================================
File_List := [] ; Array to contain all files in working folder
Files_Req_Rename_Wash := [] ; Array to contain all files relating to wash cycle that need renaming
Files_Req_Rename_Wash_Dates := [] ; Array to contain all dates of files relating to wash cycle that need renaming
Files_New_Names_Wash := []
Files_Req_Rename_Scr_Print := [] ; Array to contain all files relating to wash cycle that need renaming
Files_Req_Rename_Scr_Print_Dates := [] ; Array to contain all dates of files relating to wash cycle that need renaming
Files_New_Names_Scr_Print := []
Month_TableMM := [01,02,03,04,05,06,07,08,09,10,11,12]
Month_TableMMM := ["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]
;
;}#endregion =====================================================================

vmech
Posts: 356
Joined: 25 Aug 2019, 13:03

Re: AutoHotkey v2 Language Support, used in any editor that supports lsp

Post by vmech » 21 Nov 2023, 09:21

@Robt800
In extension settings check option shown below:
Image
Please post your script code inside [code] ... [/code] block. Thank you.

Robt800
Posts: 31
Joined: 16 May 2023, 05:09

Re: AutoHotkey v2 Language Support, used in any editor that supports lsp

Post by Robt800 » 21 Nov 2023, 10:54

vmech wrote:
21 Nov 2023, 09:21
@Robt800
In extension settings check option shown below:
Image
@vmech - good work vmech - that seems to have sorted it.
Thank you for the assistance
Rob

Post Reply

Return to “Visual Studio Code”