Search Unity

Is there a Unity Editor GUI Skin Template floating around somewhere?

Discussion in 'Immediate Mode GUI (IMGUI)' started by tonycoculuzzi, Feb 16, 2013.

  1. tonycoculuzzi

    tonycoculuzzi

    Joined:
    Jun 2, 2011
    Posts:
    301
    Anyone know of an Editor GUI skin template floating around anywhere? I'm looking for one so I can mimic the style of the Unity Editor, while adding my own touch to it, with new types of interface objects.
     
    Last edited: Feb 16, 2013
  2. dodo

    dodo

    Joined:
    Jul 13, 2011
    Posts:
    49
    Paste this code into an empty .cs file in your Editor folder and click "Save Editor Skin" in the Assets menu, it will save the inspector editor skin to your project folder.

    Code (csharp):
    1. using UnityEngine;
    2. using UnityEditor;
    3. using System.Collections;
    4.  
    5. public class DummyEditor : EditorWindow
    6. {
    7.     [MenuItem("Assets/Save Editor Skin")]
    8.     static public void SaveEditorSkin()
    9.     {
    10.         GUISkin skin = ScriptableObject.Instantiate(EditorGUIUtility.GetBuiltinSkin(EditorSkin.Inspector)) as GUISkin;
    11.         AssetDatabase.CreateAsset(skin, "Assets/EditorSkin.guiskin");
    12.     }
    13. }
     
    CanisLupus likes this.
  3. tonycoculuzzi

    tonycoculuzzi

    Joined:
    Jun 2, 2011
    Posts:
    301
    Thank you, this is great!
     
  4. Panthesilea

    Panthesilea

    Joined:
    May 31, 2013
    Posts:
    13
    I saved GUISkin, but when I build application it says: An asset is marked as dont save, but is included in the build
     
  5. DomDom

    DomDom

    Joined:
    Oct 18, 2013
    Posts:
    33