RadChartElement
Represents the main visual element of a RadChartView control that contains and manages the chart display, including the chart area, legend, title, and drill navigation components.
Definition
Namespace:Telerik.WinControls.UI
Assembly:Telerik.WinControls.ChartView.dll
Syntax:
public class RadChartElement : LightVisualElement, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IBindableComponent, IComponent, IDisposable, ISupportDrag, ISupportDrop, IShortcutProvider, IStylableElement, IStylableNode, IPrimitiveElement, IShapedElement, IFillElement, IBorderElement, IBoxStyle, IBoxElement, IDrawFillElement, IImageElement, ITextPrimitive, ITextProvider
Inheritance: objectDisposableObjectRadObjectRadElementVisualElementRadComponentElementRadItemUIItemBaseLightVisualElementRadChartElement...
Derived Classes:
Implements:
Inherited Members
Constructors
public RadChartElement()
Properties
Gets or sets the navigation mode for the drill functionality, determining how drill navigation is presented to users.
[Browsable(false)]
public DrillNavigationMode DrillNavigationMode { get; set; }
Gets the drill navigator RadItem that provides drill-down and drill-up navigation functionality for hierarchical data exploration.
[Browsable(false)]
public RadItem DrillNavigator { get; }
Gets or sets the position of the drill navigation element within the chart layout.
public DrillElementPosition DrillPosition { get; set; }
Gets the ChartLegendElement that displays series information and provides legend functionality for the chart.
public ChartLegendElement LegendElement { get; }
Gets or sets the orientation of legend items within the legend element, determining whether items are arranged horizontally or vertically.
public Orientation LegendItemsOrientation { get; set; }
Gets or sets the offset position of the legend element when LegendPosition is set to Float.
public Point LegendOffset { get; set; }
Gets or sets the docking position of the legend element relative to the chart area or allows it to float at a custom position.
public LegendPosition LegendPosition { get; set; }
Gets or sets the title text displayed at the top of the legend element.
public string LegendTitle { get; set; }
Gets or sets a value indicating whether the drill navigation element is visible and available for user interaction.
public bool ShowDrillNavigation { get; set; }
Gets or sets a value indicating whether the chart legend is visible and displayed to show series information and data point descriptions.
public bool ShowLegend { get; set; }
Gets or sets a value indicating whether the chart title element is visible and displayed above or beside the chart area.
public bool ShowTitle { get; set; }
Gets the ChartTitleElement that represents the visual title component of the chart.
public ChartTitleElement TitleElement { get; }
Gets or sets the docking position of the chart title element relative to the chart area.
public TitlePosition TitlePosition { get; set; }
Gets the primary ChartView that contains the chart area, series, and axes for data visualization.
public ChartView View { get; }
Gets the collection of ChartView objects available for drill-down navigation and multi-view scenarios.
[Browsable(false)]
public ChartViewCollection Views { get; }
Gets the ChartWrapper that encapsulates the chart view and handles chart rendering and interaction functionality.
[Browsable(false)]
public ChartWrapper Wrapper { get; }
Methods
Arranges the child elements within the available space and handles special positioning for floating legend elements.
Creates and returns the chart legend element that displays series information and data point descriptions.
protected virtual ChartLegendElement CreateChartLegendElement()
A ChartLegendElement for displaying the chart legend.
Creates and returns the chart title element that displays the chart title text.
protected virtual ChartTitleElement CreateChartTitleElement()
A ChartTitleElement for displaying the chart title.
Creates and returns the chart wrapper element that contains and manages the chart view and handles chart rendering.
protected virtual ChartWrapper CreateChartWrapperElement()
A ChartWrapper for managing chart functionality.
Creates and initializes the child elements including the dock layout panel, title element, chart wrapper, legend element, and drill navigation components.
protected override void CreateChildElements()
Overrides:
Creates and returns the dock layout panel that arranges the chart components including title, legend, and chart area.
protected virtual DockLayoutPanel CreateDockLayoutElement()
A DockLayoutPanel for organizing chart elements.
Initiates a drill-down operation to navigate to a more detailed view based on the specified data point.
Navigates directly to a specific chart view by its index in the view collection.
Navigates to the top-level chart view, returning to the root of the drill navigation hierarchy.
public virtual bool DrillToTop()
true if the navigation to the top-level view was successful; otherwise, false.
Initiates a drill-up operation to navigate back to the previous chart view level.
public virtual bool DrillUp()
true if the drill-up operation was successful; otherwise, false.
Determines and returns the appropriate dock position for the legend element based on the current LegendPosition.
Returns an enumerable collection of direct stylable child objects, including the chart view and immediate child elements.
protected override IEnumerable<RadObject> GetStylableChildren()
IEnumerable<RadObject>
An IEnumerable<T> containing direct stylable child objects.
Overrides:
Returns an enumerable collection of all stylable child objects in the entire hierarchy, including the chart view and all nested child elements.
protected override IEnumerable<RadObject> GetStylableChildrenHierarchy()
IEnumerable<RadObject>
An IEnumerable<T> containing all stylable objects in the hierarchy.
Overrides:
Determines and returns the appropriate dock position for the title element based on the current TitlePosition.
Initializes member fields to their default values. This method is called prior the CreateChildItems one and allows for initialization of members on which child elements depend.
protected override void InitializeFields()
Overrides:
Processes gesture events and routes them to the appropriate gesture handler based on the gesture type.
protected override void OnGesture(GestureEventArgs args)
The GestureEventArgs containing gesture information and event data.
Overrides:
Raises the KeyDown event and forwards it to the chart wrapper for processing.
protected override void OnKeyDown(KeyEventArgs e)
The KeyEventArgs instance containing the event data.
Overrides:
Raises the KeyPress event and forwards it to the chart wrapper for processing.
protected override void OnKeyPress(KeyPressEventArgs e)
The KeyPressEventArgs instance containing the event data.
Overrides:
Raises the KeyUp event and forwards it to the chart wrapper for processing.
protected override void OnKeyUp(KeyEventArgs e)
The KeyEventArgs instance containing the event data.
Overrides:
Raises the event.
protected override void OnMouseDown(MouseEventArgs e)
The MouseEventArgs instance containing the event data.
Overrides:
Raises the event.
protected override void OnMouseMove(MouseEventArgs e)
The MouseEventArgs instance containing the event data.
Overrides:
Raises the event.
protected override void OnMouseUp(MouseEventArgs e)
The MouseEventArgs instance containing the event data.
Overrides:
Raises the MouseWheel event and forwards it to the chart wrapper for processing.
protected override void OnMouseWheel(MouseEventArgs e)
The MouseEventArgs instance containing the event data.
Overrides:
Processes pan gesture events and forwards them to the chart wrapper for handling chart panning operations.
protected override void OnPanGesture(PanGestureEventArgs args)
The PanGestureEventArgs containing pan gesture information.
Overrides:
Processes press and tap gesture events and forwards them to the chart wrapper for handling advanced touch interactions.
protected override void OnPressAndTapGesture(PressAndTapGestureEventArgs args)
The PressAndTapGestureEventArgs containing press and tap gesture information.
Overrides:
Handles render size change events and raises the RenderSizeChanged event when the chart element's size changes.
protected override void OnRenderSizeChanged(SizeChangedInfo info)
The SizeChangedInfo containing information about the size change.
Overrides:
Processes rotate gesture events and forwards them to the chart wrapper for handling chart rotation operations.
protected override void OnRotateGesture(RotateGestureEventArgs args)
The RotateGestureEventArgs containing rotation gesture information.
Overrides:
Processes two-finger tap gesture events and forwards them to the chart wrapper for handling multi-touch interactions.
protected override void OnTwoFingerTapGesture(GestureEventArgs args)
The GestureEventArgs containing two-finger tap gesture information.
Overrides:
Processes zoom gesture events and forwards them to the chart wrapper for handling chart zooming operations.
protected override void OnZoomGesture(ZoomGestureEventArgs args)
The ZoomGestureEventArgs containing zoom gesture information.
Overrides:
Paints the chart element by drawing the chart view content to the provided graphics surface.
Sets the docking position of the legend element based on the specified LegendPosition.
protected virtual void SetLegendDock(LegendPosition position)
The desired position for the legend element.
Sets the docking position of the title element based on the specified TitlePosition.
protected virtual void SetTitleDock(TitlePosition position)
The desired position for the title element.
Determines whether the chart element should fallback to the default theme when no custom theme is applied.
protected override bool ShouldFallbackToDefaultTheme()
false to indicate that the chart element should not fallback to the default theme.
Overrides:
Events
Occurs when the chart context menu is about to open, allowing customization of menu items and behavior.
public event ChartViewContextMenuOpeningEventHandler ContextMenuOpening
Occurs when a new DataPoint is created, allowing customization of data point properties and behavior.
public event ChartViewCreatePointEventHandler CreatePoint
Occurs when a new DataPointElement is created for visual representation of data points, allowing customization of point element properties.
public event ChartViewCreatePointElementEventHandler CreatePointElement
Occurs when the chart area requires a custom renderer to be created for the first time during chart initialization.
public event ChartViewCreateRendererEventHandler CreateRenderer
Occurs when the current view index changes during drill navigation operations.
public event EventHandler CurrentViewIndexChanged
Occurs when a drill operation is initiated, allowing navigation between different chart views or data levels.
public event DrillEventHandler Drill
Occurs when a data point label needs to be formatted before display, allowing customization of label content and appearance.
public event ChartViewLabelFormattingEventHandler LabelFormatting
Occurs when the chart element's render size changes, typically during resize operations.
public event EventHandler RenderSizeChanged