Peek Popup
The RadOfficeNavigationBar
control provides a popup preview window for its elements when the mouse is over one of them. This functionality is disabled by default. To enable it, set the IsPeekPopupEnabled
property to True.
Setting the IsPeekPopupEnabled property
Setting the IsPeekPopupEnabled property in code
Displayed peek popup
Setting the Peek Popup Content
Each RadOfficeNavigationBarItem
element allows you to customize the content that will be displayed. To do so, you can use its PeekPopupContent
, PeekPopupContentTemplate
, and PeekPopupContentTemplateSelector
properties.
Setting the peek popup content
Customizing the Appearance of the Peek Popup
The peek popup's appearance can be customized for each RadOfficeNavigationBarItem element. To apply a custom style, you can utilize the PeekPopupStyle
property. The custom Style has to target the RadCallout
element as this element is used as the popup.
The following example is based on the RadOfficeNavigationBarItem's implementation from the above code snippet.
Customizing the appearance of the peek popup
Setting a String Format to the Peek Popup Content
The RadOfficeNavigationBarItem element allows you to apply a string format to the value that is set to the PeekPopupContent property. To set a string format, you can set the PeekPopupContentStringFormat
property.
Applying a string format to the peek popup content
Controlling the Show/Close Popup Delay
You can control the show/close delay of the peek popup. To do so, you can set the PeekPopupShowDelay
and PeekPopupCloseDelay
properties of RadOfficeNavigationBar.
Setting the PeekPopupShowDelay and PeekPopupCloseDelay properties
PeekPopupOpening Event
The RadOfficeNavigationBar exposes the PeekPopupOpening
event that will occur when peek popup is about to be opened. The event handler receives two arguments:
The sender parameter contains the RadOfficeNavigationBar element. This argument is of type object, but can be cast to the RadOfficeNavigationBar type.
-
The event arguments are of the type
PeekPopupOpeningEventArgs
. They expose the following properties:RadCallout
—This property contains the peek popup element, which is of the type RadCallout.CalloutPopupSettings
—The CalloutPopupSettings property contains information regarding the RadCallout element. This property is of the type CalloutPopupSettings.OfficeNavigationBarItem
—This property contains the RadOfficeNavigationBarItem that the peek popup belongs to.Cancel
—The Cancel property can be used to prevent the peek popup from opening. To stop the popup from opening, set this property to false.