diff --git a/desktop/src/main/java/haveno/desktop/main/portfolio/pendingtrades/PendingTradesView.fxml b/desktop/src/main/java/haveno/desktop/main/portfolio/pendingtrades/PendingTradesView.fxml index 29dec24a..c0240455 100644 --- a/desktop/src/main/java/haveno/desktop/main/portfolio/pendingtrades/PendingTradesView.fxml +++ b/desktop/src/main/java/haveno/desktop/main/portfolio/pendingtrades/PendingTradesView.fxml @@ -19,13 +19,15 @@ + + - + @@ -43,4 +45,8 @@ + + diff --git a/desktop/src/main/java/haveno/desktop/main/portfolio/pendingtrades/PendingTradesView.java b/desktop/src/main/java/haveno/desktop/main/portfolio/pendingtrades/PendingTradesView.java index 6df3a7c0..5da38d87 100644 --- a/desktop/src/main/java/haveno/desktop/main/portfolio/pendingtrades/PendingTradesView.java +++ b/desktop/src/main/java/haveno/desktop/main/portfolio/pendingtrades/PendingTradesView.java @@ -75,6 +75,7 @@ import javafx.scene.Scene; import javafx.scene.control.Button; import javafx.scene.control.ContextMenu; import javafx.scene.control.MenuItem; +import javafx.scene.control.ScrollPane; import javafx.scene.control.TableCell; import javafx.scene.control.TableColumn; import javafx.scene.control.TableRow; @@ -84,7 +85,6 @@ import javafx.scene.input.KeyCode; import javafx.scene.input.KeyEvent; import javafx.scene.layout.AnchorPane; import javafx.scene.layout.HBox; -import javafx.scene.layout.Priority; import javafx.scene.layout.StackPane; import javafx.scene.layout.VBox; import javafx.scene.text.Text; @@ -117,6 +117,8 @@ public class PendingTradesView extends ActivatableViewAndModel priceColumn, volumeColumn, amountColumn, avatarColumn, marketColumn, roleColumn, paymentMethodColumn, tradeIdColumn, dateColumn, chatColumn, moveTradeToFailedColumn; + @FXML + ScrollPane scrollView; private FilteredList filteredList; private SortedList sortedList; private TradeSubView selectedSubView; @@ -275,6 +277,8 @@ public class PendingTradesView extends ActivatableViewAndModel(filteredList); sortedList.comparatorProperty().bind(tableView.comparatorProperty()); tableView.setItems(sortedList); + tableView.setPrefHeight(100); + tableView.setMaxHeight(200); filterBox.initialize(filteredList, tableView); // here because filteredList is instantiated here filterBox.activate(); @@ -295,13 +299,13 @@ public class PendingTradesView extends ActivatableViewAndModel"; TitledGroupBg accountTitledGroupBg = addTitledGroupBg(gridPane, ++gridRow, 4, @@ -228,6 +231,14 @@ public class BuyerStep2View extends TradeStepView { Layout.COMPACT_FIRST_ROW_AND_GROUP_DISTANCE).second; field.setCopyWithoutCurrencyPostFix(true); + //preland: this fixes a textarea layout glitch + TextArea uiHack = new TextArea(); + uiHack.setMaxHeight(1); + GridPane.setRowIndex(uiHack, 1); + GridPane.setMargin(uiHack, new Insets(0, 0, 0, 0)); + uiHack.setVisible(false); + gridPane.getChildren().add(uiHack); + switch (paymentMethodId) { case PaymentMethod.UPHOLD_ID: gridRow = UpholdForm.addFormForBuyer(gridPane, gridRow, paymentAccountPayload); diff --git a/desktop/src/main/java/haveno/desktop/util/FormBuilder.java b/desktop/src/main/java/haveno/desktop/util/FormBuilder.java index d34d65ea..57c09c2f 100644 --- a/desktop/src/main/java/haveno/desktop/util/FormBuilder.java +++ b/desktop/src/main/java/haveno/desktop/util/FormBuilder.java @@ -645,7 +645,7 @@ public class FormBuilder { TextArea textArea = new HavenoTextArea(); textArea.setPromptText(prompt); textArea.setWrapText(true); - + textArea.setPrefHeight(100); final Tuple2 topLabelWithVBox = addTopLabelWithVBox(gridPane, rowIndex, title, textArea, top); GridPane.setColumnIndex(topLabelWithVBox.second, colIndex); @@ -672,10 +672,10 @@ public class FormBuilder { //DatePicker datePicker = new JFXDatePicker(); // //Temporary solution to fix issue 527; a more - //permanant solution would require this issue to be solved: + //permanant solution would require this issue to be solved: //(https://github.com/sshahine/JFoenix/issues/1245) DatePicker datePicker = new DatePicker(); - + Tuple2 topLabelWithVBox = addTopLabelWithVBox(gridPane, rowIndex, columnIndex, title, datePicker, top); return new Tuple2<>(topLabelWithVBox.first, datePicker); }