diff --git a/NAPS2.Lib/EtoForms/Layout/LayoutLine.cs b/NAPS2.Lib/EtoForms/Layout/LayoutLine.cs index 6b4e5b7d96..0832462bf4 100644 --- a/NAPS2.Lib/EtoForms/Layout/LayoutLine.cs +++ b/NAPS2.Lib/EtoForms/Layout/LayoutLine.cs @@ -42,8 +42,8 @@ public override void DoLayout(LayoutContext context, RectangleF bounds) if (Padding is { } padding) { bounds = new RectangleF( - bounds.X + padding.Left, bounds.Y + padding.Top, - bounds.Width - padding.Horizontal, bounds.Height - padding.Vertical); + bounds.X + padding.Left * context.Scale, bounds.Y + padding.Top * context.Scale, + bounds.Width - padding.Horizontal * context.Scale, bounds.Height - padding.Vertical * context.Scale); } var childContext = GetChildContext(context, bounds); GetInitialCellLengthsAndScaling(context, childContext, bounds, out var cellLengths, out var cellScaling); @@ -116,7 +116,7 @@ protected override SizeF GetPreferredSizeCore(LayoutContext context, RectangleF var childLayoutSize = GetSize(cellLengths[i], GetBreadth(childSize)); size = UpdateTotalSize(size, childLayoutSize, GetSpacing(i, context)); } - size += new SizeF(Padding?.Horizontal ?? 0, Padding?.Vertical ?? 0); + size += new SizeF(Padding?.Horizontal ?? 0, Padding?.Vertical ?? 0) * context.Scale; if (Width != null) { size.Width = Width.Value; diff --git a/NAPS2.Lib/EtoForms/Ui/DesktopForm.cs b/NAPS2.Lib/EtoForms/Ui/DesktopForm.cs index bdb6e7d70f..c925e8da01 100644 --- a/NAPS2.Lib/EtoForms/Ui/DesktopForm.cs +++ b/NAPS2.Lib/EtoForms/Ui/DesktopForm.cs @@ -133,7 +133,7 @@ protected override void BuildLayout() GetControlButtons(), C.Filler(), _notificationArea.Content) - ).Padding(10) + ).Padding(8) ).Scale() );