From f5746c40cbb44204edd137b3183ef0d04958047b Mon Sep 17 00:00:00 2001 From: Simon Ogorodnik Date: Sat, 26 May 2018 00:19:54 +0300 Subject: KT-24624: Partial, more detailed signature on class page --- core/src/main/kotlin/Kotlin/KotlinLanguageService.kt | 20 ++++---------------- 1 file changed, 4 insertions(+), 16 deletions(-) (limited to 'core/src/main/kotlin/Kotlin') diff --git a/core/src/main/kotlin/Kotlin/KotlinLanguageService.kt b/core/src/main/kotlin/Kotlin/KotlinLanguageService.kt index b6474583..237fa9b9 100644 --- a/core/src/main/kotlin/Kotlin/KotlinLanguageService.kt +++ b/core/src/main/kotlin/Kotlin/KotlinLanguageService.kt @@ -7,6 +7,10 @@ import org.jetbrains.dokka.LanguageService.RenderMode * Implements [LanguageService] and provides rendering of symbols in Kotlin language */ class KotlinLanguageService : CommonLanguageService() { + override fun showModifierInSummary(node: DocumentationNode): Boolean { + return node.name !in fullOnlyModifiers + } + private val fullOnlyModifiers = setOf("public", "protected", "private", "inline", "noinline", "crossinline", "reified") @@ -283,22 +287,6 @@ class KotlinLanguageService : CommonLanguageService() { } } - private fun ContentBlock.renderModifiersForNode( - node: DocumentationNode, - renderMode: RenderMode, - nowrap: Boolean = false - ) { - val modifiers = node.details(NodeKind.Modifier) - for (it in modifiers) { - if (node.kind == org.jetbrains.dokka.NodeKind.Interface && it.name == "abstract") - continue - if (renderMode == RenderMode.SUMMARY && it.name in fullOnlyModifiers) { - continue - } - renderModifier(this, it, renderMode, nowrap) - } - } - private fun ContentBlock.renderAnnotationsForNode(node: DocumentationNode) { node.annotations.forEach { renderAnnotation(it) -- cgit