Skip to content

ImGuiImplementation Class

A basic ImGui interface that adds the ImGuiMonoGameComponent to MonoGame, rendering ImGui over SadConsole.

C#
public static class ImGuiImplementation

Inheritance object

Gets the renderer for ImGui.

C#
public static ImGuiRenderer Renderer { get; }

Gets the MonoGame component that is rendering ImGui.

C#
public static ImGuiMonoGameComponent MonoGameComponent { get; }

Gets the list of UI objects that is drawn by ImGui.

C#
public static List<ImGuiObjectBase> UIObjects { get; }

Starts the ImGui system.

C#
public static void Start(bool disableFinalDraw = true, bool disableUpdate = false, bool disableInput = true, float fontSize = 18, string fontFileTTF = "Roboto-Regular.ttf")

disableFinalDraw bool
Turns off SadConsole.Settings.DoFinalDraw, which causes SadConsole to only render ImGui to the screen.

disableUpdate bool
Turns off SadConsole.Settings.DoUpdate, which pauses SadConsole’s update loop.

disableInput bool
Turns off SadConsole.Settings.Input.DoKeyboard and SadConsole.Settings.Input.DoMouse, allowing only ImGui to handle input.

fontSize float
The font size to use with ImGui.

fontFileTTF string
The TTF font file to use with ImGui.