1
0
Fork 0
mirror of https://gitlab.com/kauron/jstudy synced 2024-12-23 00:43:32 +01:00

TestController: changed JFXTextField to TextField (the former gave utf-8 related input errors)

This commit is contained in:
Carlos Galindo 2016-12-08 22:37:08 +01:00
parent 112ab9f293
commit cb27488507
Signed by: kauron
GPG key ID: 83E68706DEE119A3
2 changed files with 4 additions and 6 deletions

View file

@ -1,6 +1,5 @@
package es.kauron.jstudy.controller; package es.kauron.jstudy.controller;
import com.jfoenix.controls.JFXTextField;
import es.kauron.jstudy.model.AppConfig; import es.kauron.jstudy.model.AppConfig;
import es.kauron.jstudy.model.TestItem; import es.kauron.jstudy.model.TestItem;
import javafx.event.ActionEvent; import javafx.event.ActionEvent;
@ -9,6 +8,7 @@ import javafx.fxml.Initializable;
import javafx.geometry.Insets; import javafx.geometry.Insets;
import javafx.scene.control.Label; import javafx.scene.control.Label;
import javafx.scene.control.ProgressBar; import javafx.scene.control.ProgressBar;
import javafx.scene.control.TextField;
import javafx.scene.layout.HBox; import javafx.scene.layout.HBox;
import java.net.URL; import java.net.URL;
@ -19,7 +19,7 @@ public class TestController implements Initializable {
@FXML @FXML
private Label question, prevQuestion, prevAnswer, correctAnswer, progressLabel, correctLabel; private Label question, prevQuestion, prevAnswer, correctAnswer, progressLabel, correctLabel;
@FXML @FXML
private JFXTextField answer; private TextField answer;
@FXML @FXML
private ProgressBar progress; private ProgressBar progress;
@FXML @FXML

View file

@ -1,7 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<?import com.jfoenix.controls.JFXTextField?>
<?import javafx.geometry.Insets?> <?import javafx.geometry.Insets?>
<?import javafx.scene.control.*?> <?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?> <?import javafx.scene.layout.*?>
@ -15,11 +13,11 @@
<Font size="30.0" /> <Font size="30.0" />
</font> </font>
</Label> </Label>
<JFXTextField fx:id="answer" labelFloat="true" promptText="Answer"> <TextField fx:id="answer">
<VBox.margin> <VBox.margin>
<Insets top="5.0" /> <Insets top="5.0" />
</VBox.margin> </VBox.margin>
</JFXTextField> </TextField>
<Separator /> <Separator />
<HBox fx:id="feedback" alignment="BOTTOM_CENTER" VBox.vgrow="ALWAYS"> <HBox fx:id="feedback" alignment="BOTTOM_CENTER" VBox.vgrow="ALWAYS">
<children> <children>