Summary
Represents a
Menu
or ContextMenu
.
- Namespace
- Avalonia
.Controls - Interfaces
- Implementing Types
graph BT
Type-.->Interface0["IMenuElement"]
click Interface0 "/api/Avalonia.Controls/IMenuElement"
Type-.->Interface1["IControl"]
click Interface1 "/api/Avalonia.Controls/IControl"
Type-.->Interface2["IDataTemplateHost"]
click Interface2 "/api/Avalonia.Controls.Templates/IDataTemplateHost"
Type-.->Interface3["ILayoutable"]
click Interface3 "/api/Avalonia.Layout/ILayoutable"
Type-.->Interface4["IInputElement"]
click Interface4 "/api/Avalonia.Input/IInputElement"
Type-.->Interface5["IInteractive"]
click Interface5 "/api/Avalonia.Interactivity/IInteractive"
Type-.->Interface6["IVisual"]
click Interface6 "/api/Avalonia.VisualTree/IVisual"
Type-.->Interface7["IStyledElement"]
click Interface7 "/api/Avalonia/IStyledElement"
Type-.->Interface8["IStyleable"]
click Interface8 "/api/Avalonia.Styling/IStyleable"
Type-.->Interface9["INamed"]
click Interface9 "/api/Avalonia/INamed"
Type-.->Interface10["IStyleHost"]
click Interface10 "/api/Avalonia.Styling/IStyleHost"
Type-.->Interface11["ILogical"]
click Interface11 "/api/Avalonia.LogicalTree/ILogical"
Type-.->Interface12["IResourceHost"]
click Interface12 "/api/Avalonia.Controls/IResourceHost"
Type-.->Interface13["IResourceNode"]
click Interface13 "/api/Avalonia.Controls/IResourceNode"
Type-.->Interface14["IDataContextProvider"]
click Interface14 "/api/Avalonia/IDataContextProvider"
Type-.->Interface15["IAvaloniaObject"]
click Interface15 "/api/Avalonia/IAvaloniaObject"
Type-.->Interface16["ISupportInitialize"]
Type["IMenu"]
class Type type-node
Implementing0["ContextMenu"]-.->Type
click Implementing0 "/api/Avalonia.Controls/ContextMenu"
Implementing1["MenuFlyoutPresenter"]-.->Type
click Implementing1 "/api/Avalonia.Controls/MenuFlyoutPresenter"
Implementing2["MenuBase"]-.->Type
click Implementing2 "/api/Avalonia.Controls/MenuBase"
Implementing3["Menu"]-.->Type
click Implementing3 "/api/Avalonia.Controls/Menu"
Syntax
public interface IMenu : IMenuElement, IControl, IDataTemplateHost, ILayoutable, IInputElement,
IInteractive, IVisual, IStyledElement, IStyleable, INamed, IStyleHost, ILogical, IResourceHost,
IResourceNode, IDataContextProvider, IAvaloniaObject, ISupportInitialize
Properties
Name | Value | Summary |
---|---|---|
InteractionHandler | I |
Gets the menu interaction handler.
|
IsOpen | bool |
Gets a value indicating whether the menu is open.
|
Extension Methods
Name | Value | Summary |
---|---|---|
AddDisposableHandler |
IDisposable |
Adds a handler for the specified routed event and returns a disposable that can terminate the event subscription.
|
Bind |
IDisposable |
Binds a
AvaloniaProperty to an observable.
|
Bind |
IDisposable |
Binds a
AvaloniaProperty to an observable.
|
BindClass |
IDisposable | |
BringIntoView |
void |
Tries to bring the control into view.
From ControlExtensions
|
BringIntoView |
void |
Tries to bring the control into view.
From ControlExtensions
|
Calculate |
int |
Calculates the distance from a visual's ancestor.
From VisualExtensions
|
Find |
T |
Finds a named element in an
INameScope .
From NameScopeExtensions
|
FindAncestorOfType |
T |
Finds first ancestor of given type.
From VisualExtensions
|
Find |
IVisual |
Tries to get the first common ancestor of two visuals.
From VisualExtensions
|
FindControl |
T |
Finds the named control in the scope of the specified control.
From ControlExtensions
|
FindDataTemplate |
IDataTemplate? |
Find a data template that matches a piece of data.
|
FindDescendantOfType |
T |
Finds first descendant of given type.
From VisualExtensions
|
Find |
T |
Finds first ancestor of given type.
From LogicalExtensions
|
Find |
T |
Finds first descendant of given type.
From LogicalExtensions
|
FindNameScope |
INameScope |
From NameScopeExtensions
|
FindResource |
object? |
Finds the specified resource by searching up the logical tree and then global styles.
|
Get |
T |
Gets a named element from an
INameScope or throws if no element of the
requested name was found.
From NameScopeExtensions
|
GetBindingObservable |
IObservable |
Gets an observable for a
AvaloniaProperty .
|
GetBindingObservable |
IObservable |
Gets an observable for a
AvaloniaProperty .
|
GetBindingSubject |
ISubject |
Gets a subject for a
AvaloniaProperty .
|
GetBindingSubject |
ISubject |
Gets a subject for a
AvaloniaProperty .
|
GetInputElementsAt |
IEnumerable |
Returns the active input elements at a point on an
IInputElement .
From InputExtensions
|
GetLogicalAncestors |
IEnumerable |
Enumerates the ancestors of an
ILogical in the logical tree.
From LogicalExtensions
|
GetLogicalChildren |
IEnumerable |
Enumerates the children of an
ILogical in the logical tree.
From LogicalExtensions
|
Get |
IEnumerable |
Enumerates the descendants of an
ILogical in the logical tree.
From LogicalExtensions
|
GetLogicalParent |
ILogical |
Gets the logical parent of an
ILogical .
From LogicalExtensions
|
GetLogicalParent |
T |
Gets the logical parent of an
ILogical .
From LogicalExtensions
|
GetLogicalSiblings |
IEnumerable |
Enumerates the siblings of an
ILogical in the logical tree.
From LogicalExtensions
|
GetObservable |
IObservable |
Gets an observable for a
AvaloniaProperty .
|
GetObservable |
IObservable |
Gets an observable for a
AvaloniaProperty .
|
GetObservable |
IObservable |
Gets an observable for a
RoutedEvent<TEventArgs> .
|
Get |
IObservable |
Gets an observable that listens for property changed events for an
AvaloniaProperty .
|
Get |
IObservable |
|
Get |
IEnumerable |
Enumerates an
ILogical and its ancestors in the logical tree.
From LogicalExtensions
|
Get |
IEnumerable |
Enumerates an
ILogical and its descendants in the logical tree.
From LogicalExtensions
|
Get |
IEnumerable |
Enumerates an
IVisual and its ancestors in the visual tree.
From VisualExtensions
|
Get |
IEnumerable |
Enumerates an
IVisual and its descendants in the visual tree.
From VisualExtensions
|
GetSubject |
ISubject |
Gets a subject for a
AvaloniaProperty .
|
GetSubject |
ISubject |
Gets a subject for a
AvaloniaProperty .
|
GetVisualAncestors |
IEnumerable |
Enumerates the ancestors of an
IVisual in the visual tree.
From VisualExtensions
|
GetVisualAt |
IVisual |
Gets the first visual in the visual tree whose bounds contain a point.
From VisualExtensions
|
GetVisualAt |
IVisual |
Gets the first visual in the visual tree whose bounds contain a point.
From VisualExtensions
|
GetVisualChildren |
IEnumerable |
Enumerates the children of an
IVisual in the visual tree.
From VisualExtensions
|
GetVisualDescendants |
IEnumerable |
Enumerates the descendants of an
IVisual in the visual tree.
From VisualExtensions
|
GetVisualParent |
IVisual |
Gets the visual parent of an
IVisual .
From VisualExtensions
|
GetVisualParent |
T |
Gets the visual parent of an
IVisual .
From VisualExtensions
|
GetVisualRoot |
IRenderRoot |
Gets the root visual for an
IVisual .
From VisualExtensions
|
GetVisualsAt |
IEnumerable |
Enumerates the visible visuals in the visual tree whose bounds contain a point.
From VisualExtensions
|
GetVisualsAt |
IEnumerable |
Enumerates the visuals in the visual tree whose bounds contain a point.
From VisualExtensions
|
HitTestCustom |
bool | |
InputHitTest |
IInputElement? |
Returns the topmost active input element at a point on an
IInputElement .
From InputExtensions
|
InputHitTest |
IInputElement? |
Returns the topmost active input element at a point on an
IInputElement .
From InputExtensions
|
IsLogicalAncestorOf |
bool |
Tests whether an
ILogical is an ancestor of another logical.
From LogicalExtensions
|
IsVisualAncestorOf |
bool |
Tests whether an
IVisual is an ancestor of another visual.
From VisualExtensions
|
PointToClient |
Point |
Converts a point from screen to client coordinates.
From VisualExtensions
|
PointToScreen |
PixelPoint |
Converts a point from client to screen coordinates.
From VisualExtensions
|
TransformToVisual |
Matrix? |
Returns a transform that transforms the visual's coordinates into the coordinates
of the specified to.
From VisualExtensions
|
TranslatePoint |
Point? |
Translates a point relative to this visual to coordinates that are relative to the specified visual.
From VisualExtensions
|
TryFindResource |
bool |
Tries to the specified resource by searching up the logical tree and then global styles.
|