Provides a component with list of options that the user can choose from. More...
This element was introduced in Qt Quick Components 1.0.
There are two typical use cases for the ContextMenu component. You can use it as a context sensitive menu that opens, for example, on an object's long press signal, or you can use it to show a submenu.
The following code snippet shows how to create a ContextMenu.
ContextMenu { id: cmykMenu MenuLayout { MenuItem { text: "Cyan" onClicked: rect.color = "Cyan" } ... } }
The screenshot below illustrates the result of the code snippet.

See the Menu documentation for an example on how to use a ContextMenu as a submenu.
Provides access to the menu items in the context menu. It is recommended to use a single MenuLayout instance as the context menu content. Usage of other objects may result in unexpected behaviour.
Symbian:
If platformInverted is true, the component is visualized with the inverted style. For more information, see Using Inverted Style with Symbian Components. By default platformInverted is false.
This property group was introduced in Qt Quick Components 1.1.
Indicates the status of a context menu. The possible values are as follows:
This property is not used in Symbian. The context menu always uses the predefined position and fading policy.
Hides the context menu from the user. Normally a context menu is closed when the user selects an item from the menu. Context menu is also closed when the user clicks outside the menu.