<@U14ECM2KV> thanks! it did give me an idea and I ...
# tornadofx
g
@ron thanks! it did give me an idea and I eventually got it working properly using this:
Copy code
center {
            stackpane {
                imageview(controller.image) {
                    isPreserveRatio = true
                    this@center.heightProperty().onChange { fitHeight = it - this@borderpane.top.layoutBounds.height }
                    this@center.widthProperty().onChange { fitWidth = it }
                }
            }
        }
It's incredibly ugly and I have no idea why center would give me the full height of the borderpane, but it seem to work for now...