summaryrefslogtreecommitdiff
path: root/queries/gdscript/highlights.scm
diff options
context:
space:
mode:
Diffstat (limited to 'queries/gdscript/highlights.scm')
-rw-r--r--queries/gdscript/highlights.scm27
1 files changed, 27 insertions, 0 deletions
diff --git a/queries/gdscript/highlights.scm b/queries/gdscript/highlights.scm
new file mode 100644
index 00000000..06b7c8df
--- /dev/null
+++ b/queries/gdscript/highlights.scm
@@ -0,0 +1,27 @@
+(identifier) @variable
+
+(name) @variable
+(type) @type
+(comment) @comment
+
+(enum_definition
+ (name) @constant) @Statement
+
+(function_definition
+ (name) @function
+ (parameters
+ (identifier)* @parameter) @punctuation.bracket) @Statement
+
+(return_statement) @Statement
+
+(variable_statement
+ (inferred_type)? @operator) @Statement
+
+(call (identifier) @function) @punctuation.bracket
+(attribute (attribute_call (identifier) @function) @punctuation.bracket)
+
+; simple items
+[ (binary_operator) (comparison_operator) ] @operator
+[ (false) (true) ] @boolean
+(string) @string
+(integer) @number