2024-06-07 21:33:49 -07:00
|
|
|
((comment) @injection.content
|
|
|
|
|
(#set! injection.language "comment"))
|
|
|
|
|
|
2024-01-06 15:05:50 +09:00
|
|
|
; Pass code blocks to Cpp highlighter
|
|
|
|
|
(code
|
|
|
|
|
(code_body) @injection.content
|
2023-05-03 19:07:59 +09:00
|
|
|
(#set! injection.language "cpp"))
|
2021-12-14 13:45:56 +01:00
|
|
|
|
2024-01-06 15:05:50 +09:00
|
|
|
; Pass identifiers to Go highlighter (Cheating I know)
|
|
|
|
|
; ((identifier) @injection.content
|
|
|
|
|
; (#set! injection.language "lua")
|
|
|
|
|
; Highlight regex syntax inside literal strings
|
|
|
|
|
((string_literal) @injection.content
|
|
|
|
|
(#set! injection.language "regex"))
|
2021-12-14 13:45:56 +01:00
|
|
|
|
2024-01-06 15:05:50 +09:00
|
|
|
; Highlight PyFoam syntax as Python statements
|
2023-05-03 19:07:59 +09:00
|
|
|
(pyfoam_variable
|
|
|
|
|
code_body: (_) @injection.content
|
|
|
|
|
(#set! injection.language "python"))
|
2024-01-06 15:05:50 +09:00
|
|
|
|
2023-05-03 19:07:59 +09:00
|
|
|
(pyfoam_expression
|
|
|
|
|
code_body: (_) @injection.content
|
|
|
|
|
(#set! injection.language "python"))
|