TextAttributesKey (final @NotNull List<? extends ScopeToolState> scopeToolStates, @NotNull Project project) { TextAttributesKey previousValue = null; final SeverityRegistrar registrar = SeverityRegistrar.getSeverityRegistrar(project); for (final ScopeToolState scopeToolState : scopeToolStates) { TextAttributesKey key = scopeToolState.getEditorAttributesKey(); if (key == null) { final var severity = scopeToolState.getLevel().getSeverity(); key = severity.equals(HighlightSeverity.INFORMATION) ? INFORMATION_FAKE_KEY : registrar.getHighlightInfoTypeBySeverity(severity).getAttributesKey(); } if (previousValue == null) { previousValue = key; } else if (!previousValue.equals(key)){ return MIXED_FAKE_KEY; } } return previousValue != null ? previousValue : MIXED_FAKE_KEY; }