https://kotlinlang.org logo
Docs
Join the conversationJoin Slack
Channels
100daysofcode
100daysofkotlin
100daysofkotlin-2021
advent-of-code
aem
ai
alexa
algeria
algolialibraries
amsterdam
android
android-architecture
android-databinding
android-studio
androidgithubprojects
androidthings
androidx
androidx-xprocessing
anime
anko
announcements
apollo-kotlin
appintro
arabic
argentina
arkenv
arksemdevteam
armenia
arrow
arrow-contributors
arrow-meta
ass
atlanta
atm17
atrium
austin
australia
austria
awesome-kotlin
ballast
bangladesh
barcelona
bayarea
bazel
beepiz-libraries
belgium
berlin
big-data
books
boston
brazil
brikk
budapest
build
build-tools
bulgaria
bydgoszcz
cambodia
canada
carrat
carrat-dev
carrat-feed
chicago
chile
china
chucker
cincinnati-user-group
cli
clikt
cloudfoundry
cn
cobalt
code-coverage
codeforces
codemash-precompiler
codereview
codingame
codingconventions
coimbatore
collaborations
colombia
colorado
communities
competitive-programming
competitivecoding
compiler
compose
compose-android
compose-desktop
compose-hiring
compose-ios
compose-mp
compose-ui-showcase
compose-wear
compose-web
connect-audit-events
corda
cork
coroutines
couchbase
coursera
croatia
cryptography
cscenter-course-2016
cucumber-bdd
cyprus
czech
dagger
data2viz
databinding
datascience
dckotlin
debugging
decompose
decouple
denmark
deprecated
detekt
detekt-hint
dev-core
dfw
docs-revamped
dokka
domain-driven-design
doodle
dsl
dublin
dutch
eap
eclipse
ecuador
edinburgh
education
effective-kotlin
effectivekotlin
emacs
embedded-kotlin
estatik
event21-community-content
events
exposed
failgood
fb-internal-demo
feed
firebase
flow
fluid-libraries
forkhandles
forum
fosdem
fp-in-kotlin
framework-elide
freenode
french
fritz2
fuchsia
functional
funktionale
gamedev
ge-kotlin
general-advice
georgia
geospatial
german-lang
getting-started
github-workflows-kt
glance
godot-kotlin
google-io
gradle
graphic
graphkool
graphql
graphql-kotlin
graviton-browser
greece
grpc
gsoc
gui
hackathons
hacktoberfest
hamburg
hamkrest
helios
helsinki
hexagon
hibernate
hikari-cp
hire-me
hiring
hongkong
hoplite
http4k
hungary
hyderabad
image-processing
india
indonesia
inkremental
intellij
intellij-plugins
intellij-tricks
internships
introduce-yourself
io
ios
iran
israel
istanbulcoders
italian
jackson-kotlin
jadx
japanese
jasync-sql
java-to-kotlin-refactoring
javadevelopers
javafx
javalin
javascript
jdbi
jhipster-kotlin
jobsworldwide
jpa
jshdq
juul-libraries
jvm-ir-backend-feedback
jxadapter
k2-early-adopters
kaal
kafka
kakao
kalasim
kapt
karachi
karg
karlsruhe
kash_shell
kaskade
kbuild
kdbc
kgen-doc-tools
kgraphql
kinta
klaxon
klock
kloudformation
kmdc
kmm-español
kmongo
knbt
knote
koalaql
koans
kobalt
kobweb
kodein
kodex
kohesive
koin
koin-dev
komapper
kondor-json
kong
kontent
kontributors
korau
korean
korge
korim
korio
korlibs
korte
kotest
kotest-contributors
kotless
kotlick
kotlin-asia
kotlin-beam
kotlin-by-example
kotlin-csv
kotlin-data-storage
kotlin-foundation
kotlin-fuel
kotlin-in-action
kotlin-inject
kotlin-latam
kotlin-logging
kotlin-multiplatform-contest
kotlin-mumbai
kotlin-native
kotlin-pakistan
kotlin-plugin
kotlin-pune
kotlin-roadmap
kotlin-samples
kotlin-sap
kotlin-serbia
kotlin-spark
kotlin-szeged
kotlin-website
kotlinacademy
kotlinbot
kotlinconf
kotlindl
kotlinforbeginners
kotlingforbeginners
kotlinlondon
kotlinmad
kotlinprogrammers
kotlinsu
kotlintest
kotlintest-devs
kotlintlv
kotlinultimatechallenge
kotlinx-datetime
kotlinx-files
kotlinx-html
kotrix
kotson
kovenant
kprompt
kraph
krawler
kroto-plus
ksp
ktcc
ktfmt
ktlint
ktor
ktp
kubed
kug-leads
kug-torino
kvision
kweb
lambdaworld_cadiz
lanark
language-evolution
language-proposals
latvia
leakcanary
leedskotlinusergroup
lets-have-fun
libgdx
libkgd
library-development
linkeddata
lithuania
london
losangeles
lottie
love
lychee
macedonia
machinelearningbawas
madrid
malaysia
mathematics
meetkotlin
memes
meta
metro-detroit
mexico
miami
micronaut
minnesota
minutest
mirror
mockk
moko
moldova
monsterpuzzle
montreal
moonbean
morocco
motionlayout
mpapt
mu
multiplatform
mumbai
munich
mvikotlin
mvrx
myndocs-oauth2-server
naming
navigation-architecture-component
nepal
new-mexico
new-zealand
newname
nigeria
nodejs
norway
npm-publish
nyc
oceania
ohio-kotlin-users
oldenburg
oolong
opensource
orbit-mvi
osgi
otpisani
package-search
pakistan
panamá
pattern-matching
pbandk
pdx
peru
philippines
phoenix
pinoy
pocketgitclient
polish
popkorn
portugal
practical-functional-programming
proguard
prozis-android-backup
pyhsikal
python
python-contributors
quasar
random
re
react
reaktive
realm
realworldkotlin
reductor
reduks
redux
redux-kotlin
refactoring-to-kotlin
reflect
refreshversions
reports
result
rethink
revolver
rhein-main
rocksdb
romania
room
rpi-pico
rsocket
russian
russian_feed
russian-kotlinasfirst
rx
rxjava
san-diego
science
scotland
scrcast
scrimage
script
scripting
seattle
serialization
server
sg-user-group
singapore
skia-wasm-interop-temp
skrape-it
slovak
snake
sofl-user-group
southafrica
spacemacs
spain
spanish
speaking
spek
spin
splitties
spotify-mobius
spring
spring-security
squarelibraries
stackoverflow
stacks
stayhungrystayfoolish
stdlib
stlouis
strife-discord-lib
strikt
students
stuttgart
sudan
swagger-gradle-codegen
swarm
sweden
swing
swiss-user-group
switzerland
talking-kotlin
tallinn
tampa
teamcity
tegal
tempe
tensorflow
terminal
test
testing
testtestest
texas
tgbotapi
thailand
tornadofx
touchlab-tools
training
tricity-kotlin-user-group
trójmiasto
truth
tunisia
turkey
turkiye
twitter-feed
uae
udacityindia
uk
ukrainian
uniflow
unkonf
uruguay
utah
uuid
vancouver
vankotlin
vertx
videos
vienna
vietnam
vim
vkug
vuejs
web-mpp
webassembly
webrtc
wimix_sentry
wwdc
zircon
Powered by Linen
compose-desktop
  • e

    enighma

    10/06/2022, 1:06 AM
    When I update my Kotlin MPP to
    1.2.0-beta02
    I get a sync error
    > Failed to notify project evaluation listener.
       > Could not create task ':android:compileDebugAndroidTestKotlin'.
          > Cannot invoke "String.trim()" because "in" is null
       > KotlinJvmAndroidCompilation with name 'debugAndroidTest' not found.
    Interestingly it worked without a hitch on a desktop only project, but the gradle files look a bit different. Should I be able to use this version in a MPP project?
    h
    r
    • 3
    • 6
  • q

    Quan Le

    10/07/2022, 2:51 AM
    Hello, I try to use WebView in my app. I follow this example https://stackoverflow.com/questions/67959032/how-to-use-webview-in-jetpack-compose-for-desktop-app. It runs fine when I hit play on IDE, but when I package to msi and install, the webview doesn’t work. Did any one face the same issue?
    m
    m
    • 3
    • 5
  • z

    zt

    10/08/2022, 4:19 AM
    I'm running the packageReleaseExe and packageReleaseMsi tasks with no errors, but theres no exe or msi file to be found in the build directory. Is it not possible to build them on linux?
    d
    • 2
    • 3
  • a

    altavir

    10/09/2022, 7:54 AM
    What is the best place to report bugs? Here is an obvious one. Without override it get guaranteed SO.
    a
    m
    l
    • 4
    • 37
  • a

    Abdelilah El Aissaoui

    10/09/2022, 5:04 PM
    I've been noticing big FPS drops when a complex list of items has the
    clickable
    modifier for each item of the list. Whenever I remove that modifier, it works just fine. Has someone faced a similar issue? 🤔 I'll try to create a sample to reproduce it
    s
    r
    • 3
    • 4
  • l

    Lucas

    10/10/2022, 4:56 PM
    Are there any plans to support 32 bit jvm?
    i
    s
    • 3
    • 3
  • x

    xxfast

    10/11/2022, 12:22 AM
    https://twitter.com/AndroidDev/status/1579496646341144576?t=e__ak_jUiRoVo__PVVcw3g&s=19 Does this mean we can start moving our `@Preview`s back to
    commonMain
    ?
    k
    b
    +2
    • 5
    • 7
  • e

    enighma

    10/11/2022, 8:17 PM
    What is the best source of how to see how the build files should be written? IntelliJ's wizard seems to create a project of an older flavor.
    b
    s
    g
    • 4
    • 8
  • a

    Arkadii Ivanov

    10/11/2022, 10:16 PM
    Version 1.2.0! https://github.com/JetBrains/compose-jb/releases/tag/v1.2.0
    d
    b
    +4
    • 7
    • 13
  • z

    zt

    10/12/2022, 12:38 AM
    I have this in my dependencies
    @OptIn(ExperimentalComposeLibrary::class)
    implementation(compose.material3)
    It's wanting me to add
    This annotation should be used with the compiler argument '-opt-in=kotlin.RequiresOptIn'
    for @OptIn I tried this but it the warning is still there
    tasks.withType<KotlinCompile> {
        kotlinOptions {
            freeCompilerArgs = freeCompilerArgs + "-opt-in=kotlin.RequiresOptIn"
        }
    }
    s
    c
    • 3
    • 5
  • y

    Yan Pujante

    10/12/2022, 1:19 PM
    Can somebody explain when/how compose desktop became compose multiplatform? Was there an announcement that I missed?
    c
    i
    +3
    • 6
    • 19
  • a

    Arjan van Wieringen

    10/12/2022, 6:25 PM
    Hey everyone, I just wanted to show I was experimenting with Compose Desktop multiplatform (based on the experimental folder in de JB repo) and was quite amazed. Ofcourse I ran into a lot of weirdness, but nonetheless I was able to pull the following movie off quite fast. It is a common module which contains everything: logic, viewmodel and compose view. The platform specific modules only bootstrap my
    MandelbrotViewer
    composable. In the movie we have JVM, iOS iPad Simulator and JS. Quite the difference in platform! Biggest issue is that I got VM allocation errors when using
    withContext(Dispatchers.Default)
    on iOS targets so it is blocking the main thread. I also can't get it to work on Arm64 on Mac. But it's experimental. So... there's that. I really enjoyed this, and it was very very easy. I can't understate how awesome it would be to have a true multiplatform UI library in Kotlin. I'll post the code later on GitHub.
    s
    l
    +2
    • 5
    • 10
  • l

    Lucas

    10/12/2022, 9:08 PM
    Question for everyone: What is your preferred architecture for compose multiplatform projects?
    c
    • 2
    • 3
  • s

    Sean Proctor

    10/12/2022, 9:15 PM
    Can anyone give some advice on using proguard? It seems to break sealed interfaces. I'm getting an error: ClassA cannot implement sealed interface InterfaceB. ClassA implements InterfaceA.
    • 1
    • 1
  • c

    czuckie

    10/12/2022, 11:44 PM
    Has anyone got a compose desktop app running on a pine phone pro?
    b
    l
    • 3
    • 3
  • l

    Lucas

    10/13/2022, 1:15 AM
    Asked in multiplatform but this channel is more active Is there any way to anotate a class in common module with java-only lib anotations? expected/actual didnt work because the anotation has enum inside and i couldnt get it to work
    r
    a
    l
    • 4
    • 4
  • s

    Stefan Oltmann

    10/13/2022, 10:33 AM
    I'm migrating to the new version of
    LazyVerticalGrid
    which has a
    LazyGridState
    instead of a
    LazyListState
    . I want to display a scrollbar. I used
    VerticalScrollbar
    together with the
    LazyScrollbarAdapter
    ... This only works with
    LazyListState
    ... is something similar available for
    LazyGridState
    ? Someone mentioned https://github.com/Suwayomi/Tachidesk-JUI/blob/master/ui-core/src/desktopMain/kotlin/ca/gosyer/jui/uicore/components/DesktopScrollbar.kt#L105 , but it's broken for
    GridCells.Adaptive
    Edit: Okay, it's already known as https://github.com/JetBrains/compose-jb/issues/2029
  • k

    Kirill Grouchnikov

    10/13/2022, 2:14 PM
    Happy to announce that

    Aurora 1.2.0▾

    has been released. A couple of new APIs (tabs and tab rows), and a bunch of fixes.
    b
    a
    • 3
    • 5
  • a

    Arjan van Wieringen

    10/13/2022, 2:27 PM
    Here is the git repo for the Mandelbrot Composed Multiplatform super-experimental experiment from above: https://github.com/avwie/mandelbrot-compose-multiplatform
  • k

    Kirill Grouchnikov

    10/13/2022, 3:18 PM
    MouseInfo.getPointerInfo().getLocation()
    a
    • 2
    • 6
  • c

    Casey Brooks

    10/13/2022, 4:40 PM
    Just in general, Compose doesn’t play the nicest with mutable classes, and undo/redo will be difficult to implement if you’re modifying those properties directly. It’s best to use all immutable models to make sure any changes get updated in the Compose UI correctly. There are basically 2 ways to implement undo/redo functionality: State-based, and command-based. This article does a decent job of explaining the these two concepts and showing code snippets in JavaScript. I actually just released an experimental feature for my Ballast MVI library today which adds state-based undo-redo functionality automatically in version 2.2.0. The MVI pattern gets you writing your UIs in a manner where you already have both your “commands” and “states” explicitly described and managed for you by the library, and this new feature plugs into that process to track the changes necessary for undo/redo. You can view the documentation here, play with an example, join us over at #ballast for help getting started using Ballast or learning how to use this new feature.
    d
    a
    a
    • 4
    • 26
  • a

    adte

    10/14/2022, 4:28 PM
    Is it a common practice in Compose to have State classes? Like Application/ApplicationState, Window/WindowState, Control/ControlState? And then, there's sort of like a state tree and a ui tree?
    k
    • 2
    • 1
  • o

    orangy

    10/15/2022, 2:46 PM
    Any idea on how to universally scale up/down the whole window content without adding
    * scale
    in every place? Like zooming in browser, so window size becomes virtually smaller when zooming in, and then all sizing/measures/font size are multiplied to become bigger and fit the whole space?
    k
    a
    • 3
    • 6
  • m

    Mohamed Elfiky

    10/17/2022, 7:27 PM
    Is there a way to get position of nested child? I want to draw edges between nodes on different handlers when i use onGloballyPositioned or onPlace and state the edge moves after i drag the node.
    g
    • 2
    • 3
  • s

    spierce7

    10/18/2022, 12:08 AM
    Does anyone know how to diagnose performance problems on Compose Desktop? I’m getting poor performance in one of my composables. I re-wrote it and it got dramatically better. Is there a way for me to figure out where compose is spending its time? Profiling was pretty useless.
    a
    m
    • 3
    • 4
  • a

    Adam Brown

    10/18/2022, 1:38 AM
    i havent touched my project in a bit, just tried to update and build, and gradle is failing to sync now on the compose desktop properties, was there a change in how those work?
    val desktopMain by getting {
                dependencies {
                    api(compose.preview) <-- This fails
                    api(compose.desktop.currentOs)  <-- This fails
                    api("org.jetbrains.kotlinx:kotlinx-serialization-core-jvm:$kotlinx_serialization_version")
                }
            }
    e: \common\build.gradle.kts:93:21: Function invocation 'compose(...)' expected
    This is with Compose Desktop
    1.2.0-beta02
    and IntelliJ 2022.2.3
    • 1
    • 1
  • d

    David W

    10/18/2022, 4:26 AM
    My generated
    <http://jars-config.pro|jars-config.pro>
    is invalid, is there any way to handle that?
    The same output jar [F:\<path>\tmp\main-release\proguard\gluegen-rt-natives-windows-amd64-1d9211c54ac0a72ba2b6397fc93c9894.jar] is specified twice.
    And sure enough, the same
    outjars
    is added twice to that file. I took another look and it seems like this is happening for jars that are included both in remote dependencies as well as
    fileTree
    dependencies. So, maybe that generator is looks at the injars/outjars as a pair for comparison, rather than checking for duplicates of outjars on its own.
    • 1
    • 2
  • r

    Richard Glen

    10/18/2022, 12:56 PM
    Is the background blur achievable? It would help a lot if there’s a sample project that does something similar. Thanks!
    k
    • 2
    • 15
  • d

    Dragos Rachieru

    10/18/2022, 9:01 PM
    Can I write plugins using compose? Like being able to add a jar to an app that will change/add screens. I'm not sure how to do this right now.
    t
    k
    +3
    • 6
    • 13
  • t

    Thomas

    10/18/2022, 10:35 PM
    Could someone from the compose team please look into the following issue? https://github.com/JetBrains/compose-jb/issues/2329
    a
    • 2
    • 2
Powered by Linen
Title
t

Thomas

10/18/2022, 10:35 PM
Could someone from the compose team please look into the following issue? https://github.com/JetBrains/compose-jb/issues/2329
a

alexey.tsvetkov

10/26/2022, 3:20 PM
Sure, I will look into it today
t

Thomas

10/26/2022, 11:32 PM
Thanks, I appreciate that a lot. It seems that deleting the gradle build cache directory allows for a successful build.
View count: 18