From cd285acffcbac9d36f9ee920080a3d24bbeb8b16 Mon Sep 17 00:00:00 2001 From: Partmedia Date: Sun, 16 Jun 2024 04:06:54 +0300 Subject: [PATCH] Widen power monitoring widget (#29062) (cherry picked from commit e633fe801bb4755aa6015612b432571b687ce6ca) --- Content.Client/Power/PowerMonitoringWindow.xaml.Widgets.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Content.Client/Power/PowerMonitoringWindow.xaml.Widgets.cs b/Content.Client/Power/PowerMonitoringWindow.xaml.Widgets.cs index 68294ea3af..a50df7e715 100644 --- a/Content.Client/Power/PowerMonitoringWindow.xaml.Widgets.cs +++ b/Content.Client/Power/PowerMonitoringWindow.xaml.Widgets.cs @@ -102,6 +102,7 @@ public sealed partial class PowerMonitoringWindow // Update tool tip button.ToolTip = Loc.GetString(name); + // Update power value // Don't use SI prefixes, just give the number in W, so that it is readily apparent which consumer is using a lot of power. button.PowerValue.Text = Loc.GetString("power-monitoring-window-button-value", ("value", Math.Round(entry.PowerValue).ToString("N0"))); @@ -500,7 +501,7 @@ public sealed class PowerMonitoringButton : Button }; MainContainer.AddChild(NameLocalized); - + BatteryLevel = new ProgressBar() { SetWidth = 47f, @@ -547,7 +548,8 @@ public sealed class PowerMonitoringButton : Button PowerValue = new Label() { HorizontalAlignment = HAlignment.Right, - SetWidth = 72f, + Align = Label.AlignMode.Right, + SetWidth = 80f, Margin = new Thickness(10, 0, 0, 0), ClipText = true, };