Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing keywords.txt files to bundled libraries #5183

Merged
merged 1 commit into from
Sep 29, 2018
Merged

Add missing keywords.txt files to bundled libraries #5183

merged 1 commit into from
Sep 29, 2018

Conversation

per1234
Copy link
Contributor

@per1234 per1234 commented Sep 29, 2018

Partially resolves #5179

CC: @Makuna

@earlephilhower
Copy link
Collaborator

LGTM, but I don't think the IDE looks past the first tab, so the add'l specifiers may not be used (LITERAL, etc.). Still seems to run fine on the one I checked, DNSServer.

Thanks for helping out!

@earlephilhower earlephilhower added this to the 2.5.0 milestone Sep 29, 2018
@per1234
Copy link
Contributor Author

per1234 commented Sep 29, 2018

With the switch to using the RSyntaxTextArea editor in Arduino IDE 1.6.5 and newer, the fourth field of keywords.txt (RSYNTAXTEXTAREA_TOKENTYPE) overrides the second field (KEYWORD_TOKENTYPE). If that field is not present, the IDE falls back to using KEYWORD_TOKENTYPE, but with a less fine-grained range of keyword coloration than in Arduino IDE 1.6.4 and older.

You can see the use of the RSYNTAXTEXTAREA_TOKENTYPE field demonstrated in the Arduino core library's keywords.txt:
https://github.com/arduino/Arduino/blob/master/build/shared/lib/keywords.txt

The new keywords.txt format has not been very widely adopted because the Arduino developers never bothered to document it and the previous format continues to work.

I usually don't bother to use the new format, but decided I'd make the extra effort in this case. If you prefer the old keywords.txt format, I'll be happy to update the PR.

Details:
https://github.com/arduino/Arduino/wiki/Arduino-IDE-1.5:-Library-specification#keywordstxt-format

@earlephilhower
Copy link
Collaborator

No, it's fine the way it is. I'd just never seen it before. Thx!

@earlephilhower earlephilhower merged commit 4e3af97 into esp8266:master Sep 29, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

DNSServer cleanup
2 participants