Interface IPanel
Interface for classes implementing UI panels.
Namespace: UnityEngine.UIElements
Syntax
public interface IPanel : IDisposable
Properties
contextType
Describes in which context a VisualElement hierarchy is being ran.
Declaration
ContextType contextType { get; }
Property Value
Type | Description |
---|---|
ContextType |
contextualMenuManager
The Contextual menu manager for the panel.
Declaration
ContextualMenuManager contextualMenuManager { get; }
Property Value
Type | Description |
---|---|
ContextualMenuManager |
dispatcher
This Panel EventDispatcher.
Declaration
EventDispatcher dispatcher { get; }
Property Value
Type | Description |
---|---|
EventDispatcher |
focusController
Return the focus controller for this panel.
Declaration
FocusController focusController { get; }
Property Value
Type | Description |
---|---|
FocusController |
visualTree
Root of the VisualElement hierarchy.
Declaration
VisualElement visualTree { get; }
Property Value
Type | Description |
---|---|
VisualElement |
Methods
Pick(Vector2)
Returns the top element at this position. Will not return elements with pickingMode set to Ignore.
Declaration
VisualElement Pick(Vector2 point)
Parameters
Type | Name | Description |
---|---|---|
Vector2 | point | World coordinates. |
Returns
Type | Description |
---|---|
VisualElement | Top VisualElement at the position. Null if none was found. |
PickAll(Vector2, List<VisualElement>)
Returns all elements at this position. Will not return elements with pickingMode set to Ignore.
Declaration
VisualElement PickAll(Vector2 point, List<VisualElement> picked)
Parameters
Type | Name | Description |
---|---|---|
Vector2 | point | World coordinates. |
List<VisualElement> | picked | All Visualelements overlapping this position. |
Returns
Type | Description |
---|---|
VisualElement | Top VisualElement at the position. Null if none was found. |