From 0cb82f3e4e2a7aa5e88abcfd7edb3aa39a8bf414 Mon Sep 17 00:00:00 2001 From: Daniel Wolf Date: Sun, 4 Feb 2018 11:17:38 +0100 Subject: [PATCH] Improved column widths --- .../com/rhubarb_lip_sync/rhubarb_for_spine/MainView.kt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/extras/rhubarb-for-spine/src/main/kotlin/com/rhubarb_lip_sync/rhubarb_for_spine/MainView.kt b/extras/rhubarb-for-spine/src/main/kotlin/com/rhubarb_lip_sync/rhubarb_for_spine/MainView.kt index 98f24fa..f43822f 100644 --- a/extras/rhubarb-for-spine/src/main/kotlin/com/rhubarb_lip_sync/rhubarb_for_spine/MainView.kt +++ b/extras/rhubarb-for-spine/src/main/kotlin/com/rhubarb_lip_sync/rhubarb_for_spine/MainView.kt @@ -76,10 +76,13 @@ class MainView : View() { } fieldset("Audio events") { tableview { - columnResizePolicy = TableView.CONSTRAINED_RESIZE_POLICY + columnResizePolicy = SmartResize.POLICY column("Event", AudioFileModel::eventNameProperty) + .weigthedWidth(1.0) column("Audio file", AudioFileModel::displayFilePathProperty) + .weigthedWidth(1.0) column("Dialog", AudioFileModel::dialogProperty).apply { + weigthedWidth(3.0) // Make dialog column wrap setCellFactory { tableColumn -> return@setCellFactory TableCell().also { cell -> @@ -93,7 +96,9 @@ class MainView : View() { } } column("Status", AudioFileModel::statusLabelProperty) + .weigthedWidth(1.0) column("", AudioFileModel::actionLabelProperty).apply { + weigthedWidth(1.0) // Show button setCellFactory { tableColumn -> return@setCellFactory object : TableCell() {