diff --git a/client/src/main/kotlin/org/hso/texturesyncclient/app/Main.kt b/client/src/main/kotlin/org/hso/texturesyncclient/app/Main.kt index 65b27a8..b178587 100644 --- a/client/src/main/kotlin/org/hso/texturesyncclient/app/Main.kt +++ b/client/src/main/kotlin/org/hso/texturesyncclient/app/Main.kt @@ -5,6 +5,6 @@ import org.hso.texturesyncclient.view.mainView.MainView import org.hso.texturesyncclient.view.startupView.StartupView import tornadofx.App -class Main: App(MainView::class){ +class Main: App(ImportView::class){ } \ No newline at end of file diff --git a/client/src/main/kotlin/org/hso/texturesyncclient/view/importView/ImportView.kt b/client/src/main/kotlin/org/hso/texturesyncclient/view/importView/ImportView.kt index 7758861..a9f0798 100644 --- a/client/src/main/kotlin/org/hso/texturesyncclient/view/importView/ImportView.kt +++ b/client/src/main/kotlin/org/hso/texturesyncclient/view/importView/ImportView.kt @@ -11,8 +11,6 @@ import javafx.scene.layout.CornerRadii import javafx.scene.paint.Paint import javafx.scene.control.Label import javafx.scene.layout.Priority -import javafx.scene.text.Font -import javafx.scene.text.FontWeight import tornadofx.* class ImportView : View() { @@ -57,19 +55,18 @@ class ImportView : View() { } style { - labelHeading.font = Font.font("Verdana", FontWeight.MEDIUM, 40.0) - labelHeading.textFill = Paint.valueOf("#2b7bbb") + labelHeading.style = "-fx-font: 20px Verdana; -fx-text-fill: #2b7bbb;" + tfFilePath.style = "-fx-text-fill: #b15b2e;" tfFilePath.promptText = "Pfad zur Datei" tfFilePath.hgrow = Priority.ALWAYS - tfFilePath.style = "-fx-text-fill: #b15b2e;" btnFileChooser.style = "-fx-button-type: RAISED; -fx-background-color: #3c3f41; -fx-text-fill: #2b7bbb;" labelName.style = "-fx-font: 14px Verdana; -fx-text-fill: #2b7bbb;" - tfName.promptText = "Name eingeben" tfName.style = "-fx-text-fill: #b15b2e;" + tfName.promptText = "Name eingeben" labelTags.style = "-fx-font: 14px Verdana; -fx-text-fill: #2b7bbb;" diff --git a/client/src/main/kotlin/org/hso/texturesyncclient/view/importView/ImportViewController.kt b/client/src/main/kotlin/org/hso/texturesyncclient/view/importView/ImportViewController.kt index 8b7ce77..e8cd537 100644 --- a/client/src/main/kotlin/org/hso/texturesyncclient/view/importView/ImportViewController.kt +++ b/client/src/main/kotlin/org/hso/texturesyncclient/view/importView/ImportViewController.kt @@ -1,6 +1,5 @@ package org.hso.texturesyncclient.view.importView -import javafx.stage.FileChooser import javafx.stage.FileChooser.ExtensionFilter import tornadofx.Controller import tornadofx.FileChooserMode diff --git a/client/src/main/kotlin/org/hso/texturesyncclient/view/mainView/DetailView.kt b/client/src/main/kotlin/org/hso/texturesyncclient/view/mainView/DetailView.kt index 7ffaaab..730a35f 100644 --- a/client/src/main/kotlin/org/hso/texturesyncclient/view/mainView/DetailView.kt +++ b/client/src/main/kotlin/org/hso/texturesyncclient/view/mainView/DetailView.kt @@ -14,8 +14,8 @@ class DetailView: View() { val preview = Preview3D() init { - val DIFFUSE_MAP = "https://bit.ly/2FTajSP" - preview.setTexture(Image(DIFFUSE_MAP)) + // set a default texture + preview.setTexture(Image("textures/sample_texture.jpg")) } override val root = form { diff --git a/client/src/main/kotlin/org/hso/texturesyncclient/view/startupView/StartupView.kt b/client/src/main/kotlin/org/hso/texturesyncclient/view/startupView/StartupView.kt index b904603..28abb3a 100644 --- a/client/src/main/kotlin/org/hso/texturesyncclient/view/startupView/StartupView.kt +++ b/client/src/main/kotlin/org/hso/texturesyncclient/view/startupView/StartupView.kt @@ -1,6 +1,5 @@ package org.hso.texturesyncclient.view.startupView -import com.jfoenix.animation.alert.CenterTransition import com.jfoenix.controls.JFXButton import com.jfoenix.controls.JFXSpinner import com.jfoenix.controls.JFXTextField @@ -12,8 +11,6 @@ import javafx.scene.layout.Background import javafx.scene.layout.BackgroundFill import javafx.scene.layout.CornerRadii import javafx.scene.paint.Paint -import javafx.scene.text.Font -import javafx.scene.text.FontWeight import tornadofx.* class StartupView : View("StartupView") { @@ -51,14 +48,12 @@ class StartupView : View("StartupView") { style { spinnerStatus.isVisible = false - labelStatus.font = Font.font("Verdana", FontWeight.MEDIUM, 20.0) - labelStatus.textFill = Paint.valueOf("#2b7bbb") + labelStatus.style = "-fx-font: 20px Verdana; -fx-text-fill: #2b7bbb;" + labelServerIP.style = "-fx-font: 15px Verdana; -fx-text-fill: #2b7bbb;" - labelServerIP.textFill = Paint.valueOf("#2b7bbb") - labelServerIP.font = Font.font("Verdana", FontWeight.MEDIUM, 15.0) - btnConnect.textFill = Paint.valueOf("#2b7bbb") - btnConnect.background = Background(BackgroundFill(Paint.valueOf("#3c3f41"), CornerRadii.EMPTY, Insets.EMPTY)) + btnConnect.style = "-fx-button-type: RAISED; -fx-background-color: #3c3f41; -fx-text-fill: #2b7bbb;" + //tfServerIP.style = "-fx-text-fill: #b15b2e;" tfServerIP.style { //TODO without .style textFill = Paint.valueOf("#b15b2e") alignment = Pos.BASELINE_CENTER @@ -77,7 +72,7 @@ class StartupView : View("StartupView") { if (it.code == KeyCode.ENTER) { spinnerStatus.isVisible = true svc.btnConnectAction(tfServerIP.text) - spinnerStatus.isVisible = false + //spinnerStatus.isVisible = false } } diff --git a/client/src/main/kotlin/org/hso/texturesyncclient/view/startupView/StartupViewController.kt b/client/src/main/kotlin/org/hso/texturesyncclient/view/startupView/StartupViewController.kt index 55a67e4..01328f8 100644 --- a/client/src/main/kotlin/org/hso/texturesyncclient/view/startupView/StartupViewController.kt +++ b/client/src/main/kotlin/org/hso/texturesyncclient/view/startupView/StartupViewController.kt @@ -15,10 +15,10 @@ class StartupViewController : Controller() { startupView.labelStatus.text = txt } -fun tfServerIPClear (){ - val startupView = find(StartupView::class) - startupView.tfServerIP.clear() -} + fun tfServerIPClear (){ + val startupView = find(StartupView::class) + startupView.tfServerIP.clear() + } } diff --git a/client/src/main/resources/textures/sample_texture.jpg b/client/src/main/resources/textures/sample_texture.jpg new file mode 100644 index 0000000..4876a3b Binary files /dev/null and b/client/src/main/resources/textures/sample_texture.jpg differ