ussClassName
The USS class name for a UXML attribute field.
Read time 1 minuteLast updated 12 days ago
Definition
- Type: Field
- Namespace: Unity.UIToolkit.Editor
- Assembly: UnityEditor
public const string ussClassName = "unity-uxml-attribute-field"
Remarks
The following example finds and styles these controls by their USS class names.
Examples
// The USS class names let you find or style these controls.var field = root.Q<UxmlAttributeField>(className: UxmlAttributeField.ussClassName);var decorator = root.Q<UxmlAttributeFieldDecorator>(className: UxmlAttributeFieldDecorator.ussClassName);if (field != null) field.style.marginTop = 2;if (decorator != null) decorator.style.marginBottom = 2;