Solution 1 :
It actually works!
For some reason I was trying to use click and drag… which lead me to confusion.
Problem :
I am trying to add scrolling behaviour to a Column
by setting verticalScroll(state = rememberScrollState())
modifier.
I checked out some examples in the official compose-jb repository, and it seems that that is the right way to do it, yet in my case the content is not scrollable.
Here the full code:
@Composable
@Preview
fun App() {
MaterialTheme {
// add scroll behaviour
val stateVertical = rememberScrollState(0)
Column(modifier = Modifier.verticalScroll(state = stateVertical)) {
repeat(100){
Text("item: $it")
}
}
}
}
fun main() = application {
Window(onCloseRequest = ::exitApplication) {
App()
}
}
Any ideas why it does not work in my case?
The Column is populated with 100 Text
items, more than enough to exceed the default window height.