ExTextBox
ExTextBox is a TextBox that draws its border in its own color, highlighted under the mouse and with focus, has its own
colors when disabled and shows a hint text in an empty box.
Hint text
HintText is shown in HintForeColor while the box is empty and doesn't have focus, in both styles. Unlike
TextBox.PlaceholderText it also works in a window with WS_EX_COMPOSITED, which ExForm uses by default: an empty
TextBox with PlaceholderText repaints such a window endlessly.
Custom style
| Property | Description |
|---|---|
DefaultStyle |
true (default) leaves the drawing to Windows, false uses the custom style. |
BorderColor, BorderThickness |
Border of the box. |
HighlightColor |
Border under the mouse and with focus. |
DisabledBorderColor, DisabledBackColor, DisabledForeColor |
Colors of a disabled box. |
UseDarkScrollBar |
Dark scroll bars of a multiline box. |
Theme
| Theme color | Used for |
|---|---|
BoxBackColor, BoxForeColor |
Background and text. |
BorderColor |
Border. |
HighlightBackColor |
Border under the mouse and with focus. |
ButtonBackColor |
Border of a disabled box. |
PanelBackColor |
Background of a disabled box. |
DarkScrollBars |
Scroll bars of a multiline box. |
Example
var search = new ExTextBox { HintText = "Search…", HintForeColor = Color.Gray };


