aboutsummaryrefslogtreecommitdiffstats
path: root/runtime/queries/gdshader
diff options
context:
space:
mode:
authorTayfun Bocek <tayfunbocek@live.ca>2025-11-27 12:35:21 +0300
committerGitHub <noreply@github.com>2025-11-27 10:35:21 +0100
commitd56ed0f7f90d6492ce422f5e0a9cb36d3169eb96 (patch)
tree3aebda41c2d7160ee41281920ae6326ee5fad053 /runtime/queries/gdshader
parentfix(perl): correct use of supertypes (diff)
downloadnvim-treesitter-d56ed0f7f90d6492ce422f5e0a9cb36d3169eb96.tar
nvim-treesitter-d56ed0f7f90d6492ce422f5e0a9cb36d3169eb96.tar.gz
nvim-treesitter-d56ed0f7f90d6492ce422f5e0a9cb36d3169eb96.tar.bz2
nvim-treesitter-d56ed0f7f90d6492ce422f5e0a9cb36d3169eb96.tar.lz
nvim-treesitter-d56ed0f7f90d6492ce422f5e0a9cb36d3169eb96.tar.xz
nvim-treesitter-d56ed0f7f90d6492ce422f5e0a9cb36d3169eb96.tar.zst
nvim-treesitter-d56ed0f7f90d6492ce422f5e0a9cb36d3169eb96.zip
feat(gdshader): update highlight queries (#8299)
* use uniform scope node instead of literal matching This avoids the need to refactor if other scope types are added. Maybe helps performance as well. * add method expression highlight
Diffstat (limited to 'runtime/queries/gdshader')
-rw-r--r--runtime/queries/gdshader/highlights.scm7
1 files changed, 5 insertions, 2 deletions
diff --git a/runtime/queries/gdshader/highlights.scm b/runtime/queries/gdshader/highlights.scm
index b4bb46ea1..0e29d53e7 100644
--- a/runtime/queries/gdshader/highlights.scm
+++ b/runtime/queries/gdshader/highlights.scm
@@ -1,6 +1,4 @@
[
- "global"
- "instance"
"group_uniforms"
"uniform"
"const"
@@ -10,6 +8,8 @@
"shader_type"
] @keyword
+(scope) @keyword
+
[
"if"
"else"
@@ -213,6 +213,9 @@
(call_expression
function: (identifier) @function.call)
+(method_expression
+ method: (_) @function.method.call)
+
(field_expression
field: (_) @property)