void OnGUI() { #region 单例 格式 标题 GetEditorController(); InitGUIStyle(); CheckScenePath(); if (!gm) { return; } float h = 1200; float w = position.width; if (position.height < h) { w -= 15; } scrollPos = GUI.BeginScrollView(new Rect(0, 0, position.width, position.height), scrollPos, new Rect(0, 0, w, h)); GUILayout.BeginArea(new Rect(5, 5, w - 10, h)); GUILayout.Label("位置识别展示编辑器", subtitleLabelStyle); #endregion #region 开始 isShowStartPart = GUITools.DrawBox(isShowStartPart, "开始", partTitleStyle, StartBox); #endregion #region 总体介绍 isShowIntroducePart = GUITools.DrawBox(isShowIntroducePart, "总体介绍", partTitleStyle, IntroduceBox); #endregion #region 模型管理 isShowTransformPart = GUITools.DrawBox(isShowTransformPart, "模型管理", partTitleStyle, TransformBox); #endregion #region 部件管理 isShowUnitPart = GUITools.DrawBox(isShowUnitPart, "部件管理", partTitleStyle, UnitBox); #endregion GUILayout.EndArea(); GUI.EndScrollView(); }