AutoHotkey syntax lists (text files)

Put simple Tips and Tricks that are not entire Tutorials in this forum
User avatar
jeeswg
Posts: 4977
Joined: 19 Dec 2016, 01:58
Location: UK

AutoHotkey syntax lists (text files)

19 Apr 2018, 07:09

- Previously, AutoHotkey syntax lists were available as text files, when you downloaded AutoHotkey.
- Here is an example for the last version of AutoHotkey Basic, AutoHotkey v1.0.48.05:
Index of /download/1.0
https://autohotkey.com/download/1.0/
AutoHotkey104805.zip
https://autohotkey.com/download/1.0/AutoHotkey104805.zip
AutoHotkey104805.zip\Extras\Editors\Syntax
- I have attempted to update these for the latest version of AutoHotkey, AutoHotkey v1.1.28.02. The zip also includes copies of the text files from 2009 for AutoHotkey v1.0.48.05.
- [EDIT:] Fixed ZInfo.txt to say 'v1.1.28.02' not 'v1.0.28.02'.
Attachments
AHKSyntax_1.1.28.02.zip
(34.6 KiB) Downloaded 37 times
Last edited by jeeswg on 19 Apr 2018, 17:37, edited 2 times in total.
burque505
Posts: 546
Joined: 22 Jan 2017, 19:37

Re: AutoHotkey syntax lists (text files)

19 Apr 2018, 10:56

Thanks, jeeswg. I didn't find "Join" in there anywhere.
Regards,
burque505
User avatar
gregster
Posts: 1381
Joined: 30 Sep 2013, 06:48

Re: AutoHotkey syntax lists (text files)

19 Apr 2018, 11:57

Isn't Join just an specific option in Continuation sections? (I haven't looked at the file, so I don't know if it tries to list all available options...?)
User avatar
derz00
Posts: 495
Joined: 02 Feb 2016, 17:54
GitHub: derz00
Location: Middle of the round cube

Re: AutoHotkey syntax lists (text files)

19 Apr 2018, 12:38

oops, a typo in the OP--should be 1.1.28.02

Cheers
try it and see
...
User avatar
jeeswg
Posts: 4977
Joined: 19 Dec 2016, 01:58
Location: UK

Re: AutoHotkey syntax lists (text files)

19 Apr 2018, 17:27

- @burque505: Keywords.txt contains 'Join' as used by continuation sections.
- This page contains a 'Join' example custom function, but it isn't a standard (built-in) part of AutoHotkey.
Functions
https://autohotkey.com/docs/Functions.htm#Variadic
I only knew about it because I saw this post the other day:
Example for "Join" re variadic functions: bug? - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=5&t=47563
- @derz00: Fixed. It had said '1.0.28.02', when it should have said '1.1.28.02'. Thanks. I've fixed this in ZInfo.txt also, and updated the zip.
User avatar
nnnik
Posts: 3218
Joined: 30 Sep 2013, 01:01
Location: Germany

Re: AutoHotkey syntax lists (text files)

19 Apr 2018, 23:48

It's kind of confusing - I have no idea which file contains which info for what version.
It would be nice if you could add an Overwie.ahk that explains that.
Other than that it's good work - I'll use it to complete a few Syntax Highlighters.
Recommends AHK Studio
User avatar
jeeswg
Posts: 4977
Joined: 19 Dec 2016, 01:58
Location: UK

Re: AutoHotkey syntax lists (text files)

19 Apr 2018, 23:54

I'll add this info to ZInfo.txt during the next update:

Code: [Select all] [Expand] [Download] GeSHi © Codebox Plus

You know, the original files, they didn't have any helpful info. Cheers.
Last edited by jeeswg on 19 Apr 2018, 23:57, edited 1 time in total.
User avatar
nnnik
Posts: 3218
Joined: 30 Sep 2013, 01:01
Location: Germany

Re: AutoHotkey syntax lists (text files)

19 Apr 2018, 23:57

Thanks
Recommends AHK Studio
User avatar
nnnik
Posts: 3218
Joined: 30 Sep 2013, 01:01
Location: Germany

Re: AutoHotkey syntax lists (text files)

20 Apr 2018, 00:12

Also consistent with Commands Directives, Functions etc:
NamesKeywords.txt:

Code: [Select all] [Expand] [Download] (NamesKeywords.txt)GeSHi © Codebox Plus

Recommends AHK Studio
User avatar
jeeswg
Posts: 4977
Joined: 19 Dec 2016, 01:58
Location: UK

Re: AutoHotkey syntax lists (text files)

20 Apr 2018, 00:54

- These have an absolutely clear definition:
commands
control flow statements
directives
functions
variables

