Skip to content

Commit

Permalink
Merge pull request #39 from pustota-theme/java-support
Browse files Browse the repository at this point in the history
Java support
  • Loading branch information
igor-gorohovsky authored Jan 21, 2025
2 parents b85918e + ad42168 commit e32d887
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ A clean, minimalist Neovim colorscheme inspired by the original [pustota VSCode
- JS/JSX
- HTML
- CSS
- Java
- C#
- Rust
- C++
Expand Down
11 changes: 11 additions & 0 deletions after/queries/java/highlights.scm
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
;; extends

((record_declaration name: (identifier) @type.definition))
((enum_declaration name: (identifier) @type.definition))
((interface_declaration name: (identifier) @type.definition))
((class_declaration name: (identifier) @type.definition))

((constructor_declaration name: (identifier) @function))

((marker_annotation ("@") @operator.decorator))
((method_reference ("::") @operator.access))
5 changes: 5 additions & 0 deletions lua/pustota.lua
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,11 @@ M.hl_langs = function()
hl(0, "@type.delimiter.css", { link = "Function" })
hl(0, "@punctuation.delimiter.css", {})

-- Java specific
hl(0, "@constructor.java", { link = "Function" })
hl(0, "@operator.decorator.java", { link = "Operator" })
hl(0, "@operator.access.java", { fg = colors.gray })

-- C# specific
hl(0, "@module.c_sharp", { link = "Type" })
hl(0, "@property.c_sharp", { fg = colors.gray })
Expand Down

0 comments on commit e32d887

Please sign in to comment.