Class AnchorPopupUtils
Utility class to compute the position of a popup based on the anchor's position and size.
Inherited Members
Namespace: Unity.AppUI.UI
Assembly: Unity.AppUI.dll
Syntax
public static class AnchorPopupUtils
Methods
ComputePosition(VisualElement, VisualElement, VisualElement, PositionOptions)
This method will return the possible position of UI element based on a specific context.
Declaration
public static PositionResult ComputePosition(VisualElement element, VisualElement anchor, VisualElement container, PositionOptions options)
Parameters
Type | Name | Description |
---|---|---|
VisualElement | element | The element which needs to be positioned |
VisualElement | anchor | The element used as an anchor for the element. |
VisualElement | container | The element used as container. |
PositionOptions | options | The options used to compute the position. |
Returns
Type | Description |
---|---|
PositionResult | The computed position. |
Exceptions
Type | Condition |
---|---|
ArgumentOutOfRangeException | The provided |