From 1cb59ef2df257e8501f5064710193f3470e7c01a Mon Sep 17 00:00:00 2001 From: Android-X13 <76814540+Android-X13@users.noreply.github.com> Date: Mon, 1 Aug 2022 02:41:10 +0300 Subject: [PATCH 1/2] Fix clickable area of Enable Offers toggle button --- .../bisq/desktop/main/portfolio/openoffer/OpenOffersView.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/desktop/src/main/java/bisq/desktop/main/portfolio/openoffer/OpenOffersView.java b/desktop/src/main/java/bisq/desktop/main/portfolio/openoffer/OpenOffersView.java index 80dc38afe6e..34b10b158a0 100644 --- a/desktop/src/main/java/bisq/desktop/main/portfolio/openoffer/OpenOffersView.java +++ b/desktop/src/main/java/bisq/desktop/main/portfolio/openoffer/OpenOffersView.java @@ -218,9 +218,10 @@ public void initialize() { return row; }); - selectToggleButton.setPadding(new Insets(0, 90, -20, 0)); + selectToggleButton.setPadding(new Insets(0, 0, -20, 0)); selectToggleButton.setText(Res.get("shared.enabled")); selectToggleButton.setDisable(true); + HBox.setMargin(selectToggleButton, new Insets(0, 90, 0, 0)); numItems.setId("num-offers"); numItems.setPadding(new Insets(-5, 0, 0, 10)); From 402eb99404ea1b1ec9078fdcf50ffa0a6dbfe4c9 Mon Sep 17 00:00:00 2001 From: Android-X13 <76814540+Android-X13@users.noreply.github.com> Date: Mon, 15 Aug 2022 04:18:41 +0300 Subject: [PATCH 2/2] Fix clickable area of toggle buttons --- .../desktop/components/chart/ChartView.java | 34 ++++++++++--------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/desktop/src/main/java/bisq/desktop/components/chart/ChartView.java b/desktop/src/main/java/bisq/desktop/components/chart/ChartView.java index 6e2ccbe6a95..5c3c366ecae 100644 --- a/desktop/src/main/java/bisq/desktop/components/chart/ChartView.java +++ b/desktop/src/main/java/bisq/desktop/components/chart/ChartView.java @@ -177,28 +177,29 @@ public void initialize() { // Put all together VBox timelineNavigationBox = new VBox(); - double paddingLeft = 15; + double paddingTop = 0; double paddingRight = 89; + double paddingLeft = 15; // Y-axis width depends on data so we register a listener to get correct value yAxisWidthListener = (observable, oldValue, newValue) -> { double width = newValue.doubleValue(); if (width > 0) { double rightPadding = width + 14; - VBox.setMargin(timeIntervalBox, new Insets(0, rightPadding, 0, paddingLeft)); - VBox.setMargin(timelineNavigation, new Insets(0, rightPadding, 0, paddingLeft)); - VBox.setMargin(timelineLabels, new Insets(0, rightPadding, 0, paddingLeft)); + VBox.setMargin(timeIntervalBox, new Insets(paddingTop, rightPadding, 0, paddingLeft)); + VBox.setMargin(timelineNavigation, new Insets(paddingTop, rightPadding, 0, paddingLeft)); + VBox.setMargin(timelineLabels, new Insets(paddingTop, rightPadding, 0, paddingLeft)); VBox.setMargin(legendBox1, new Insets(10, rightPadding, 0, paddingLeft)); if (legendBox2 != null) { - VBox.setMargin(legendBox2, new Insets(-20, rightPadding, 0, paddingLeft)); + VBox.setMargin(legendBox2, new Insets(paddingTop, rightPadding, 0, paddingLeft)); } if (legendBox3 != null) { - VBox.setMargin(legendBox3, new Insets(-20, rightPadding, 0, paddingLeft)); + VBox.setMargin(legendBox3, new Insets(paddingTop, rightPadding, 0, paddingLeft)); } if (legendBox4 != null) { - VBox.setMargin(legendBox4, new Insets(-20, rightPadding, 0, paddingLeft)); + VBox.setMargin(legendBox4, new Insets(paddingTop, rightPadding, 0, paddingLeft)); } if (legendBox5 != null) { - VBox.setMargin(legendBox5, new Insets(-20, rightPadding, 0, paddingLeft)); + VBox.setMargin(legendBox5, new Insets(paddingTop, rightPadding, 0, paddingLeft)); } if (model.getDividerPositions()[0] == 0 && model.getDividerPositions()[1] == 1) { @@ -207,25 +208,25 @@ public void initialize() { } }; - VBox.setMargin(timeIntervalBox, new Insets(0, paddingRight, 0, paddingLeft)); - VBox.setMargin(timelineNavigation, new Insets(0, paddingRight, 0, paddingLeft)); - VBox.setMargin(timelineLabels, new Insets(0, paddingRight, 0, paddingLeft)); - VBox.setMargin(legendBox1, new Insets(0, paddingRight, 0, paddingLeft)); + VBox.setMargin(timeIntervalBox, new Insets(paddingTop, paddingRight, 0, paddingLeft)); + VBox.setMargin(timelineNavigation, new Insets(paddingTop, paddingRight, 0, paddingLeft)); + VBox.setMargin(timelineLabels, new Insets(paddingTop, paddingRight, 0, paddingLeft)); + VBox.setMargin(legendBox1, new Insets(paddingTop, paddingRight, 0, paddingLeft)); timelineNavigationBox.getChildren().addAll(timelineNavigation, timelineLabels, legendBox1); if (legendBox2 != null) { - VBox.setMargin(legendBox2, new Insets(-20, paddingRight, 0, paddingLeft)); + VBox.setMargin(legendBox2, new Insets(paddingTop, paddingRight, 0, paddingLeft)); timelineNavigationBox.getChildren().add(legendBox2); } if (legendBox3 != null) { - VBox.setMargin(legendBox3, new Insets(-20, paddingRight, 0, paddingLeft)); + VBox.setMargin(legendBox3, new Insets(paddingTop, paddingRight, 0, paddingLeft)); timelineNavigationBox.getChildren().add(legendBox3); } if (legendBox4 != null) { - VBox.setMargin(legendBox4, new Insets(-20, paddingRight, 0, paddingLeft)); + VBox.setMargin(legendBox4, new Insets(paddingTop, paddingRight, 0, paddingLeft)); timelineNavigationBox.getChildren().add(legendBox4); } if (legendBox5 != null) { - VBox.setMargin(legendBox5, new Insets(-20, paddingRight, 0, paddingLeft)); + VBox.setMargin(legendBox5, new Insets(paddingTop, paddingRight, 0, paddingLeft)); timelineNavigationBox.getChildren().add(legendBox5); } root.getChildren().addAll(timeIntervalBox, chart, timelineNavigationBox); @@ -407,6 +408,7 @@ protected HBox initLegendsAndGetLegendBox(Collection