RadRadioButton
Represents a RadRadioButton control that enables the user to select a single option from a group of choices. Radio buttons are typically used in groups where only one option can be selected at a time.
Definition
Namespace:Telerik.WinControls.UI
Assembly:Telerik.WinControls.UI.dll
Syntax:
public class RadRadioButton : RadToggleButton, IDropTarget, ISynchronizeInvoke, IWin32Window, IBindableComponent, IComponent, IDisposable, INotifyPropertyChanged, ISupportInitializeNotification, ISupportInitialize, IComponentTreeHandler, ILayoutHandler, IAnalyticsProvider, ISupportRootUIAutomation
Inheritance: objectMarshalByRefObjectComponentControlScrollableControlRadControlRadButtonBaseRadToggleButtonRadRadioButton...
Implements:
Inherited Members
Constructors
Initializes a new instance of the RadRadioButton class. Creates a radio button with default settings including automatic checking behavior and tab stop functionality.
public RadRadioButton()
Properties
Gets or sets a value indicating whether the IsChecked value and the appearance of the control automatically change when the control is clicked. When true and the radio button is part of a group, it automatically ensures that only one control is checked at a time. When false, a group of radio button controls will not act as a mutually exclusive group and the IsChecked property must be updated in code.
[Browsable(true)]
public bool AutoCheck { get; set; }
Gets or sets a value indicating whether the control is automatically resized to display its entire contents. When enabled, the radio button will automatically adjust its size to accommodate its text and visual elements.
[Browsable(true)]
public override bool AutoSize { get; set; }
Overrides:
Gets the RadRadioButtonElement that represents the visual element of this radio button control. This element contains the visual styling and behavior logic for the radio button including the check mark and text layout.
[Browsable(false)]
public RadRadioButtonElement ButtonElement { get; }
Gets the default size of the RadRadioButton control. This property returns the recommended dimensions for the radio button when no explicit size is set.
protected override Size DefaultSize { get; }
Overrides:
Gets or sets the alignment of the radio button's check mark relative to the text. This property determines where the radio button circle appears in relation to the button text.
public ContentAlignment RadioCheckAlignment { get; set; }
Gets or sets a value indicating whether the user can give focus to this radio button using the TAB key. For radio buttons, this is automatically managed to ensure proper tab navigation within radio button groups. Only the checked radio button in a group typically receives tab focus.
public bool TabStop { get; set; }
Methods
Handles the toggle state changed event from the button element and manages tab stop behavior for radio button groups. This method ensures proper keyboard navigation within radio button groups when the checked state changes.
protected override void ButtonElement_ToggleStateChanged(object sender, StateChangedEventArgs args)
The source of the event.
argsStateChangedEventArgsA StateChangedEventArgs that contains the event data.
Overrides:
Creates the accessibility instance for the radio button control to support assistive technologies. Returns a specialized accessibility object when accessibility objects are enabled.
protected override AccessibleObject CreateAccessibilityInstance()
An AccessibleObject that provides accessibility support for the radio button.
Overrides:
Creates the main button element that is specific for RadRadioButton. This method is responsible for instantiating the underlying visual element that provides the radio button functionality.
protected override RadButtonElement CreateButtonElement()
A RadRadioButtonElement encapsulates the functionality of RadRadioButton.
Overrides:
Creates the child items and establishes event handlers for the radio button control. This method sets up the property change notification system for the button element.
protected override void CreateChildItems(RadElement parent)
The parent RadElement that will contain the child items.
Overrides:
Initializes the UI Automation provider for the radio button control. This method creates and returns the automation provider that enables assistive technologies to interact with the radio button.
protected override IRadRawElementProviderFragmentRoot InitializeUIAutomationProvider()
IRadRawElementProviderFragmentRoot
An IRadRawElementProviderFragmentRoot that provides UI Automation support for the radio button.
Overrides:
Raises the Enter event and handles keyboard navigation behavior for radio button groups. When entered via keyboard navigation, this method may automatically check the radio button or update tab stops.
Raises the GotFocus event and invalidates the control to update its visual appearance. This method ensures the radio button displays the appropriate focus indicators when it receives focus.
Raises the CheckStateChanged event when the check state of the radio button changes. This method provides notification when the radio button's checked state is modified.
Raises the CheckStateChanging event when the check state of the radio button is about to change. This method provides notification before the radio button's checked state is modified, allowing for cancellation.
protected override void res_CheckStateChanging(object sender, CheckStateChangingEventArgs args)
The source of the event.
argsCheckStateChangingEventArgsA CheckStateChangingEventArgs that contains the event data.
Overrides:
Manages tab stop behavior for radio button groups to ensure proper keyboard navigation. This method coordinates tab stops among radio buttons in the same container to maintain standard Windows behavior.
protected virtual void SetTabStops(bool tabPressed)
A value indicating whether this method was called as a result of tab key navigation.