- If you want to somehow make 'keywords', 'a thing', you'll have to do some detailed categorisation stating sources and principles. So that anyone in the world could recreate exactly the same list. At the moment I don't see any logical basis for 'keywords'.
- Btw where is RawRead? Should object methods be listed?
list of every object type/property/method - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=37&t=44081
- There is also this, if you want to use GUI-related keywords.
GUI - Complete Command & Property Listing - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=5&t=46420&p=213529#p213529
- What about window classes like AutoHotkeyGUI / AutoHotkey2?
- I've done what I wanted to do. A lot of how this project might move forward, is for people doing autocomplete etc, to tailor it to their requirements. As I suggested here:
AHK Auto Formatter? - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=5&t=1778
User avatar
nnnik
Posts: 3218
Joined: 30 Sep 2013, 01:01
Location: Germany

Re: AutoHotkey syntax lists (text files)

20 Apr 2018, 06:59

Object methods are not keywords.
We also need operators.

Keywords are parameters that commonly give or have special meaning for functions/commands or methods and are very specific. Im not sure about that definition - but keywords is something that is commonly used to define syntax highlighters and in editors.
I think would be useful specifically for editors/syntax highlighting.
Recommends AHK Studio
User avatar
jeeswg
Posts: 4977
Joined: 19 Dec 2016, 01:58
Location: UK

Re: AutoHotkey syntax lists (text files)

20 Apr 2018, 08:21

- @nnnik: If you wanted to post an updated version of Keywords.txt with more keywords, that would be fine.
- Already in the list: Not/Or/And, Between/Contains/In/Is.
- Not in the list: class/new/this.
- Note: Keywords.txt is almost unchanged from the AHK Basic original (I added ahk_exe/Files/Reg), and it currently contains nothing object-related since AHK Basic didn't have objects.
- Note: object methods aren't currently listed anywhere in the zip, in case you wanted them somewhere.
- If you wanted symbolic operators, see OPERATOR PRECEDENCE, here:
jeeswg's characters tutorial - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=7&t=26486
- Potentially a systematic check for (read through of) lines containing '[v1.1.' could be done, these indicate new features.
- Anyhow, it's for people other than me to make suggestions, I'm happy with what I've got, and I find that drop-down menus/script assistance slows me down, I prefer hotstrings for code blocks, code lines and individual words.
User avatar
nnnik
Posts: 3218
Joined: 30 Sep 2013, 01:01
Location: Germany

Re: AutoHotkey syntax lists (text files)

20 Apr 2018, 08:48

No just a list of operators. I wouldn't even mention precedence.
Also not/Or/And are operators.
Methods should be in their file - I might do this this weekend.
Maintaining this list should help people to implement proper Syntax Highlighting for the latest version.

v2 should be it's own zip
Recommends AHK Studio
User avatar
jeeswg
Posts: 4977
Joined: 19 Dec 2016, 01:58
Location: UK

Re: AutoHotkey syntax lists (text files)

20 Apr 2018, 08:57

- The operators link has a list of the symbolic operators listed in a form that's easy to parse. (I know they're operators, in the post above I listed operators that were already in the list.)
- If your doing methods, this could save you some work.
list of every object type/property/method - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=37&t=44081
- You could start a separate AHK v2 keywords file if you like.
- I wanted to get more feedback before considering an AHK v2 zip, i.e. I want people to point out all possible issues with the AHK v1.1 zip before moving forwards.
User avatar
nnnik
Posts: 3218
Joined: 30 Sep 2013, 01:01
Location: Germany

Re: AutoHotkey syntax lists (text files)

20 Apr 2018, 10:50

We should probably use github for hosting though - so that people can edit it and see it in public.
Thanks for the link i will use it.

I dont understand what you mean - do you already have a list for operators?
Recommends AHK Studio
User avatar
jeeswg
Posts: 4977
Joined: 19 Dec 2016, 01:58
Location: UK

Re: AutoHotkey syntax lists (text files)

20 Apr 2018, 12:15

- I keep various syntax lists, listed in this post:
list of every command/function/variable from across all versions - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=7&t=27321&p=131642#p131642
- Here's a list of operators. I wasn't sure if this list was applicable to this project, since most of the operators are symbolic not words, however, there are symbols listed in Keys.txt.

Code: [Select all] [Expand] [Download] GeSHi © Codebox Plus

burque505
Posts: 546
Joined: 22 Jan 2017, 19:37

Re: AutoHotkey syntax lists (text files)

20 Apr 2018, 16:06

Thanks for the clarification, jeeswg.
Regards,
burque505

Return to “Tips and Tricks”

Who is online

Users browsing this forum: No registered users and 3 guests