- Home /
Is there a way to manually resize the controls inside an editor window at runtime?
As far as I know, we have 2 way to control the layout of multiple controls inside an editor gui : - using the EditorGUI and GUI objects, wich we pass rectangles to them in, - using the EditorGUILayout and GUILayout objects, wich use an automatic layouting system.
But it both cases, each controls have a fixed proportions. If I resize the entire window, the controls keep the same proportion, and with rectangles, they keep the same size whatsoever.
So, is there a way to resize ourself the controls when using the editor?
To illustrate, I have this :
public void OnGUI
{
EditorGUILayout.BeginHorizontal();
GUILayout.Button("hello");
GUILayout.Button("there!");
EditorGUILayout.EndHorizontal();
}
In this case, how could I "move" the space between the two button with my mouse?
For those familiar with Qt, it is like I'm asking for the features of a QSplitter. http://harmattan-dev.nokia.com/docs/library/html/qt4/qsplitter.html#details
Answer by SkillDev · Jan 27, 2014 at 06:47 AM
if you know about layouts like Grid, StackPanel, Canvas, WrapPanel, ... like WPF take a look at Skill project Skill UI V1
also you can download latest version at http://skill.codeplex.com/
Your answer
Follow this Question
Related Questions
How to build an editor window with a treeview widget? 4 Answers
Editor Window stuck on a blank white screen 2 Answers
Editor controls problem 0 Answers
Game window size from editor window in editor mode 1 Answer
Adjustable width columns in editor 0 Answers