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
tornadofx
  • s

    Shan

    02/05/2019, 5:33 PM
    (its not going well)
    • 1
    • 1
  • s

    Shan

    02/05/2019, 6:04 PM
    Can you set the keybind based on the node's
    focusedProperty
    status maybe?
    b
    • 2
    • 3
  • m

    mariofelesdossantosjr

    02/05/2019, 6:06 PM
    @carlw Could you help me with a question?
    c
    • 2
    • 11
  • b

    bjonnh

    02/05/2019, 11:08 PM
    it also looks ugly when you have tabs in tabs…
    h
    • 2
    • 1
  • m

    mariofelesdossantosjr

    02/06/2019, 10:56 AM
    Exception in thread "JavaFX Application Thread" kotlin.KotlinNullPointerException at tornadofx.FX$Companion.getPrimaryStage(FX.kt:117)return error
    a
    • 2
    • 1
  • m

    mariofelesdossantosjr

    02/06/2019, 10:56 AM
    Has anyone ever experienced this?
    c
    • 2
    • 1
  • s

    Shan

    02/06/2019, 12:29 PM
    a
    • 2
    • 3
  • s

    Shan

    02/06/2019, 3:19 PM
    Ok well I got the points to add properly, but now I am experiencing very strange animating issues. Looks like it's trying to animate to the Y value first and then the X instead of the diagonal between them. I'm not quite sure how TornadoFX does it's animations for adding Data points to a graph (if anyone has any insight on this, would be appreciated!)
    👍 2
    r
    a
    +2
    • 5
    • 20
  • j

    jmfayard

    02/06/2019, 4:25 PM
    First day of TornadoFX and I was able to write a useful app in 3-4 hours. Thanks for this nice framework! https://github.com/jmfayard/skripts/commit/ea768cf981854503956e0ebd11bdff0268a40261
    🎉 5
    🌪️ 1
    a
    • 2
    • 1
  • b

    bjonnh

    02/06/2019, 10:26 PM
    and my tabs are dynamic, so they can get added and removed
    d
    c
    • 3
    • 15
  • j

    jmfayard

    02/07/2019, 12:29 PM
    I can't get FxLauncher to work on OSX, any hints on how to debug the issue? https://github.com/edvin/fxldemo-gradle/issues/15
    s
    • 2
    • 4
  • j

    jchildress

    02/08/2019, 9:38 PM
    https://www.reddit.com/r/Kotlin/comments/aocgz1/kotlin_java11_javafx_pain_in_the_neck/
    a
    b
    • 3
    • 3
  • a

    amanda.hinchman-dominguez

    02/09/2019, 3:20 AM
    Jitpack actually has this really cool feature where if you say, have a project on github, you don't even need to publish anything anywhere. I don't know if it would work for private repositories but it's worth trying out
    n
    • 2
    • 3
  • s

    Shan

    02/10/2019, 2:53 PM
    Hmm, doesn't seem to be working on my computer. Maybe it's a Windows limitation?
    a
    • 2
    • 2
  • a

    amanda.hinchman-dominguez

    02/10/2019, 6:52 PM
    Cool - have you had success creating a configuration to be able to attempt a launch?
    a
    • 2
    • 14
  • a

    amanda.hinchman-dominguez

    02/10/2019, 7:41 PM
    I'm getting a Kotlin error on the test build that says
    Module java.base cannot be found in the module graph
    , which I thought might have been a bytecode issue
    a
    • 2
    • 33
  • c

    carlw

    02/10/2019, 7:42 PM
    @Shan does this get you closer? I'm using a StackPane. One of the child vboxes is doing the slight transparency while the other holds the content. The first opacity setting isn't affecting the content like the button in the second vbox()
    Using_StackPane_for_Transparent_Popup.php
    s
    • 2
    • 2
  • s

    spechard

    02/11/2019, 9:12 AM
    but it does not show anything, while a BorderPane works. Do you have any idea how I can embed views in a VBox? Thanks!
    a
    • 2
    • 2
  • c

    carlw

    02/12/2019, 12:14 PM
    @alex what are you using for the SDK? Oracle or Corretto?
    a
    a
    r
    • 4
    • 4
  • a

    amanda.hinchman-dominguez

    02/12/2019, 2:41 PM
    @alex this is interesting. Do you have insight on why? Is this just an IDE issue?
    a
    • 2
    • 3
  • d

    Dustin Jensen

    02/14/2019, 3:04 AM
    @amanda.hinchman-dominguez I'm a C#/React web developer by day. I picked the naming style when I realized that the stylesheets were not view specific and wanted to keep classes from clashing 😛. It is something I've seen in CSS to achieve that goal before scope CSS was a thing. What is the Kotlin convention for naming styles? camelCase? When you ask,
    What exactly is the style itself?
    are you referring to the convention I used, or the style definitions to achieve the image I shared? The following is what I ended up doing with because I couldn't figure out how to align the label 😛
    k
    c
    s
    • 4
    • 5
  • a

    amanda.hinchman-dominguez

    02/14/2019, 3:51 AM
    d
    • 2
    • 2
  • k

    Kevin

    02/15/2019, 1:21 AM
    How can I see validation decorators immediately when first opening a form? I can tell that validation is happening because I also have it bound to a button, but the decorators don’t activate until I type into the field
    d
    g
    • 3
    • 5
  • i

    iari

    02/15/2019, 3:29 PM
    @edvin this time I got a bigger bit of the co/contravariance quickfix: Look at the ItemViewModel<T> class, starting line 550. There are a couple of bind functions, that work directly on properties, like bind(property: KProperty1<T, N?> ... bind(property: KMutableProperty1<T, N> ... bind(property: KMutableProperty1<T, N?> ... and so on. These can benefit from adding the an in modifier to the T parameter could use : if someone makes abstract Viewmodels this makes a lot of sense (I'm doing it right now).
    a
    • 2
    • 1
  • t

    thomasnield

    02/15/2019, 4:18 PM
    https://twitter.com/thomasnield9727/status/1096443476865101832
    a
    • 2
    • 1
  • t

    thomasnield

    02/15/2019, 8:09 PM
    I need to test TornadoFX on 11 soon
    a
    a
    • 3
    • 4
  • c

    Czar

    02/16/2019, 9:57 PM
    Well, from what I understand App() is the singular point of entry in TornadoFX application, so if we define external DI there, we'll be ok. The question is probably - how do we do it, do we provide predefined setup method and offer user to call it in
    init {}
    or maybe do a class that extends App and offer the user to use that if they want external DI, both have merits, I guess we have to try and see.
    👍 1
    a
    • 2
    • 1
  • a

    amanda.hinchman-dominguez

    02/16/2019, 11:34 PM
    @sbyrne and I discovered something interesting for JavaFX and MacOS: if for some weird reason you wish to set your menu bar in the top apple menubar where "java" is, you have to write something like this:
    k
    • 2
    • 4
  • a

    alex

    02/17/2019, 4:21 PM
    What are good practices for tests when you need to create temporary folder/files?
    c
    b
    • 3
    • 4
  • j

    jchildress

    02/18/2019, 1:40 PM
    Off topic, but I just have to ask if anyone has spent any serious time trying to use JavaFX with Java 11? Not with Kotlin, just "plain" Java 11... It is really amazing how difficult it is now. It could just be me, but all of the stuff that was so "simple/easy" with Java 8 seems really complex with regard to setting up the dev env... I hope it's just me. All of the "add-exports" seem strange...
    a
    a
    +2
    • 5
    • 20
Powered by Linen
Title
j

jchildress

02/18/2019, 1:40 PM
Off topic, but I just have to ask if anyone has spent any serious time trying to use JavaFX with Java 11? Not with Kotlin, just "plain" Java 11... It is really amazing how difficult it is now. It could just be me, but all of the stuff that was so "simple/easy" with Java 8 seems really complex with regard to setting up the dev env... I hope it's just me. All of the "add-exports" seem strange...
a

alex

02/18/2019, 1:47 PM
We've discussed it several days ago, I'm able to run JavaFX11/Kotlin project with pure Oracle JDK, no add-exports needed
I've spend some time reading all these tutorials as well, to avoid export thing you need to provide
module-info.java
, which solves basically everything
a

abhinay

02/18/2019, 1:49 PM
add-exports
is typically only required if you need to access something from the internal API.
j

jchildress

02/18/2019, 1:49 PM
Have you tried using any external libraries with it? PreferencesFX or anything like that? Plain works fine... when I try to use any "recent" JavaFX libraries it seems like it's back to adding all of the "--add-exports"...
I spent about a month working with JPMS I kept running into issues with external libraries. Which I realize I don't have to use. It's really a pia compared to what it used to be...
I can't wait to show my team members how easy it is to work with Java 11 and JavaFX 🙂
a

alex

02/18/2019, 1:51 PM
I have issues with some libraries, like arrow-kt, others are working fine.
https://github.com/sanyarnd/kani you can look at my `pom.xml`/`module-info.java` here, this project works on Windows machine with pure Oracle JDK, nothing else.
j

jchildress

02/18/2019, 1:52 PM
Sound goods, I think I'll just accept that I need to spend more time studying up on what the changes have taken place. I'm sure it will pay off in the long run 🙂
a

abhinay

02/18/2019, 1:54 PM
Does
PreferencesFX
11 use internal API as well?
I thought ControlsFX was the only library heavily dependent on internal APIs 😵
j

jchildress

02/18/2019, 1:56 PM
Checking on it now. Stuck on most recent "error" of
javafx.scene.control.TreeItem.children accessible: module javafx.controls does not "opens javafx.scene.control" to unnamed module
I'm sure it's my error, it's just frustrating how involved it seems it has become.
a

alex

02/18/2019, 1:57 PM
The issue is
module-info.java
, you need to add something like this:
opens your.package to javafx.controls, javafx.graphics, javafx.fxml;
if I recall correctly
j

jchildress

02/18/2019, 2:38 PM
You are correct. Plain Java/JavaFX 11 works fine. My problem is with external libraries and their dependencies. Not really a Java problem I admit.
a

alex

02/18/2019, 2:41 PM
There's nothing you can do, I'm afraid. The only way is to use jvm/compiler flags 😞. Almost a year since Java11 (and 5? since Jigsaw thing), yet many libraries are not ready for good Java11 experience
m

mikehearn

02/18/2019, 4:34 PM
yes you need to declare what internal packages you're "breaking in to" as they see it, now. it's a bit a pita but it's a mechanical process of setting the flags
you can just --add-exports or --add-opens until the libraries or jdk are fixed
a

amiracam

02/19/2019, 2:26 AM
What are people here using for a redis client ? Kedis ? Or the less idiomatic Lettuce ?
View count: 2