DockLayoutManager.ShowingDockHints Event
Allows you to disable individual dock guides and hide specific dock hints based on a condition.
Namespace: DevExpress.Xpf.Docking
Assembly: DevExpress.Xpf.Docking.v25.1.dll
NuGet Package: DevExpress.Wpf.Docking
Declaration
Event Data
The ShowingDockHints event's data class is ShowingDockHintsEventArgs. The following properties provide information specific to this event:
| Property | Description |
|---|---|
| DraggingSource | Gets the dragged item’s owner. |
| DraggingTarget | Gets the target of the dragged item. |
| Handled | Gets or sets a value that indicates the present state of the event handling for a routed event as it travels the route. Inherited from RoutedEventArgs. |
| OriginalSource | Gets the original reporting source as determined by pure hit testing, before any possible Source adjustment by a parent class. Inherited from RoutedEventArgs. |
| RoutedEvent | Gets or sets the RoutedEvent associated with this RoutedEventArgs instance. Inherited from RoutedEventArgs. |
| Source | Gets or sets a reference to the object that raised the event. Inherited from RoutedEventArgs. |
The event data class exposes the following methods:
| Method | Description |
|---|---|
| Disable(DockHint) | Disables the DockHint. |
| DisableAll() | Disables all DockHints. |
| GetIsEnabled(DockHint) | Gets whether the DockHint item is enabled. |
| GetIsVisible(DockGuide) | Gets whether the DockGuide item is visible. |
| Hide(DockGuide) | Hides the DockGuide item. |
| Hide(DockHint) | Hides the DockHint item. |
| HideAll() | Hides all DockGuides. |
| InvokeEventHandler(Delegate, Object) | When overridden in a derived class, provides a way to invoke event handlers in a type-specific way, which can increase efficiency over the base implementation. Inherited from RoutedEventArgs. |
| OnSetSource(Object) | When overridden in a derived class, provides a notification callback entry point whenever the value of the Source property of an instance changes. Inherited from RoutedEventArgs. |
Remarks
When a user drags a dock item over dock panels, the DockLayoutManager displays the following dock guides: left, top, right, bottom, and central. Dock guides display hints (for example, the central dock guide displays five hints: Center, CenterBottom, CenterLeft, CenterRight, and CenterTop).

Handle the ShowingDockHints event to disable individual dock guides and hide specific dock hints based on a condition. Use the following methods: e.DisableAll, e.Disable, e.HideAll, and e.Hide. The e.DraggingTarget event parameter identifies the dragged dock panel.
void OnShowingDockHints(object sender, ShowingDockHintsEventArgs e) {
// Hide all Dock Guides while dragging a panel over Panel1
if(object.Equals(e.DraggingTarget, Panel1)) {
e.HideAll();
return;
}
// Disable all Dock Hints while dragging over Panel3
if(object.Equals(e.DraggingTarget, Panel3)) {
e.DisableAll();
return;
}
// Disable and hide specific Dock Hints and Dock Guides while dragging over Panel4
if(object.Equals(e.DraggingTarget, Panel4)) {
e.Disable(DockHint.SideLeft);
e.Disable(DockHint.AutoHideLeft);
e.Disable(DockHint.CenterLeft);
e.Disable(DockHint.CenterRight);
e.Hide(DockGuide.Top);
e.Hide(DockGuide.Bottom);
return;
}
}
Warning
Dock Hints are rendered on a transparent window, which may not function correctly on systems with transparency-related optimizations, such as Citrix. Issues may include invisible or disappearing Dock Hints.