public void End() { EditorGUILayout.EndVertical(); if (visible) // Some space that cannot be placed in the GUIStyle unfortunately { GUILayout.Space(4); } EditorGUILayout.EndFadeGroup(); EditorGUILayout.EndVertical(); GUIUtilityx.PopTint(); }
public bool BeginFade() { var hermite = Hermite(0, 1, value); visible = EditorGUILayout.BeginFadeGroup(hermite); GUIUtilityx.PushTint(new Color(1, 1, 1, hermite)); Tick(); // Another vertical group is necessary to work around // a kink of the BeginFadeGroup implementation which // causes the padding to change when value!=0 && value!=1 EditorGUILayout.BeginVertical(); return(visible); }