Class: ImGuiViewport
- Inherits:
-
FFI::Struct
- Object
- FFI::Struct
- ImGuiViewport
- Defined in:
- lib/imgui.rb
Overview
-
Currently represents the Platform Window created by the application which is hosting our Dear ImGui windows.
-
In ‘docking’ branch with multi-viewport enabled, we extend this concept to have multiple active viewports.
-
In the future we will extend this concept further to also represent Platform Monitor and support a “no main platform window” operation mode.
-
About Main Area vs Work Area:
-
Main Area = entire viewport.
-
Work Area = entire viewport minus sections used by main menu bars (for platform windows), or by task bar (for platform monitor).
-
Windows are generally trying to stay within the Work Area of their host viewport.
-
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.create ⇒ Object
1474 1475 1476 |
# File 'lib/imgui.rb', line 1474 def self.create() return ImGuiViewport.new(ImGui::ImGuiViewport_ImGuiViewport()) end |
Instance Method Details
#destroy ⇒ Object
1478 1479 1480 |
# File 'lib/imgui.rb', line 1478 def destroy() ImGui::ImGuiViewport_destroy(self) end |
#GetCenter ⇒ Object
1462 1463 1464 1465 1466 |
# File 'lib/imgui.rb', line 1462 def GetCenter() pOut = ImVec2.new ImGui::ImGuiViewport_GetCenter(pOut, self) return pOut end |
#GetWorkCenter ⇒ Object
1468 1469 1470 1471 1472 |
# File 'lib/imgui.rb', line 1468 def GetWorkCenter() pOut = ImVec2.new ImGui::ImGuiViewport_GetWorkCenter(pOut, self) return pOut end |