Legacy Documentation: Version 2018.2 (Go to current version)
LanguageEnglish
  • C#

EditorWindow.Show

public void Show();
public void Show(bool immediateDisplay);

Parameters

immediateDisplayImmediately display Show.

Description

Show the EditorWindow window.

EditorWindow.Show displays any window that has been created. In the script example below the window is created with no addition functionality. Many of the script examples in EditorWindow are more complex.

// Create an empty editor window and show it

using UnityEditor; using UnityEngine; using System.Collections;

public class Example : EditorWindow { [MenuItem("Example/Window position usage")] static void InitWindow() { Example window = (Example)GetWindow(typeof(Example)); window.Show(); } }
对文档有任何疑问,请移步至开发者社区提问,我们将尽快为您解答