From 35c2ee3673b16c34eaf8fa19bb5d853e4827c082 Mon Sep 17 00:00:00 2001
From: chylex <contact@chylex.com>
Date: Sun, 3 Jul 2022 15:46:00 +0200
Subject: [PATCH] Work around broken bottom anchor in PluginControl

---
 windows/TweetDuck/Plugins/PluginControl.cs | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/windows/TweetDuck/Plugins/PluginControl.cs b/windows/TweetDuck/Plugins/PluginControl.cs
index 6d0b8b6a..e19055b3 100644
--- a/windows/TweetDuck/Plugins/PluginControl.cs
+++ b/windows/TweetDuck/Plugins/PluginControl.cs
@@ -40,6 +40,12 @@ public PluginControl(PluginManager pluginManager, Plugin plugin) : this() {
 			this.labelWebsite.Text = plugin.Website;
 			this.labelVersion.Text = plugin.Version;
 
+			// Bottom anchor seems to be broken, so the height of the label and border is set manually.
+			this.labelType.Anchor = AnchorStyles.Left | AnchorStyles.Top;
+			this.panelBorder.Anchor = AnchorStyles.Left | AnchorStyles.Top;
+			this.labelType.Height = Height;
+			this.panelBorder.Height = Height;
+			
 			this.labelType.LineHeight = BrowserUtils.Scale(11, dpiScale);
 
 			UpdatePluginState();
@@ -54,6 +60,8 @@ public PluginControl(PluginManager pluginManager, Plugin plugin) : this() {
 		private void timerLayout_Tick(object? sender, EventArgs e) {
 			timerLayout.Stop();
 			Height = nextHeight;
+			labelType.Height = nextHeight;
+			panelBorder.Height = nextHeight;
 			ResumeLayout();
 		}