Skip to content

Commit 2822178

Browse files
authored
Merge pull request #840 from devoxx/fix/plugin-verifier-warnings
fix: resolve plugin verifier warnings for experimental and deprecated…
2 parents 7f878bf + 79e468c commit 2822178

File tree

3 files changed

+19
-5
lines changed

3 files changed

+19
-5
lines changed

build.gradle.kts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,17 @@ tasks {
160160
}
161161
}
162162

163+
runPluginVerifier {
164+
ideVersions.set(listOf(
165+
"IC-2023.3.8",
166+
"IC-2024.1.7",
167+
"IC-2024.2.6",
168+
"IC-2024.3.7",
169+
"IC-2025.1.7",
170+
"IC-2025.2.6.1"
171+
))
172+
}
173+
163174
signPlugin {
164175
certificateChain.set(System.getenv("CERTIFICATE_CHAIN"))
165176
privateKey.set(System.getenv("PRIVATE_KEY"))

src/main/java/com/devoxx/genie/ui/renderer/CodeBlockNodeRenderer.java

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
import com.devoxx.genie.ui.util.LanguageGuesser;
44
import com.intellij.lang.Language;
5-
import com.intellij.lang.documentation.DocumentationSettings;
65
import com.intellij.openapi.application.ApplicationManager;
76
import com.intellij.openapi.editor.richcopy.HtmlSyntaxInfoUtil;
87
import com.intellij.openapi.fileTypes.PlainTextLanguage;
@@ -35,6 +34,7 @@
3534
* String html = renderer.render(node);
3635
*/
3736
public class CodeBlockNodeRenderer implements NodeRenderer {
37+
private static final float DEFAULT_HIGHLIGHTING_SATURATION = 1.0f;
3838
private final Project project;
3939
private final HtmlWriter htmlOutputWriter;
4040

@@ -125,7 +125,7 @@ private enum HighlightingMode {
125125
language,
126126
codeSnippet,
127127
false,
128-
DocumentationSettings.getHighlightingSaturation(true)
128+
DEFAULT_HIGHLIGHTING_SATURATION
129129
)
130130
);
131131
} else {
@@ -135,10 +135,8 @@ private enum HighlightingMode {
135135
}
136136

137137
private HighlightingMode determineHighlightingMode(boolean block) {
138-
if (block && DocumentationSettings.isHighlightingOfCodeBlocksEnabled()) {
138+
if (block) {
139139
return HighlightingMode.SEMANTIC_HIGHLIGHTING;
140-
} else if (block) {
141-
return HighlightingMode.NO_HIGHLIGHTING;
142140
} else {
143141
return HighlightingMode.INLINE_HIGHLIGHTING;
144142
}

src/main/resources/META-INF/plugin.xml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -311,6 +311,11 @@
311311
<postStartupActivity implementation="com.devoxx.genie.service.PostStartupActivity"/>
312312
</extensions>
313313

314+
<!-- Declare K2 Kotlin plugin mode compatibility (required since IntelliJ IDEA 2024.2.1) -->
315+
<extensions defaultExtensionNs="org.jetbrains.kotlin">
316+
<supportsKotlinPluginMode supportsK2="true"/>
317+
</extensions>
318+
314319
<actions>
315320

316321
<action id="DevoxxGenie.AddSnippetAction"

0 commit comments

Comments
 (0)