Wizard: update project & module templates texts
This commit is contained in:
+4
-2
@@ -15,6 +15,7 @@ import org.jetbrains.kotlin.tools.projectWizard.wizard.ui.setting.SettingCompone
|
||||
import org.jetbrains.kotlin.tools.projectWizard.wizard.ui.setting.ValidationIndicator
|
||||
import java.awt.Dimension
|
||||
import javax.swing.JComponent
|
||||
import javax.swing.SwingConstants
|
||||
|
||||
class ProjectTemplateSettingComponent(
|
||||
context: Context
|
||||
@@ -38,7 +39,7 @@ class ProjectTemplateSettingComponent(
|
||||
|
||||
override val component: JComponent = borderPanel {
|
||||
addToCenter(borderPanel { addToCenter(list) }.addBorder(JBUI.Borders.empty(0,/*left*/ 3, 0, /*right*/ 3)))
|
||||
addToBottom(templateDescriptionComponent.component.addBorder(JBUI.Borders.empty(/*top*/8,/*left*/ 3, /*bottom*/10, 0)))
|
||||
addToBottom(templateDescriptionComponent.component.addBorder(JBUI.Borders.empty(/*top*/8,/*left*/ 3, 0, 0)))
|
||||
}
|
||||
|
||||
private fun applySelectedTemplate() = modify {
|
||||
@@ -65,7 +66,8 @@ class ProjectTemplateSettingComponent(
|
||||
class TemplateDescriptionComponent : Component() {
|
||||
private val descriptionLabel = label("").apply {
|
||||
fontColor = UIUtil.FontColor.BRIGHTER
|
||||
preferredSize = Dimension(preferredSize.width, 50)
|
||||
preferredSize = Dimension(preferredSize.width, 55)
|
||||
verticalAlignment = SwingConstants.TOP
|
||||
}
|
||||
|
||||
fun setTemplate(template: ProjectTemplate) {
|
||||
|
||||
+1
-1
@@ -123,7 +123,7 @@ private class ModuleTemplateComponent(
|
||||
|
||||
private object NoneTemplate : Template() {
|
||||
override val title = "None"
|
||||
override val htmlDescription: String = ""
|
||||
override val description: String = ""
|
||||
override val moduleTypes: Set<ModuleType> = ModuleType.ALL
|
||||
override val id: String = "none"
|
||||
}
|
||||
|
||||
+2
-4
@@ -13,10 +13,8 @@ import org.jetbrains.kotlin.tools.projectWizard.settings.buildsystem.SourcesetTy
|
||||
|
||||
class ConsoleJvmApplicationTemplate : Template() {
|
||||
override val id: String = "consoleJvmApp"
|
||||
override val title: String = "Console JVM Module with main method"
|
||||
override val htmlDescription: String = """
|
||||
Console JVM module with main method and run task generated
|
||||
""".trimIndent()
|
||||
override val title: String = "Console Application"
|
||||
override val description: String = """Simple “Hello World!” Kotlin/JVM application that works in the console"""
|
||||
override val moduleTypes: Set<ModuleType> = setOf(ModuleType.jvm)
|
||||
|
||||
override fun Writer.getIrsToAddToBuildFile(
|
||||
|
||||
+2
-2
@@ -24,8 +24,8 @@ import org.jetbrains.kotlin.tools.projectWizard.settings.version.Version
|
||||
import org.jetbrains.kotlin.tools.projectWizard.transformers.interceptors.InterceptionPoint
|
||||
|
||||
class KtorServerTemplate : Template() {
|
||||
override val title: String = "Ktor-based Server"
|
||||
override val htmlDescription: String = title
|
||||
override val title: String = "Ktor Server"
|
||||
override val description: String = "Configurable Ktor web server for building web applications"
|
||||
override val moduleTypes: Set<ModuleType> = setOf(ModuleType.jvm)
|
||||
override val id: String = "ktorServer"
|
||||
|
||||
|
||||
+2
-2
@@ -17,8 +17,8 @@ import org.jetbrains.kotlin.tools.projectWizard.plugins.kotlin.ModuleType
|
||||
import org.jetbrains.kotlin.tools.projectWizard.settings.buildsystem.SourcesetType
|
||||
|
||||
class NativeConsoleApplicationTemplate : Template() {
|
||||
override val title: String = "Native Console Application"
|
||||
override val htmlDescription: String = title
|
||||
override val title: String = "Native Application"
|
||||
override val description: String = "Simple Kotlin/Native application for your operating system"
|
||||
override val moduleTypes: Set<ModuleType> = setOf(ModuleType.native)
|
||||
override val id: String = "nativeConsoleApp"
|
||||
|
||||
|
||||
+2
-2
@@ -27,8 +27,8 @@ import org.jetbrains.kotlin.tools.projectWizard.transformers.interceptors.Templa
|
||||
import org.jetbrains.kotlin.tools.projectWizard.transformers.interceptors.interceptTemplate
|
||||
|
||||
class SimpleJsClientTemplate : Template() {
|
||||
override val title: String = "JS client"
|
||||
override val htmlDescription: String = title
|
||||
override val title: String = "Frontend Application"
|
||||
override val description: String = "Configurable Kotlin/JS frontend application"
|
||||
override val moduleTypes: Set<ModuleType> = setOf(ModuleType.js)
|
||||
override val id: String = "simpleJsClient"
|
||||
|
||||
|
||||
+1
-1
@@ -67,7 +67,7 @@ abstract class Template : SettingsOwner, EntitiesOwnerDescriptor, DisplayableSet
|
||||
}
|
||||
|
||||
abstract val title: String
|
||||
abstract val htmlDescription: String
|
||||
abstract val description: String
|
||||
abstract val moduleTypes: Set<ModuleType>
|
||||
|
||||
override val text: String get() = title
|
||||
|
||||
Reference in New Issue
Block a user