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

    edvin

    11/10/2017, 6:03 PM
    @anidotnet You must never reference the person you pass in, that defeats the whole purpose of the ViewModel and effectively stops you from assigning another person item to this viewmodel. Just do val name = bind(Person::name) instead. You can pass the person constructor param onto the ViewModel constructor, but I recommend to just remove it and do model.item = person if you need to assign the value manually. This avoids that whole confusion and also ensures that you have a noargs constructor so that you ViewModel also works with injection.
    a
    • 2
    • 31
  • e

    edvin

    11/10/2017, 8:27 PM
    You can use our vgrow helper though 🙂
    a
    • 2
    • 14
  • k

    kastork

    11/12/2017, 4:52 PM
    @edvin When in the
    Workspace
    lifecycle would you invoke
    removeFromParent
    on the default toolbar buttons? If you do it in
    init
    or
    onDock
    the buttons have null parents, so nothing happens.
    • 1
    • 1
  • t

    thomasnield

    11/14/2017, 1:28 PM
    https://github.com/HanSolo/charts/tree/master/src/main/java/eu/hansolo/fx/charts
    👍 1
    n
    e
    • 3
    • 5
  • e

    edvin

    11/15/2017, 10:01 AM
    So cool @thomasnield 🙂
    😉 4
    n
    • 2
    • 1
  • e

    edvin

    11/15/2017, 1:47 PM
    Great. So basically, make them Fragments, remove the injects and just do add where you want to add them.
    👍 1
    a
    • 2
    • 1
  • j

    jschneider

    11/15/2017, 4:24 PM
    Okay guys. Forget it. I had to add the style class to the app 😂
    👍 1
    r
    • 2
    • 1
  • e

    edvin

    11/15/2017, 10:33 PM
    @g4sarma Be sure to not mix Type Safe CSS and Type Safe Builders. Only the Type Safe Builders are an alternative to FXML, and Type Safe CSS can be applied to both.
    👍 1
    g
    • 2
    • 1
  • e

    edvin

    11/16/2017, 5:28 PM
    @g4sarma You might also want to check out FXLauncher 🙂
    g
    • 2
    • 20
  • e

    edvin

    11/16/2017, 6:18 PM
    @jamie-purchase Instead of Google, try Ctrl+N in IDEA 🙂
    j
    • 2
    • 10
  • j

    Juan

    11/19/2017, 3:40 PM
    How can I add a shadow to a node?
    a
    • 2
    • 1
  • a

    amanda.hinchman-dominguez

    11/19/2017, 11:08 PM
    @Juan You probably could if you assigned a class and a subsequent style that reacts to the change
    j
    • 2
    • 1
  • j

    Juan

    11/19/2017, 11:21 PM
    @carlw So you say I should do something like this
    override fun start(stage: Stage) {
            super.start(stage)
            stage.isResizable = false
        }
    and then when replacing the window I should make the window resizable again through a parameter?
    c
    • 2
    • 2
  • j

    jschneider

    11/22/2017, 7:45 AM
    Hey. Do you have any sample code? I am very interested in 2FA.
    p
    • 2
    • 3
  • r

    ron

    11/22/2017, 10:36 AM
    @pike when do you want to do the login? the fxlauncher should I think be downloadable without logging in, but after that it should have it before downloading the actual application, its dependencies and the app.xml?
    p
    c
    • 3
    • 7
  • e

    edvin

    11/22/2017, 10:48 AM
    @aayush I can expose the toggle button in each drawer item so that you can bind a boolean expression to the enabled state using
    enableWhen
    or
    disableWhen
    ?
    a
    • 2
    • 2
  • g

    g4sarma

    11/22/2017, 7:36 PM
    @jamie-purchase
    j
    • 2
    • 5
  • a

    amanda.hinchman-dominguez

    11/24/2017, 9:12 PM
    I know you can add jars easily as part of your library, however, is it possible to use a zip file as a library or would I have to find a way to turn it into a jar
    c
    • 2
    • 1
  • j

    jchildress

    11/27/2017, 8:56 PM
    Wonder if we still get links of the week and controlsfx....
    a
    • 2
    • 1
  • e

    edvin

    11/28/2017, 8:56 PM
    @thomasnield I've seen "old syntax" pop up for new users here and there, and I was wondering where it was coming from. One guy got back to me and explained he had read it in the guide. We have a chapter explaining what goes on behind the scenes with the builders, but he probably just skimmed it and thought that was the way to go (
    this += Button
    etc). I wonder if we're better off just showing the shiny syntax to avoid confusion. What do you think?
    k
    j
    g
    • 4
    • 7
  • g

    g4sarma

    11/28/2017, 10:14 PM
    ?
    t
    • 2
    • 3
  • e

    edvin

    11/29/2017, 1:52 PM
    Let me look at the test, I'm not familiar with it.
    k
    • 2
    • 1
  • g

    g4sarma

    11/29/2017, 6:54 PM
    @edvin does using inside the gradle fxLauncher{ includeExtensions "dll" } Download the dll libraries automatically declared as System.loadLibrary("sqljdbc_auth.dll")
    j
    • 2
    • 2
  • e

    edvin

    11/30/2017, 7:39 AM
    @kastork Can you see where? I don't see any code that should add interceptors there.
    k
    • 2
    • 7
  • a

    amanda.hinchman-dominguez

    11/30/2017, 8:18 PM
    oh yeah, okay. is s(classname) now deprecated?
    r
    • 2
    • 1
  • e

    edvin

    11/30/2017, 8:46 PM
    @amanda.hinchman-dominguez Looking at the caching thing now. By the way, that last line (
    center
    ) does nothing.
    a
    • 2
    • 2
  • e

    edvin

    11/30/2017, 8:47 PM
    @thomasnield We really need to update the guide, it looks like every new guy is using outdated syntax 🙂
    t
    • 2
    • 2
  • e

    edvin

    12/01/2017, 10:56 PM
    @g4sarma I always use an http client and store the data elsewhere, I find it much easier to deal with user access this way. But you can of course include a direct connection to a local postgresql server or something if your use case calls for it. There are some very nice libraries out there for working with JDBC in Kotlin.
    g
    e
    k
    • 4
    • 7
  • e

    edvin

    12/05/2017, 6:28 PM
    I contributed the desktop implementation 🙂
    😮 1
    👍 4
    n
    • 2
    • 1
  • e

    edvin

    12/05/2017, 6:30 PM
    As I was writing it, I realized that I wanted the refresh/loading status to be observable properties, but they were defined as booleans in the interface I had to implement. Luckily, due to the property delegates in TornadoFX, it was really easy to turn them into observables so I could keep the UI in sync easily.
    r
    • 2
    • 3
Powered by Linen
Title
e

edvin

12/05/2017, 6:30 PM
As I was writing it, I realized that I wanted the refresh/loading status to be observable properties, but they were defined as booleans in the interface I had to implement. Luckily, due to the property delegates in TornadoFX, it was really easy to turn them into observables so I could keep the UI in sync easily.
r

Ruckus

12/05/2017, 6:42 PM
That's pretty slick
e

edvin

12/05/2017, 7:22 PM
It's so lovely when a situation we didn't anticipate shows up, and our existing tools are a perfect fit for the job 🙂
👍 2
r

Ruckus

12/05/2017, 7:24 PM
Couldn't agree more
View count: 2