typedb-osi / typeql-plugin-jetbrains

TypeQL plugin for JetBrains
MIT License
10 stars 6 forks source link

Update ANTLR file and proposed colouring #11

Closed SullivanDaly closed 1 year ago

SullivanDaly commented 1 year ago

What is the goal of this PR?

Updating ANTLR file and proposing a colouring identical to the on present in TypeDB Studio.

What are the changes implemented in this PR?

Updating the ANTLR file. Adding a new "ANY" token category working as a "garbage collector" Modifying the README to add proper colouring.

BFergerson commented 1 year ago

Thanks for this. The new colors are nice. I wasn't sure what the ANY_ thing was in the grammar file, but it was causing syntax issues with any TypeQL I put in the IDE, so I removed it. Besides that, lgtm.

SullivanDaly commented 1 year ago

Thank you for helping with updates and testing! the ANY_ was there because I was not able to capture the curvy brakets, comas and semi column to color them the proper way (as they are not tokenized in the ANTLR grammar). Putting those ones at the end was just a way to catch them all and add them to the proper section.