Skip to content

Commit 9a4372c

Browse files
committed
Fix for #132
1 parent d30116e commit 9a4372c

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

src/main/kotlin/com/github/dinbtechit/vscodetheme/annotators/JavaAnnotator.kt

+6-3
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ package com.github.dinbtechit.vscodetheme.annotators
33
import com.intellij.openapi.editor.DefaultLanguageHighlighterColors
44
import com.intellij.openapi.editor.colors.TextAttributesKey
55
import com.intellij.psi.PsiElement
6+
import com.intellij.psi.PsiKeyword
67
import com.intellij.psi.PsiTypeElement
78
import com.intellij.util.ObjectUtils
89

@@ -31,9 +32,11 @@ class JavaAnnotator : BaseAnnotator() {
3132
else -> {}
3233
}
3334

34-
when (element.parent) {
35-
is PsiTypeElement -> type = TYPE_KEYWORD
36-
else -> {}
35+
if (element !is PsiKeyword) {
36+
when (element.parent) {
37+
is PsiTypeElement -> type = TYPE_KEYWORD
38+
else -> {}
39+
}
3740
}
3841

3942
return type

0 commit comments

Comments
 (0)