語言

CustomPopupPlacementCallback 代理人

定義

代表一種為控制點提供自訂定位 Popup 的方法。

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() 

參數

popupSize
Size

控制的Size部分Popup。

targetSize
Size

Size的 PlacementTarget。

offset
Point

這些數據 Point 是從 HorizontalOffset 和 VerticalOffset 屬性值計算出來的。

傳回值

控制相對於 CustomPopupPlacement的一系列可能Popup位置PlacementTarget。

備註

當彈出視窗顯示時,會選擇一個能最大化視窗可見面積 ToolTip 的點。 這些 ContextMenu、 Popup 和 ToolTip 類別各自定義了一個屬性 CustomPopupPlacementCallback。

擴充方法

名稱 Description
GetMethodInfo(Delegate)

取得一個代表指定代理所代表方法的物件。

適用於

另請參閱