I have a Custom Inspector and I want to have a preview for my inventory and i know that the OnPreviewGUI() is only for assets. So I’ve created an EditorWindow script. But…when I use this :
thanks it works …better because it’s just that now my static variables aren’t shown in the inspector …and there are to be shown
There are some posts on that kind of problem so i’ll work a bit on that before ask again.
public static GUIStyle styleFenetre;
public static GUIStyle styleBoite;
public static GUIStyle styleOnglets;
in OnInspectorGUI :
styleFenetre = (target as ConfigurationGUI).styles.styleFenetre;
styleBoite = (target as ConfigurationGUI).styles.styleBoite;
styleOnglets = (target as ConfigurationGUI).styles.styleOnglets;