How to override the preferred size of a WinForms TextBox?
A TextBox in .NET does not let you adjust its height (there isn't even an AutoSize option). i have a textbox that is cutting off the bottom of text in the box : Example 1: Example 2: What i need is to fix the PreferredSize calculation; to override the bug in .NET WinForms TextBox control. i created a descendant FixedTextBox , and tried overriding the protected GetPreferredSize : public override Size GetPreferredSize(Size proposedSize) { Size size = base.GetPreferredSize(proposedSize); if (this.BorderStyle == BorderStyle.None) { size.Height += 2; } return size; } My overridden method is being