diff options
Diffstat (limited to '3rdparty/imgui-node-editor/imgui_canvas.h')
-rw-r--r-- | 3rdparty/imgui-node-editor/imgui_canvas.h | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/3rdparty/imgui-node-editor/imgui_canvas.h b/3rdparty/imgui-node-editor/imgui_canvas.h index acbb8ae..e5e4959 100644 --- a/3rdparty/imgui-node-editor/imgui_canvas.h +++ b/3rdparty/imgui-node-editor/imgui_canvas.h @@ -1,11 +1,11 @@ -// Canvas widget - view over infinite virtual space. +// Canvas widget - view over infinite virtual space. // // Canvas allows you to draw your widgets anywhere over infinite space and provide // view over it with support for panning and scaling. // // When you enter a canvas ImGui is moved to virtual space which mean: // - ImGui::GetCursorScreenPos() return (0, 0) and which correspond to top left corner -// of the canvas on the screen (this can be changed usign CanvasView()). +// of the canvas on the screen (this can be changed using CanvasView()). // - Mouse input is brought to canvas space, so widgets works as usual. // - Everything you draw with ImDrawList will be in virtual space. // @@ -23,7 +23,7 @@ // as usual in ImGui. // // While drawing inside canvas you can translate position from world (usual ImGui space) -// to virtual space and back usign CanvasFromWorld()/CanvasToWorld(). +// to virtual space and back using CanvasFromWorld()/CanvasToWorld(). // // Canvas can be nested in each other (they are regular widgets after all). There // is a way to transform position between current and parent canvas with @@ -35,6 +35,8 @@ // Note: // It is not valid to call canvas API outside of BeginCanvas() / EndCanvas() scope. // +// VERSION 0.1 +// // LICENSE // This software is dual-licensed to the public domain and under the following // license: you are granted a perpetual, irrevocable license to copy, modify, @@ -248,8 +250,16 @@ private: ImVec2 m_WindowCursorMaxBackup; # if defined(IMGUI_HAS_VIEWPORT) + ImVec2 m_WindowPosBackup; ImVec2 m_ViewportPosBackup; ImVec2 m_ViewportSizeBackup; +# if IMGUI_VERSION_NUM > 18002 + ImVec2 m_ViewportWorkPosBackup; + ImVec2 m_ViewportWorkSizeBackup; +# else + ImVec2 m_ViewportWorkOffsetMinBackup; + ImVec2 m_ViewportWorkOffsetMaxBackup; +# endif # endif }; |