https://kotlinlang.org logo
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
  • a

    Alonso Ato Neyra

    09/22/2021, 2:03 AM
    Hi! How to handle this scenario. My first windows is smaller than the second one, so I define as unspecified the width and height. Then when the program opens the second windows it stays with the size of the first one. Any idea?
    a
    • 2
    • 1
  • f

    Frank

    09/22/2021, 1:09 PM
    Hi! How can I tell a LazyRow how many items should be visible. E.g. I have a list do 10 items but I want to display only items 4 to 6 or the first 3 items?
    c
    f
    • 3
    • 3
  • s

    spierce7

    09/22/2021, 9:43 PM
    Can you package and msi from a linux machine? When I try it seems like it’s processing the DMG settings, and looking for my mac signing certificate, which isn’t there, but that’s ok as I’m not trying to build a DMG.
    ✅ 1
    b
    m
    • 3
    • 4
  • c

    Colton Idle

    09/24/2021, 5:03 AM
    My builds seem to be failing when trying to use kotlin 1.5.31 because one of my dependencies is from jetpack compose and so it's not updated to 1.5.31 yet.
    +--- androidx.compose.runtime:runtime-livedata:{strictly 1.1.0-alpha04} -> 1.1.0-alpha04 (c)
    Does anyone know if there's a jetbrains version of that library that I just can't seem to locate so that I can build with the latest kotlin?
    j
    • 2
    • 2
  • j

    jimmyt

    09/24/2021, 8:57 PM
    Hello everybody, I've just created a new Compose Desktop project and added dependencies on the SQLDelight gradle plugin and sqlite driver, both version 1.5.1. Now when I run the main function in Main.kt, I get the following error:
    Exception in thread "AWT-EventQueue-0" java.lang.NoSuchMethodError: 'kotlinx.coroutines.JobSupport kotlinx.coroutines.ChildHandleNode.getJob()'
    	at kotlinx.coroutines.JobImpl.handlesException(JobSupport.kt:1333)
    	at kotlinx.coroutines.JobImpl.<init>(JobSupport.kt:1326)
    	at kotlinx.coroutines.JobKt__JobKt.Job(Job.kt:389)
    	at kotlinx.coroutines.JobKt.Job(Unknown Source)
    	at androidx.compose.runtime.Recomposer.<init>(Recomposer.kt:130)
    	at androidx.compose.ui.platform.DesktopOwners.<init>(DesktopOwners.desktop.kt:78)
    	at androidx.compose.desktop.ComposeLayer.<init>(ComposeLayer.desktop.kt:63)
    	at androidx.compose.desktop.ComposeWindow.<init>(ComposeWindow.desktop.kt:35)
    	at androidx.compose.desktop.AppWindow.<init>(AppWindow.desktop.kt:116)
    	at androidx.compose.desktop.AppWindow.<init>(AppWindow.desktop.kt)
    	at androidx.compose.desktop.AppWindow_desktopKt$Window$1.run(AppWindow.desktop.kt:85)
    	at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:316)
    	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
    	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
    	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
    	at java.base/java.security.AccessController.doPrivileged(AccessController.java:391)
    	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
    	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
    	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
    	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
    	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
    	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
    	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
    	at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
    
    Process finished with exit code 0
    I've posted the entire project on Github here. Does anyone know what might be causing this issue?
    🧵 1
    m
    • 2
    • 6
  • a

    Ayfri

    09/25/2021, 11:25 PM
    Hi, any build compatible to Kotlin 1.5.31 soon ?
    👍 4
    j
    j
    +2
    • 5
    • 6
  • j

    Javier

    09/27/2021, 1:28 PM
    I checked that Compose Desktop dependency is exposing the material dependency, which should be unnecessary if you are not using Material. Is it a requirement or it can be changed from
    api
    to
    implementation
    ?
    i
    • 2
    • 11
  • k

    Kirill Grouchnikov

    09/27/2021, 8:00 PM
    Build
    1.0.0-alpha4-build362
    is out with support for Kotlin 1.5.31
    🔥 9
    🚀 5
    ❤️ 5
    :kotlin-intensifies: 14
    💪 4
    o
    h
    d
    • 4
    • 13
  • s

    smallshen

    09/28/2021, 2:03 AM
    A good news, Compose Desktop can compiled to native with GraalVM
    🎉 12
    u
    • 2
    • 2
  • m

    Mahir Chowdhury

    09/28/2021, 3:41 AM
    s
    s
    • 3
    • 8
  • s

    Scott Kruse

    09/28/2021, 6:13 AM
    Went through the compose multiplatform wizard for a new project and the setContent import isn't working
    o
    a
    k
    • 4
    • 9
  • s

    Sebastian Kürten

    09/28/2021, 4:35 PM
    Hi everyone, I'm looking for examples of real applications being build with compose for desktop already, i.e. not just examples/demos but projects that are on track to get used in production at some point. I guess with compose for desktop being so young there probably are not many projects yet, but I'd be interested in some pointers to projects on the rise
    j
    c
    +2
    • 5
    • 11
  • a

    Ayfri

    09/29/2021, 3:17 PM
    Hi, is there a way to generate dynamically an image with a text ?
    k
    • 2
    • 1
  • s

    spierce7

    09/29/2021, 8:18 PM
    Is there a way to embed a browser inside of a desktop compose app?
    d
    k
    +2
    • 5
    • 4
  • s

    Stefan Oltmann

    09/30/2021, 11:55 AM
    I want to create an Apple TV like hover effect. Does someone know how I can do that? This is a sample in CSS: https://codepen.io/iremlopsum/pen/WzKBpE
    c
    s
    i
    • 4
    • 12
  • s

    Stefan Oltmann

    09/30/2021, 2:32 PM
    I'm confused right now... After updating to the latest compose-jb build the deprecated
    imageResource
    and
    vectorXmlResource
    are removed... But this sample code still uses that: https://github.com/JetBrains/compose-jb/blob/master/examples/widgets-gallery/commo[…]kotlin/org/jetbrains/compose/demo/widgets/platform/Resources.kt How to replace it? Edit: Oh, okay... The sample is still on 1.0.0-alpha1 ... But my question is the same ^^
    c
    • 2
    • 6
  • m

    mcpiroman

    09/30/2021, 8:30 PM
    Kinda meta: I was skimming over the sources and I'm impressed how little code the desktop part takes - it's like maybe a 50 of usually a very small files! I was looking only below the `desktopMain`folders, maybe I miss something? Looks nice tho 👍
    💯 3
    c
    k
    +2
    • 5
    • 7
  • s

    Sebastian Kürten

    10/01/2021, 7:48 AM
    does anybody know if localization using
    strings.xml
    is supported already (or planned?)
    r
    j
    a
    • 4
    • 12
  • a

    Aaron Yoder

    10/01/2021, 9:19 AM
    Can't seem to figure out how to disable scrollbars. Gist here: https://gist.github.com/aaronjyoder/b3bd774117fa47e9e23c666612973019 I had this problem quite a few months back but gave up on it and came back to it now. Using v1.0.0-alpha4-build366. Basically trying to disable them when I'm zooming (holding ctrl).
    i
    • 2
    • 2
  • d

    Denis Simanchuk

    10/01/2021, 12:55 PM
    Hello, who knows, tell me how to change the background color of the window title?
    o
    • 2
    • 2
  • g

    gpaligot

    10/01/2021, 8:07 PM
    Hello here! Recently, I built a KMP library (https://github.com/GerardPaligot/kighlighter) which highlight code in a composable
    Text
    and use
    buildAnnotatedString
    builder to change the color for all keywords of the programming language. The library work pretty well and if I use it to highlight one times any source code, there is no problem. But now, I would like to use my library to create a presentation. To do that, I have a state to switch in my slides. It works but, sometimes, I don’t know why and randomly,
    buildAnnotatedString
    don’t apply my color on my
    Text
    . Maybe a bug in compose ? Any help is welcome! (Record of the bug in thread)
    z
    • 2
    • 4
  • m

    mcpiroman

    10/01/2021, 8:19 PM
    androidx.compose.ui.graphics.FilterQuality.None
    - "Fastest possible filtering, albeit also the lowest quality Typically this implies nearest-neighbour filtering." What if I want to always use nearest-neighbour filtering? Is there (yet) an API to specify hard filtering requirement?
    r
    i
    • 3
    • 4
  • a

    Akram Bensalem

    10/01/2021, 11:54 PM
    Does Desktop Compose supports "Lyricist" ?
    k
    z
    • 3
    • 3
  • k

    K J

    10/02/2021, 9:18 AM
    Is there any way for me to be able to detect a mouse release over something? I want to be able to click and drag on something (already handled), but then release the mouse over something else and run code on that other thing. I'm trying to connect two nodes in a node graph with wires and I'm not sure how to "drop" the wire onto the pin because I don't know how to detect mouse release without a mouse click.
    i
    • 2
    • 1
  • k

    kk57

    10/03/2021, 9:13 AM
    HI everyone, is onclick tag in SVG supported in compose desktop? something like this?
    <rect x="115" y="231" width="11" height="1" fill="#4D4D4D" onclick=""/>
    t
    i
    • 3
    • 4
  • m

    Mini

    10/03/2021, 3:13 PM
    I find myself reaching for
    rule.waitForIdle()
    a lot more in compose for desktop tests than in android tests. I vaguely remember reading something about compose tests waiting for idleness by default, but can’t find anything right now. Does the desktop rule not do this?
    i
    • 2
    • 1
  • a

    Alexey Glushkov

    10/03/2021, 5:02 PM
    Hi, is there any update about supporting java files in compose-jb desktop projects? I still can’t just build my compose-jb desktop project including a KMM shared lib. It just feels very confusing and I’m not even sure whether it’s my silly mistake or not… Everything works without java files but I got used to Dagger and would like to keep using it with compose-jb 🙂 I’ve filed a bug here https://github.com/JetBrains/compose-jb/issues/1022. My previous thread is here https://kotlinlang.slack.com/archives/C01D6HTPATV/p1628257318170400
    a
    • 2
    • 5
  • a

    Akram Bensalem

    10/03/2021, 5:39 PM
    How we can integrate FireBase sdk to Compose Desktop ?
    s
    c
    • 3
    • 4
  • j

    Jakob K

    10/04/2021, 5:43 PM
    Is it possible to let compose render to something else than the high level window abstraction? I was thinking of something more primitive, like a
    BufferedImage
    . As compose-jb can render to a
    JFrame
    , shouldn't this theoretically work?
    ➕ 1
    i
    m
    • 3
    • 23
  • a

    Akram Bensalem

    10/04/2021, 8:35 PM
    Is there any way to set min window size?
    s
    • 2
    • 3
Powered by Linen
Title
a

Akram Bensalem

10/04/2021, 8:35 PM
Is there any way to set min window size?
s

Sebastian Kürten

10/05/2021, 8:09 AM
I think you can do it by accessing the
ComposeWindow
object which extends
JFrame
and then set a minimum size on it
Window(
  onCloseRequest = { exitProcess(0) }
) {
  window.minimumSize = Dimension(800, 600)
  …
  content
  …
}
❤️ 1
a

Akram Bensalem

10/05/2021, 6:12 PM
Thank you
View count: 430