Jetbrains Compose (https://www.jetbrains.com/lp/compose/) is a ui toolkit targeting jvm on desktop platforms. It is a port of Android Jetpack Compose (https://developer.android.com/jetpack/compose) which is developed by google
Questions tagged [jetbrains-compose]
52 questions
2
votes
2 answers
Jetpack Compose mutableStateList vs mutableList Performance
How do mutableState, mutableStateList, mutableStateMap perform in comparison to a normal variable, mutableList, mutableMap? If there are observers listening they will be slower of course (because recomposition is triggered) but is there a difference…

nhcodes
- 1,206
- 8
- 20
2
votes
1 answer
Divider composable becomes invisible when placed inside composable with horizontalScroll modifier set. Is this a bug?
Background
I am making a desktop compose application.
I had a LazyColumn with Divider separating items. LazyColumn's width may not fit in window so I made the LazyColumn horizontally scrollable by enclosing it inside a Box with horizontalScroll()…

Om Kumar
- 1,404
- 13
- 19
1
vote
2 answers
How to use Context in a compose multiplatform projeect?
I'm trying to migrate an Android Jetpack Compose project to compose multiplatform. How can we use context in the composables.
val context = LocalContext.current
I can't access the LocalContext

Anmol Singh Sahi
- 75
- 5
1
vote
3 answers
How to trigger LaunchedEffect when mutableStateList is changed?
In Jetpack/Desktop Compose I want a coroutine to run in response to changes to a SnapshotStateList.
In this example:
import androidx.compose.foundation.layout.Column
import androidx.compose.material.Button
import…

David Hadley
- 184
- 2
- 8
1
vote
0 answers
Compose for web: Uploading a file submitted via a multipart form
I am trying to upload a file from Compose for Web form using Ktor.
My server code is based on the example found in the Ktor…

HPage
- 1,412
- 20
- 27
1
vote
0 answers
Efficient rendering of many Jetbrains Compose elements at absolute coordinates within a graphics layer
I am trying to render a large number of "nodes" in a freeform sandbox area with Jetbrains Compose. Each node has it's own X,Y position. The editor is in a graphicsLayer where it can be panned and scaled. Inside this sandbox area, each node is offset…

Ejektaflex
- 11
- 3
1
vote
1 answer
How can I specify the version of Gradle Kotlin plugin in subproject that different from the root one
I'm working on a multiproject, the Kotlin plugin version in ./build.gradle.kts is 1.7.0, but as I'm using compose-jb in the subproject, it requires 1.6.X because it throws exceptions on 1.7.0. And there is no other compose-jb version supporting…

Taskeren
- 35
- 3
1
vote
1 answer
What is the best way to persist state in composable recreation in Jetpack Compose?
Consider we have the following structure in a toggling implementation scenario:
@Composable
fun RootComposable() {
var someAuxToggle by remember { mutableStateOf(false) }
if (someAuxToggle) {
FirstComposable { someAuxToggle = !someAuxToggle…

Lucas Sousa
- 192
- 3
- 14
1
vote
0 answers
How to implement Accessibility in Desktop Compose
I am building an app with Desktop Compose Multiplatform for Windows and MacOS platform.
I need to add accessibility support for users.
In Android we have Accessibility Scanner and TalkBack to announce contentDescription and these tools also helps…

SVK
- 676
- 1
- 5
- 17
1
vote
1 answer
Can I change the value of a component from a separate button in Compose Multiplatform?
I am trying to make a desktop application that allows you to search through a number of predefined locations stored in Kotlin classes in a separate directory. To accomplish this, I've used the reflections and compose-jb libraries.
The problem I've…

Mob
- 13
- 2
1
vote
1 answer
Specific Module routes in Jetbrains Compose with Decompose on kotlin desktop application
I'm using JetBrains Compose framework on a desktop application project, and for routing they suggest in the official documentation arkivanov-Decompose library for routing between views (Composables).
Works like a charm, but the more views you have,…

Pstr
- 777
- 1
- 8
- 17
1
vote
1 answer
Compose Desktop application crashing: ClassNotFoundException: java.net.http.HttpClient
I want to use the java.net.http package in my compose desktop application. When I run the application in IntelliJ, everything works fine. But when I build a .deb file using packageDeb and install it via apt, the application crashes due to a…

nhcodes
- 1,206
- 8
- 20
1
vote
0 answers
How to enable selection between multiple BasicTextField in Kotlin Compose
As you can see here, there is a composable function available to use as a wrapper for Text functions:
SelectionContainer {
Column {
Text("test1")
Text("test2")
Text("test3")
}
}
However, it…

Shynline
- 1,497
- 1
- 13
- 18
1
vote
1 answer
LazyColumn does not scroll if using TextFields as child
@Composable
fun init() {
LazyColumn(Modifier.fillMaxSize()) {
for (i in 0..10) {
item { Box(Modifier.padding(15.dp)) { TextField("Hallo$i", modifier = Modifier.fillMaxWidth(), onValueChange = {}) } }
}
}
}
If i…

Zen1000
- 147
- 9
1
vote
0 answers
how to close the dropdown popup on clicking of outside the dropdown popup window?
I am Using jetbrain compose 2020.3.3 version and i am implementing Dropdown example similar as mentioned below code. as per my analysis "DropDownmenu" internally using the "Popup" and by default popup focusable is false and there is no option in…

Mahesh Mule
- 41
- 5