svn path=/trunk/mcs/; revision=69815
* TextBoxBase.cs: When changing the font across the document we
can't recalculate after changing each line, since that will cahnge
the line count.
+ - PreferredHeight is a little different than i thought.
2006-12-19 Rolf Bjarne Kvinge <RKvinge@novell.com>
[EditorBrowsable(EditorBrowsableState.Advanced)]
public int PreferredHeight {
get {
- int bs = 0;
- switch (border_style) {
- case BorderStyle.FixedSingle:
- bs = 2;
- break;
- case BorderStyle.Fixed3D:
- bs = ThemeEngine.Current.Border3DSize.Width * 2;
- break;
- }
- return this.Font.Height + 7 + bs;
+ return (BorderStyle == BorderStyle.None ? 0 : Font.Height + 7);
}
}