docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class StylingUtility

    Provides utility methods around styling.

    Inheritance
    object
    StylingUtility
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Unity.Properties.UI
    Assembly: Unity.Properties.UI.Editor.dll
    Syntax
    public static class StylingUtility

    Methods

    AlignInspectorLabelWidth(VisualElement)

    Dynamically computes and sets the width of Label elements so that they stay properly aligned when indented with Foldout elements.

    Declaration
    public static void AlignInspectorLabelWidth(VisualElement root)
    Parameters
    Type Name Description
    VisualElement root

    The target element

    Remarks

    This will effectively inline the width and the minWidth value of every VisualElement under the provided root.

    In This Article
    Back to top
    Copyright © 2025 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)