Is more work planned for Scroll Bars? My initial f...
# compose-desktop
s
Is more work planned for Scroll Bars? My initial feedback after spending an hour with them: • I put my screen in a
ScrollableColumn
and got an error. I was annoyed that I had to refactor my screen because I had a
LazyColumnFor
nested inside it. • Using the
item
syntax inside
LazyColumn
was surprisingly delightful for building lazy content. I was pretty happy with how easy it made things. • Not having access to ScrollBars in the common layer was pretty brutal. • The current api for lazy column with scroll bars forces me to give an average item height and a count. This api was pretty cumbersome to use. This takes away most of the benefits from using the
item
syntax with
LazyColumn
. • I’m going to avoid using `ScrollBar`s for now as I have to modify the way I’m developing too much, and the APIs are too error prone.
o
right, scrollbars API needs further work, especially around commonizing it in a sensible way
i
Not having access to ScrollBars in the common layer was pretty brutal.
For now you can define your own scrollbars in a common code: https://github.com/JetBrains/compose-jb/blob/master/examples/codeviewer/common/src[…]ommonMain/kotlin/org/jetbrains/codeviewer/platform/Scrollbar.kt
The current api for lazy column with scroll bars forces me to give an average item height and a count.
It is a temporary solution. We plan to get rid of these parameters in the future.
s
Glad to hear most of this feedback was already known. I’m in love with compose desktop. It’s quite good.
1