Class HintTextBox
A special TextBox that displays a HintText when Text is empty and a clear button when it is not.
Assembly: NanoByte.Common.WinForms.dll
Syntax
public class HintTextBox : TextBox
Constructors
HintTextBox()
Declaration
Properties
ForeColor
Gets or sets the color used when displaying text in the control.
Declaration
public Color ForeColor { get; set; }
Property Value
HintText
Declaration
public string HintText { get; set; }
Property Value
IsHintTextVisible
Indicates whether the HintText is currently visible.
Declaration
public bool IsHintTextVisible { get; }
Property Value
ShowClearButton
Controls whether the clear button is shown. Remains invisible when the HintText is visible.
Declaration
public bool ShowClearButton { get; set; }
Property Value
Text
Declaration
public override string Text { get; set; }
Property Value
Methods
OnBackColorChanged(EventArgs)
Declaration
protected override void OnBackColorChanged(EventArgs e)
Parameters
OnClearButtonClicked(EventArgs)
Declaration
protected virtual void OnClearButtonClicked(EventArgs e)
Parameters
OnEnter(EventArgs)
Declaration
protected override void OnEnter(EventArgs e)
Parameters
OnLeave(EventArgs)
Declaration
protected override void OnLeave(EventArgs e)
Parameters
OnTextChanged(EventArgs)
Declaration
protected override void OnTextChanged(EventArgs e)
Parameters
Events
ClearButtonClicked
Occurs when the clear button is clicked.
Declaration
public event EventHandler ClearButtonClicked
Event Type
Extension Methods