From 2be3b831ef76cba520c52180197628fa3d874166 Mon Sep 17 00:00:00 2001 From: Serge <5920850+seerge@users.noreply.github.com> Date: Sat, 6 Jan 2024 19:51:18 +0100 Subject: [PATCH] UI tweaks https://github.com/seerge/g-helper/issues/533 --- app/Extra.Designer.cs | 1 + app/Extra.cs | 12 +++++++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/app/Extra.Designer.cs b/app/Extra.Designer.cs index 6602ff8f..e44a646f 100644 --- a/app/Extra.Designer.cs +++ b/app/Extra.Designer.cs @@ -1267,6 +1267,7 @@ namespace GHelper // AutoScaleDimensions = new SizeF(192F, 192F); AutoScaleMode = AutoScaleMode.Dpi; + AutoScroll = true; AutoSize = true; AutoSizeMode = AutoSizeMode.GrowAndShrink; ClientSize = new Size(1013, 1515); diff --git a/app/Extra.cs b/app/Extra.cs index 245112ae..e098e00f 100644 --- a/app/Extra.cs +++ b/app/Extra.cs @@ -634,7 +634,17 @@ namespace GHelper { if (Height > Program.settingsForm.Height) { - Top = Program.settingsForm.Top + Program.settingsForm.Height - Height; + var top = Program.settingsForm.Top + Program.settingsForm.Height - Height; + + if (top < 0) + { + MaximumSize = new Size(Width, Program.settingsForm.Height); + Top = Program.settingsForm.Top; + } else + { + Top = top; + } + } else {