i\'ve changed a WinForms TextBox control to have no border.
When i do the bottom pixel row of text in the box is being cut off.
Top:>
You can do this in your form:
private void RefreshHeight(TextBox textbox)
{
textbox.Multiline = true;
Size s = TextRenderer.MeasureText(textbox.Text, textbox.Font, Size.Empty, TextFormatFlags.TextBoxControl);
textbox.MinimumSize = new Size(0, s.Height + 1);
textbox.Multiline = false;
}
Then you say RefreshHeight(textbox1);
Multiline change will force the textbox to "accept" the new size