- Home /
Question by
Paulo-Henrique025 · Oct 31, 2012 at 03:49 PM ·
guilayouteditorguilayout
Odd GUILayout Placement
Hey guys, how can I fix this odd placement? I want the enum popup to be closer to the text;
Here is the code:
playerSets = EditorGUILayout.Foldout(playerSets, "Player Sets");
if(playerSets)
{
SceneMaster.PlayerSet ps;
ps = _target.set1;
ps.chars = SceneMaster.Characters.Astronaut_Female;
ps.name = ps.chars.ToString();
GUILayout.Label("Set " + ps.name, EditorStyles.boldLabel);
GUILayout.BeginHorizontal();
ps.wp1 = (SceneMaster.Weapons)EditorGUILayout.EnumPopup("Primary", ps.wp1);
ps.wp2 = (SceneMaster.Weapons)EditorGUILayout.EnumPopup("Secondary", ps.wp2);
GUILayout.EndHorizontal();
}
There is no BeginVertical nor BeginHorizontal calls nested above.
Comment
Your answer
Follow this Question
Related Questions
Setting height via GUILayout.Height() has no effect to BeginVertical in Inspector 0 Answers
EditorGUI, EditorGUILayout, GUI, GUILayout... pshhh... WHEN TO USE WHAT?! 3 Answers
What is the difference between editorguilayout and guilayout? 1 Answer
Custom Inspector tooltips behaving inconsistently 0 Answers
Small GUILayout button 1 Answer