mirror of
https://github.com/ocornut/imgui.git
synced 2026-02-01 09:34:31 +00:00
Docking: fixed various rendering issues and ability to have rounded floating dock nodes. Amend 91ce8cc. (#6993, #6151)
This commit is contained in:
@@ -8219,10 +8219,12 @@ bool ImGui::Begin(const char* name, bool* p_open, ImGuiWindowFlags flags)
|
||||
|
||||
// Lock window rounding for the frame (so that altering them doesn't cause inconsistencies)
|
||||
// Large values tend to lead to variety of artifacts and are not recommended.
|
||||
if (window->RootWindowDockTree->ViewportOwned)
|
||||
if ((flags & ImGuiWindowFlags_ChildWindow) && !window->DockIsActive)
|
||||
window->WindowRounding = style.ChildRounding;
|
||||
else if (window->RootWindowDockTree->ViewportOwned)
|
||||
window->WindowRounding = 0.0f;
|
||||
else
|
||||
window->WindowRounding = ((flags & ImGuiWindowFlags_ChildWindow) && !window->DockIsActive) ? style.ChildRounding : ((flags & ImGuiWindowFlags_Popup) && !(flags & ImGuiWindowFlags_Modal)) ? style.PopupRounding : style.WindowRounding;
|
||||
window->WindowRounding = ((flags & ImGuiWindowFlags_Popup) && !(flags & ImGuiWindowFlags_Modal)) ? style.PopupRounding : style.WindowRounding;
|
||||
|
||||
// For windows with title bar or menu bar, we clamp to FrameHeight(FontSize + FramePadding.y * 2.0f) to completely hide artifacts.
|
||||
//if ((window->Flags & ImGuiWindowFlags_MenuBar) || !(window->Flags & ImGuiWindowFlags_NoTitleBar))
|
||||
|
||||
Reference in New Issue
Block a user