From 2bb91aa559bb01fce0c50bfd986613ecb57ab2db Mon Sep 17 00:00:00 2001 From: Justin Brown Date: Sun, 7 Jul 2024 09:49:32 -0700 Subject: [PATCH] Fix button alignment --- Pulsar4X/Pulsar4X.Client/EmpireManagement/FleetWindow.cs | 2 +- Pulsar4X/Pulsar4X.Client/Styles.cs | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/Pulsar4X/Pulsar4X.Client/EmpireManagement/FleetWindow.cs b/Pulsar4X/Pulsar4X.Client/EmpireManagement/FleetWindow.cs index 0115c9216..c97353def 100644 --- a/Pulsar4X/Pulsar4X.Client/EmpireManagement/FleetWindow.cs +++ b/Pulsar4X/Pulsar4X.Client/EmpireManagement/FleetWindow.cs @@ -666,7 +666,7 @@ private void DisplayShips() ImGui.EndChild(); } - ImGui.SetCursorPosY(ImGui.GetCursorPosY()); + ImGui.SetCursorPosY(ImGui.GetCursorPosY() - Styles.ButtonVerticalOffset); ImGui.SetCursorPosX(xPosition); if(ImGui.Button("Select All/None", new Vector2(Styles.LeftColumnWidthLg, 0f))) { diff --git a/Pulsar4X/Pulsar4X.Client/Styles.cs b/Pulsar4X/Pulsar4X.Client/Styles.cs index c2e11c823..e25cd2bcf 100644 --- a/Pulsar4X/Pulsar4X.Client/Styles.cs +++ b/Pulsar4X/Pulsar4X.Client/Styles.cs @@ -30,5 +30,7 @@ public static class Styles public static string IntFormat = "###,###,###,##0"; public static string DecimalFormat = "###,###,##0.##"; + + public static float ButtonVerticalOffset = 23f; } } \ No newline at end of file