Class RadBreadCrumb
Provides a breadcrumb navigation control that displays a hierarchical path representation with support for tree-based navigation. The control allows users to navigate through hierarchical data structures and provides text mode editing capabilities with auto-completion features.
Inherited Members
Namespace: Telerik.WinControls.UI
Assembly: Telerik.WinControls.UI.dll
Syntax
public class RadBreadCrumb : RadEditorControl, INotifyPropertyChanged, ISupportInitializeNotification, ISupportInitialize, IComponentTreeHandler, ILayoutHandler, IPCHost, IAnalyticsProvider
Constructors
RadBreadCrumb()
Initializes a new instance of the RadBreadCrumb class with default settings. Sets the AutoSize property to true to enable automatic sizing based on content.
Declaration
public RadBreadCrumb()
Properties
AutoCompleteSuggestHelper
Gets the auto-completion suggestion helper that manages the display and filtering of suggested navigation paths. This helper provides intelligent suggestions based on the current input and available tree nodes.
Declaration
public BreadCrumbAutoCompleteSuggestHelper AutoCompleteSuggestHelper { get; }
Property Value
BreadCrumbAutoCompleteSuggestHelper
|
AutoSize
Gets or sets a value indicating whether the breadcrumb control automatically adjusts its size to fit its content. When enabled, the control will resize itself based on the breadcrumb path length and available space.
Declaration
public override bool AutoSize { get; set; }
Property Value
System.Boolean
|
Overrides
BreadCrumbElement
Gets the main breadcrumb element that handles the visual representation and functionality of the breadcrumb navigation. This element contains all the visual parts including split buttons, text editor, and dropdown menus.
Declaration
public virtual RadBreadCrumbElement BreadCrumbElement { get; }
Property Value
RadBreadCrumbElement
|
ChildMember
Gets or sets the property name from the data source that identifies child relationships in hierarchical data. This property is ignored when DefaultTreeView is set, as the tree view manages the hierarchy.
Declaration
public virtual string ChildMember { get; set; }
Property Value
System.String
|
DataMember
Gets or sets the name of the data member in the data source that contains the hierarchical data. This property is ignored when DefaultTreeView is set, as the tree view provides the data structure.
Declaration
public string DataMember { get; set; }
Property Value
System.String
|
DataSource
Gets or sets the data source that provides hierarchical data for the breadcrumb navigation. This property is ignored when DefaultTreeView is set, as the tree view serves as the data source.
Declaration
public object DataSource { get; set; }
Property Value
System.Object
|
DefaultSize
Gets the default size for the breadcrumb control when no explicit size is specified. Returns a size of 200x20 pixels which provides adequate space for typical breadcrumb navigation.
Declaration
protected override Size DefaultSize { get; }
Property Value
System.Drawing.Size
|
DefaultTreeView
Gets or sets the RadTreeView control that provides the hierarchical data source for breadcrumb navigation. When set, the breadcrumb will display and navigate through the tree structure of the associated tree view.
Declaration
public RadTreeView DefaultTreeView { get; set; }
Property Value
RadTreeView
|
DisplayMember
Gets or sets the property name from the data source that provides the display text for breadcrumb items. This property is ignored when DefaultTreeView is set, as the tree view handles display member mapping.
Declaration
public string DisplayMember { get; set; }
Property Value
System.String
|
ForeColor
This property is not relevant for this control.
Declaration
public override Color ForeColor { get; set; }
Property Value
System.Drawing.Color
|
Overrides
IsAutoCompleteEnabled
Gets or sets a value indicating whether auto-completion functionality is enabled when the breadcrumb is in edit mode. When enabled, the control provides suggestions based on available navigation paths as the user types.
Declaration
public bool IsAutoCompleteEnabled { get; set; }
Property Value
System.Boolean
|
IsHistoryEnabled
Gets or sets a value indicating whether the breadcrumb maintains a history of visited navigation paths. When enabled, users can access previously visited paths through the history dropdown menu.
Declaration
public bool IsHistoryEnabled { get; set; }
Property Value
System.Boolean
|
IsTextModeEnabled
Gets or sets a value indicating whether text mode editing is enabled for the breadcrumb control. When enabled, users can click to edit the breadcrumb path as text with auto-completion support.
Declaration
public bool IsTextModeEnabled { get; set; }
Property Value
System.Boolean
|
Nodes
Gets the collection of tree nodes that define the hierarchical structure for breadcrumb navigation. These nodes represent the available navigation paths and are displayed as breadcrumb segments.
Declaration
public virtual RadTreeNodeCollection Nodes { get; }
Property Value
RadTreeNodeCollection
|
ParentMember
Gets or sets the property name from the data source that identifies parent relationships in hierarchical data. This property is ignored when DefaultTreeView is set, as the tree view manages the hierarchy.
Declaration
public virtual string ParentMember { get; set; }
Property Value
System.String
|
Path
Gets or sets the current navigation path as a string with path elements separated by the PathSeparator. Setting this property navigates to the specified path and updates the breadcrumb display accordingly.
Declaration
public string Path { get; set; }
Property Value
System.String
|
PathSeparator
Gets or sets the character used to separate path elements in the breadcrumb navigation. This separator is used when displaying the path in text mode and when parsing user input.
Declaration
public char PathSeparator { get; set; }
Property Value
System.Char
|
PinnedHeaderItems
Gets the collection of pinned menu items in the HeaderDropDownButtonElement. These items provide shortcuts for faster navigation to predefined paths and enhance user experience.
Declaration
public ObservableCollection<AssociatedMenuItem> PinnedHeaderItems { get; }
Property Value
ObservableCollection<AssociatedMenuItem>
|
PinnedItemsPosition
Gets or sets the position of pinned header items in the HeaderDropDownButtonElement. Determines whether pinned items appear at the top or bottom of the dropdown menu for quick navigation access.
Declaration
public MenuItemsPosition PinnedItemsPosition { get; set; }
Property Value
MenuItemsPosition
|
RelationBindings
Gets the collection of relation bindings that define how related data tables are connected in the data source. This property is ignored when DefaultTreeView is set, as the tree view handles data relationships.
Declaration
public virtual RelationBindingCollection RelationBindings { get; }
Property Value
RelationBindingCollection
|
SelectTreeNodeOnClick
Gets or sets a value indicating whether clicking the action part of a split button element selects the corresponding tree node. When false, clicking the action part opens the dropdown menu instead of selecting the node.
Declaration
public bool SelectTreeNodeOnClick { get; set; }
Property Value
System.Boolean
|
ShowHiddenNodes
Gets or sets a value indicating whether hidden tree nodes should be displayed in the breadcrumb navigation. Hidden nodes are those with their Visible property set to false.
Declaration
public bool ShowHiddenNodes { get; set; }
Property Value
System.Boolean
|
Text
This property is not relevant for this control.
Declaration
public override string Text { get; set; }
Property Value
System.String
|
Overrides
UseMnemonic
Gets or sets a value indicating whether the control interprets ampersand characters as access key prefix characters. When enabled, characters following ampersands will be underlined and treated as keyboard shortcuts.
Declaration
public bool UseMnemonic { get; set; }
Property Value
System.Boolean
|
ValueMember
Gets or sets the property name from the data source that provides the value for breadcrumb items. This property is ignored when DefaultTreeView is set, as the tree view handles value member mapping.
Declaration
public string ValueMember { get; set; }
Property Value
System.String
|
Methods
CraeteBreadCrumbElement()
Creates and returns a new instance of RadBreadCrumbElement that serves as the main visual element for the breadcrumb control. Override this method in derived classes to provide custom breadcrumb element implementations.
Declaration
protected virtual RadBreadCrumbElement CraeteBreadCrumbElement()
Returns
RadBreadCrumbElement
A new RadBreadCrumbElement instance. |
CreateChildItems(RadElement)
Creates the child elements for the breadcrumb control by adding the main RadBreadCrumbElement to the parent container. This method is called during the initialization phase to build the visual element hierarchy.
Declaration
protected override void CreateChildItems(RadElement parent)
Parameters
RadElement
parent
The parent element that will contain the breadcrumb element. |
Overrides
CreateSplitButtonElement()
This method is not relevant for this class.
Declaration
[Obsolete("Obsolete. Use BreadCrumbElement.CreateSplitButtonElement method instead.")]
protected virtual RadSplitButtonElement CreateSplitButtonElement()
Returns
RadSplitButtonElement
A new RadSplitButtonElement instance. |
GetNodesCount(RadTreeNodeCollection)
Gets the total count of nodes in the specified tree node collection, including all descendant nodes. This method recursively counts nodes in the entire subtree hierarchy.
Declaration
public int GetNodesCount(RadTreeNodeCollection nodes)
Parameters
RadTreeNodeCollection
nodes
The RadTreeNodeCollection to count nodes from. |
Returns
System.Int32
The total number of nodes in the collection and all its descendant collections. |
ProcessAutoSizeChanged(Boolean)
Processes changes to the AutoSize property and adjusts the layout behavior of the breadcrumb control accordingly. When AutoSize is enabled, the control stretches horizontally but not vertically; when disabled, it stretches in both directions.
Declaration
protected override void ProcessAutoSizeChanged(bool value)
Parameters
System.Boolean
value
The new AutoSize value indicating whether automatic sizing is enabled. |
Overrides
UpdateBreadCrumb(RadTreeNode)
Updates the breadcrumb display to show the path to the specified tree node. This method rebuilds the breadcrumb segments to reflect the hierarchy from the root to the target node.
Declaration
public void UpdateBreadCrumb(RadTreeNode node)
Parameters
RadTreeNode
node
The RadTreeNode to navigate to and display in the breadcrumb. |
Events
AutoCompleteItemsCreated
Occurs after auto-completion items have been created and populated. This event allows modification of the auto-completion suggestions collection including adding, removing, or reordering items.
Declaration
public event AutoCompleteItemsCreatedEventHandler AutoCompleteItemsCreated
Event Type
AutoCompleteItemsCreatedEventHandler
|
AutoCompleteItemsCreating
Occurs when auto-completion items are being created from user input. This event allows modification of the input text used for generating auto-completion suggestions, useful for implementing shortcuts.
Declaration
public event AutoCompleteItemsCreatingEventHandler AutoCompleteItemsCreating
Event Type
AutoCompleteItemsCreatingEventHandler
|
CollapsedItemCreated
Occurs when breadcrumb segments are collapsed due to insufficient display space and menu items are created for collapsed segments. This event allows customization of collapsed menu items or prevention of specific items from being added to the collapsed collection.
Declaration
public event AssociatedMenuItemEventHandler CollapsedItemCreated
Event Type
AssociatedMenuItemEventHandler
|
CollapsedItemsCreated
Occurs after all collapsed menu items have been created when breadcrumb segments don't fit in the available space. This event allows final modifications to the collapsed items collection including reordering and custom item management.
Declaration
public event AssociatedMenuItemCollectionEventHandler CollapsedItemsCreated
Event Type
AssociatedMenuItemCollectionEventHandler
|
HistoryItemCreated
Occurs when the user navigates to a new path and a history entry is being created. This event allows customization of history menu items or prevention of specific paths from being added to the navigation history.
Declaration
public event AssociatedMenuItemEventHandler HistoryItemCreated
Event Type
AssociatedMenuItemEventHandler
|
PathParsed
Occurs after a navigation path has been successfully parsed and a RadTreeNode is about to be selected. This event allows changing the selected node or handling cases where the parsed path is invalid.
Declaration
public event PathParsedEventHandler PathParsed
Event Type
PathParsedEventHandler
|
PathParsing
Occurs when a navigation path is about to be parsed from user input. This event allows modification of the path string or cancellation of the parsing operation before navigation occurs.
Declaration
public event PathParsingEventHandler PathParsing
Event Type
PathParsingEventHandler
|
RootNodesRequested
Occurs when the root nodes of the associated tree view are requested during path parsing operations. This event allows modification of the default root nodes collection by adding, removing, or replacing nodes.
Declaration
public event TreeNodeCollectionEventHandler RootNodesRequested
Event Type
TreeNodeCollectionEventHandler
|
SplitButtonCreated
Occurs after a RadSplitButtonElement has been created for a breadcrumb segment. This event allows customization of button properties and modification of the dropdown menu items collection.
Declaration
public event SplitButtonCreatedEventHandler SplitButtonCreated
Event Type
SplitButtonCreatedEventHandler
|
SplitButtonCreating
Occurs when a RadSplitButtonElement is being created for a breadcrumb segment. This event allows replacement with a custom button implementation or cancellation of button creation for specific nodes.
Declaration
public event SplitButtonCreatingEventHandler SplitButtonCreating
Event Type
SplitButtonCreatingEventHandler
|