Window

Defined in : <DataMorph/window.h>

class dm::Window;

This class represents a Window, which is a frame which can be drawn on.

Overview

Window is meant to be inherited from by the plugin developer. It is responsible for rendering a named frame which can be customized using ImGui. Note that there’s no need to call ImGui::Begin and ImGui::End. The function that must be overriden is OnRender. In its core, this class is actually just a C++ wrapper around the internal C API.

Namespace : dm
Inherits from : dm::abi::IWindow

Members

Constructors and assignments
(constructor)Constructs the Window object
Getters
GetNumIDReturns the numerical ID of the window
GetDisplayNameReturns the displayed window name
GetInternalNameReturns the internal ImGui identifier
GetFullNameReturns the full ImGui-formatted name
IsFocusedReturns whether the window is focused
IsOpenReturns whether the window is open
IsHiddenReturns whether the window is hidden
HasCloseButtonReturns whether the close button is shown
GetDFlagsReturns the ImGui docking flags
GetWFlagsReturns the ImGui window flags
GetDockNodeReturns a dock node ID
GetDockSpaceIDReturns the main dockspace ID
Setters & State control
SetNameSets the window display name
SetInternalNameSets the internal window name
SetOpenSets the open state
SetHiddenSets the hidden state
SetShowCloseButtonSets the close button visibility
SetDFlagsSets the docking flags
SetWFlagsSets the window flags
Window control
OpenOpens the window
CloseCloses the window
ShowShows the window
HideHides the window
UpdateUpdates and renders the window
Docking
DockDocks a window into this dock space
AddDockNodeAdds a dock node to the dock space
Inherited overriden methods
IWindow::OnAttachCalled when the window is attached
IWindow::OnDetachCalled when the window is detached
IWindow::OnPreRenderCalled before rendering
IWindow::OnPostRenderCalled after rendering
IWindow::OnMenuBarRenders the menu bar
IWindow::InitDockSpaceInitializes the dock space
IWindow::OnPreDockUpdateCalled before dock update
IWindow::OnPostDockUpdateCalled after dock update
Inherited abstract methods
IWindow::OnRenderRenders the window content