Class RadRepeatButton
Represents a RadRepeatButton that generates repeated click events when held down continuously. The RadRepeatButton class is a wrapper for the RadRepeatButtonElement class, transferring events to and from its corresponding element instance. The RadRepeatButtonElement contains all graphical and logical functionality and may be nested in other Telerik controls. When the button is pressed and held, it generates click events at specified intervals after an initial delay.
Inherited Members
Namespace: Telerik.WinControls.UI
Assembly: Telerik.WinControls.UI.dll
Syntax
public class RadRepeatButton : RadButton, INotifyPropertyChanged, ISupportInitializeNotification, ISupportInitialize, IComponentTreeHandler, ILayoutHandler, IPCHost, IAnalyticsProvider, IButtonControl, ISupportRootUIAutomation
Constructors
RadRepeatButton()
Declaration
public RadRepeatButton()
Properties
ButtonElement
Gets the RadRepeatButtonElement that represents the visual element of this repeat button control. This element contains the visual styling and repeat behavior logic for the button.
Declaration
public RadRepeatButtonElement ButtonElement { get; }
Property Value
RadRepeatButtonElement
A RadRepeatButtonElement that represents the button's visual element. |
DefaultSize
Gets the default size for the repeat button control when no explicit size is specified. This size is used during layout calculations and initial control sizing.
Declaration
protected override Size DefaultSize { get; }
Property Value
System.Drawing.Size
A System.Drawing.Size structure with default dimensions of 110x24 pixels. |
Overrides
Delay
Gets or sets the initial delay before the button starts repeating clicks when held down. This value specifies how long the button waits before beginning to generate repeated click events.
Declaration
[RadDefaultValue("Delay", typeof(RadRepeatButtonElement))]
public int Delay { get; set; }
Property Value
System.Int32
The delay in milliseconds before repeating starts. Must be non-negative. |
Interval
Gets or sets the interval between repeated clicks when the button is held down. This value specifies the time between each repeated click event after the initial delay.
Declaration
[RadDefaultValue("Interval", typeof(RadRepeatButtonElement))]
public int Interval { get; set; }
Property Value
System.Int32
The interval in milliseconds between repeated clicks. Must be non-negative. |
UseMnemonic
Gets or sets a value indicating whether the button responds to mnemonic characters. When true, the button can be activated using Alt + the mnemonic character defined by an ampersand (&) in the text.
Declaration
public bool UseMnemonic { get; set; }
Property Value
System.Boolean
true if the button responds to mnemonic characters; otherwise, false. The default is true. |
Methods
CreateButtonElement()
Creates the button element that represents the visual and functional core of this repeat button control. This method is called during control initialization to create the underlying RadRepeatButtonElement.
Declaration
protected override RadButtonElement CreateButtonElement()
Returns
RadButtonElement
A new instance of RadRepeatButtonElement that provides the repeat functionality. |
Overrides
OnButtonClick(EventArgs)
Raises the ButtonClick event with the specified event arguments. This method is called by the underlying button element when a repeat click occurs.
Declaration
protected virtual void OnButtonClick(EventArgs e)
Parameters
System.EventArgs
e
An System.EventArgs that contains the event data. |
ResetBackColorThemeOverrides()
Resets theme value overrides for the BackColor property, restoring the original themed appearance. This method removes any custom BackColor overrides and gradient style settings that were previously applied through SetBackColorThemeOverrides().
Declaration
protected override void ResetBackColorThemeOverrides()
Overrides
ResetForeColorThemeOverrides()
Resets theme value overrides for the ForeColor property, restoring the original themed text appearance. This method removes any custom ForeColor overrides that were previously applied through SetForeColorThemeOverrides() and reapplies the theme to the element tree.
Declaration
protected override void ResetForeColorThemeOverrides()
Overrides
SetBackColorThemeOverrides()
Sets theme value overrides for the BackColor property across all visual states of the button. This method applies the current BackColor to all available visual states and configures the button fill element to use a solid gradient style.
Declaration
protected override void SetBackColorThemeOverrides()
Overrides
SetForeColorThemeOverrides()
Sets theme value overrides for the ForeColor property across all visual states of the button. This method applies the current ForeColor to all available visual states for both the button element and its text primitive to ensure consistent text color appearance.
Declaration
protected override void SetForeColorThemeOverrides()
Overrides
Events
ButtonClick
Occurs when the repeat button generates a click event during continuous pressing. This event is fired repeatedly while the button is held down, after the initial delay and at the specified interval.
Declaration
public event EventHandler ButtonClick
Event Type
System.EventHandler
|