Skip to content

Commit

Permalink
fix null pointer exception in SourceViewerDecorationSupport
Browse files Browse the repository at this point in the history
fInlineAnnotationColorKey might be not set
  • Loading branch information
tobias-melcher authored and BeckerWdf committed Oct 17, 2024
1 parent abffd92 commit 28c2d5d
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -890,7 +890,7 @@ protected AnnotationPainter createAnnotationPainter() {
painter.addTextStyleStrategy(AnnotationPreference.STYLE_UNDERLINE, fgUnderlineStrategy);

ColorRegistry registry = JFaceResources.getColorRegistry();
if (registry != null) {
if (registry != null && fInlineAnnotationColorKey != null) {
Color color = registry.get(fInlineAnnotationColorKey);
painter.setInlineAnnotationColor(color);
if (fPropertyChangeListener != null) {
Expand Down

0 comments on commit 28c2d5d

Please sign in to comment.