Edit

Share via


CustomPopupPlacementCallback Delegate

Definition

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

public delegate cli::array <System::Windows::Controls::Primitives::CustomPopupPlacement> ^ CustomPopupPlacementCallback(Size popupSize, Size targetSize, Point offset);
public delegate System.Windows.Controls.Primitives.CustomPopupPlacement[] CustomPopupPlacementCallback(Size popupSize, Size targetSize, Point offset);
type CustomPopupPlacementCallback = delegate of Size * Size * Point -> CustomPopupPlacement[]
Public Delegate Function CustomPopupPlacementCallback(popupSize As Size, targetSize As Size, offset As Point) As CustomPopupPlacement() 

Parameters

popupSize
Size

The Size of the Popup control.

targetSize
Size

The Size of the PlacementTarget.

offset
Point

The Point computed from the HorizontalOffset and VerticalOffset property values.

Return Value

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

Remarks

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.

Extension Methods

GetMethodInfo(Delegate)

Gets an object that represents the method represented by the specified delegate.

Applies to

See also