語言

ContextMenuEventArgs.CursorTop 屬性

定義

它能取得滑鼠的垂直位置。

public:
 property double CursorTop { double get(); };
public double CursorTop { get; }
member this.CursorTop : double
Public ReadOnly Property CursorTop As Double

屬性值

滑鼠的垂直位置。

備註

當使用者透過右鍵點擊滑鼠開啟右鍵選單時,這個屬性會回傳滑鼠的位置。 透過設定 ContextMenu、 PlacementTarget、 PlacementRectangle、 Placement或 HorizontalOffset 屬性來指定 的位置VerticalOffsetProperty,不會影響 的CursorTop值。

當使用者使用鍵盤開啟右鍵選單,或關閉右鍵選單時,此屬性的值為 -1。

適用於