
Open the Gradle toolbar on the right and select sample/Tasks/compose desktop/run. Open as a project in IntelliJ IDEA.Īfter you download the Compose for Desktop dependencies from the Maven repositories, your new project is ready Import .Arrangement import .Column import .fillMaxSize import import import import import import .Alignment import .Modifier import .unit.dp import .window.Window import .window.application import .window.rememberWindowState fun main() = application ! ")īutton(modifier = Modifier.align( Alignment. Update to the latest plugin version by editing the file and updating the version information as shown below.įor the latest versions, see the latest versions site and the Kotlin site. The Compose plugin version used in the wizard above might not be the latest. This plugin can also be installed via the plugins marketplace. You can see how a particular composable function looksĭirectly in the IDE panel. Note that JDK must be at least JDK 11, and to use the native distributionĬan simplify compose development by adding support for the annotation on functions. Which creates a Compose application automatically. Starting with the version 2020.3, Kotlin support in IDEA comes with the new project wizard, IntelliJ IDEA Community Edition or Ultimate Edition 2020.3 or later (other editors could be used, but we assume you are using IntelliJ IDEA in this tutorial)Ĭreating a new project New project wizard.The following software must be preinstalled: So any of these platforms can be used for this tutorial. PrerequisitesĬompose for Desktop can produce applications for macOS, Linux and Windows platforms. Using the Compose Multiplatform UI framework. In this tutorial we will create a simple desktop UI application Getting Started with Compose Multiplatform What is covered
