Class UserControl
Parent class for all owner draw controls.
[ControlCategory("Other")]
public class UserControl : Control, IBaseObject, IDisposableObject, ISupportInitialize, IFocusable, ITextProperty, IComponent, IControl, IDisposable, IWin32Window, INotifyDataErrorInfo
- Inheritance
-
UserControl
- Implements
- Derived
Constructors
- UserControl()
Initializes a new instance of the UserControl class.
Properties
- ControlKind
Returns control identifier.
- DropDownMenu
Gets or sets ContextMenu which is shown when control is clicked.
- HasBorder
Gets or sets a value indicating whether the control has a border.
- RefreshOptions
Gets or sets different behavior and visualization options.
- ScrollBars
Gets or sets the type of scroll bars displayed in the control.
- WantChars
Gets or sets whether control wants to get all char/key events for all keys.
Methods
- DefaultPaint(Graphics, RectD)
Default painting method of the UserControl and its descendants.
- DrawDefaultBackground(Graphics, RectD)
Draw default background.
- GetBackground(VisualControlState)
Gets the background brush for specified state of the control.
- GetBorderSettings(VisualControlState)
Gets the border settings for specified state of the control.
- GetDefaultTheme()
Gets default color and style settings.
- OnMouseLeftButtonDown(MouseEventArgs)
Called when the left mouse button was pressed.
- OnPaint(PaintEventArgs)
Called when the control is redrawn. See Paint for details.
- OnSystemColorsChanged(EventArgs)
Called when the SystemColorsChanged event is raised.
- OnVisualStateChanged(EventArgs)
Called when VisualStateChanged property is changed.
- SetStateColors(VisualControlState, IReadOnlyFontAndColor?)
Sets StateObjects colors and backgrounds for the state specified in the
state
parameter to the colors fromfontAndColor
.
- ShowDropDownMenu()
Shows attached drop down menu.