UnityEditor.EditorGUILayout.RectField C# (CSharp) Method

RectField() public static method

Make an X, Y, W & H field for entering a Rect.

public static RectField ( GUIContent label, Rect value ) : Rect
label UnityEngine.GUIContent Label to display above the field.
value UnityEngine.Rect The value to edit.
return UnityEngine.Rect
        public static Rect RectField(GUIContent label, Rect value, params GUILayoutOption[] options)
        {
            bool hasLabel = EditorGUI.LabelHasContent(label);
            float propertyHeight = EditorGUI.GetPropertyHeight(SerializedPropertyType.Rect, label);
            Rect position = s_LastRect = GetControlRect(hasLabel, propertyHeight, EditorStyles.numberField, options);
            return EditorGUI.RectField(position, label, value);
        }

Same methods

EditorGUILayout::RectField ( Rect value ) : Rect
EditorGUILayout::RectField ( string label, Rect value ) : Rect