Class UnityUiUtils
Helpers for Unity UI (uGUI) operations
Assembly: Serenity.UnityGlobal.Infrastructure.dll
Syntax
public static class UnityUiUtils
Methods
Declaration
public static RectTransform CalculateBoundingRect(RectTransform[] rectTransforms)
Parameters
| Type |
Name |
Description |
| RectTransform[] |
rectTransforms |
|
Returns
| Type |
Description |
| RectTransform |
|
Declaration
public static bool IsStretchedX(RectTransform rt)
Parameters
| Type |
Name |
Description |
| RectTransform |
rt |
|
Returns
Declaration
public static bool IsStretchedY(RectTransform rt)
Parameters
| Type |
Name |
Description |
| RectTransform |
rt |
|
Returns
Declaration
public static void SafeSetHeight(RectTransform rt, float height)
Parameters
| Type |
Name |
Description |
| RectTransform |
rt |
|
| float |
height |
|
Declaration
public static void SafeSetWidth(RectTransform rt, float width)
Parameters
| Type |
Name |
Description |
| RectTransform |
rt |
|
| float |
width |
|
WaitForComponent<T>(MonoBehaviour, GameObject, Action<T>, float)
Declaration
public static IEnumerator WaitForComponent<T>(MonoBehaviour context, GameObject root, Action<T> onFound, float timeout = 2) where T : Component
Parameters
| Type |
Name |
Description |
| MonoBehaviour |
context |
|
| GameObject |
root |
|
| Action<T> |
onFound |
|
| float |
timeout |
|
Returns
Type Parameters