CustomPopupPlacementCallback Delegate


The .NET API Reference documentation has a new home. Visit the .NET API Browser on to see the new experience.

Represents a method that provides custom positioning for a Popup control.

Namespace:   System.Windows.Controls.Primitives
Assembly:  PresentationFramework (in PresentationFramework.dll)

public delegate CustomPopupPlacement[] CustomPopupPlacementCallback(
	Size popupSize,
	Size targetSize,
	Point offset


Type: System.Windows.Size

The Size of the Popup control.

Type: System.Windows.Size

The Size of the PlacementTarget.

Type: System.Windows.Point

The Point computed from the HorizontalOffset and VerticalOffset property values.

Return Value

Type: System.Windows.Controls.Primitives.CustomPopupPlacement[]

An array of possible CustomPopupPlacement positions for the Popup control relative to the PlacementTarget.

When the Popup is displayed, a point is chosen that maximizes the amount of the ToolTip window that is visible. The ContextMenu, Popup and ToolTip classes each define a property of type CustomPopupPlacementCallback.

.NET Framework
Available since 3.0
Return to top