Skip to content

MenuPlacement enumeration

Where a ContextMenu opens relative to its placement target. Side placements flip to the opposite side when the preferred side has no room.

Guide: C# Markup guide

public enum MenuPlacement
name value description
Pointer 0 At the pointer position. The context-menu default.
Below 1 Under the target’s bottom edge, flipping above the top edge when out of room.
Above 2 Over the target’s top edge, flipping below when out of room.
Right 3 Beside the target’s right edge, flipping to the left when out of room.
Left 4 Beside the target’s left edge, flipping to the right when out of room.