1.5 KiB
1.5 KiB
1. Build Configuration
- 1.1 Verify that
third_party/Imgui-1.92.7source files contain docking APIs (DockSpaceOverViewport,ImGuiConfigFlags_DockingEnable). If not, fetch the docking branch of imgui. - 1.2 Add
IMGUI_HAS_DOCKcompile definition incmake/modules/FindImgui.cmakeviatarget_compile_definitionson the imgui library target.
2. Runtime Docking Enablement
- 2.1 In
src/ui/ImGuiContext.cpp, addImGuiConfigFlags_DockingEnabletoio.ConfigFlagsin theInitialize()method. - 2.2 In
src/ui/Application.cpp, addImGui::DockSpaceOverViewport()call inRenderUI()afterNewFrame()and before any window/panelBegin/Endcalls.
3. Panel Migration to Dockable Layout
- 3.1 Remove all
ImGui::SetNextWindowPos()andImGui::SetNextWindowSize()calls from every panel window inApplication::RenderUI()(Scene Hierarchy, Layer Panel, Viewport, Property Panel, Stage Info, Demo Window). - 3.2 Add
ImGuiWindowFlags_NoCollapseto the four core panels: Scene Hierarchy, Layer Panel, Viewport, Property Panel. - 3.3 Verify that the View menu visibility toggles (Stage Info, Demo Window) continue to work with dockable windows.
4. Build and Verification
- 4.1 Run
cmake --preset defaultandcmake --buildto verify the project compiles without errors. - 4.2 Launch
App.exeand confirm: dockspace fills the window, panels are draggable/dockable/tabbable, layout persists after restart (checkimgui.ini), and View menu toggles work correctly.