From 85e316f3a7649b6d1cfcbf841a302f969fd14a16 Mon Sep 17 00:00:00 2001 From: axpoems <145597137+axpoems@users.noreply.github.com> Date: Sun, 28 Jul 2024 12:14:15 +0200 Subject: [PATCH] Fix horizontal scroll issue in My Open Trades page --- .../bisq_easy/open_trades/BisqEasyOpenTradesView.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/apps/desktop/desktop/src/main/java/bisq/desktop/main/content/bisq_easy/open_trades/BisqEasyOpenTradesView.java b/apps/desktop/desktop/src/main/java/bisq/desktop/main/content/bisq_easy/open_trades/BisqEasyOpenTradesView.java index 0d3c1fa523..e6af4635f8 100644 --- a/apps/desktop/desktop/src/main/java/bisq/desktop/main/content/bisq_easy/open_trades/BisqEasyOpenTradesView.java +++ b/apps/desktop/desktop/src/main/java/bisq/desktop/main/content/bisq_easy/open_trades/BisqEasyOpenTradesView.java @@ -95,8 +95,10 @@ public BisqEasyOpenTradesView(BisqEasyOpenTradesModel model, tableView.getStyleClass().addAll("bisq-easy-open-trades", "hide-horizontal-scrollbar"); configTableView(); - VBox.setMargin(tableView, new Insets(10, 0, 0, 0)); - Triple triple = BisqEasyViewUtils.getContainer(Res.get("bisqEasy.openTrades.table.headline"), tableView); + ScrollPane scrollPane = new ScrollPane(tableView); + scrollPane.setFitToWidth(true); + scrollPane.setFitToHeight(true); + Triple triple = BisqEasyViewUtils.getContainer(Res.get("bisqEasy.openTrades.table.headline"), scrollPane); VBox tableViewVBox = triple.getThird(); // ChatBox @@ -131,7 +133,7 @@ protected void configTitleHBox() { @Override protected void configCenterVBox() { - centerVBox.setAlignment(Pos.CENTER); + centerVBox.setAlignment(Pos.TOP_CENTER); centerVBox.setFillWidth(true); } @@ -175,6 +177,7 @@ protected void onViewAttached() { tableView.setPlaceholderText(Res.get("bisqEasy.openTrades.noTrades")); tableView.allowVerticalScrollbar(); tableView.setFixHeight(150); + tableView.setMinWidth(500); tableView.getStyleClass().add("empty-table"); } else { tableView.setPlaceholder(null);