VerticalGroupAttribute

VerticalGroup is used to gather properties together in a vertical group in the inspector.

This doesn't do much in and of itself, but in combination with other groups, such as HorizontalGroupAttribute it can be very useful.

namespace Sirenix.OdinInspector
{
[AttributeUsageAttribute((AttributeTargets)448, AllowMultiple = True, Inherited = True)]
public class VerticalGroupAttribute : PropertyGroupAttribute
}

Requirements

Namespace: Sirenix.OdinInspector
Assembly: Sirenix.OdinInspector
Version: 1.0.4.1

See Also

Constructors

Definition Description
VerticalGroupAttribute(string, int) Groups properties vertically.

Properties

Return Type Definition Description
float PaddingBottom Space in pixels at the bottom of the group.
float PaddingTop Space in pixels at the top of the group.

Methods

Return Type Definition Description
void CombineValuesWith(PropertyGroupAttribute) Combines properties that have been group vertically.

Example

The following example demonstrates how VerticalGroup can be used in conjuction with HorizontalGroupAttribute

public class MyComponent : MonoBehaviour
{
	[HorizontalGroup("Split")]
	[VerticalGroup("Split/Left")]
	public Vector3 Vector;
	
	[VerticalGroup("Split/Left")]
	public GameObject First;
	
	[VerticalGroup("Split/Left")]
	public GameObject Second;
	
	[VerticalGroup("Split/Right", PaddingTop = 18f)]
	public int A;
	
	[VerticalGroup("Split/Right")]
	public int B;
}