fix(renderer): improve child window layout in logs

Updated the `ImGui.BeginChild` call to include the
`ImGuiChildFlags.AlwaysUseWindowPadding` flag for better
layout behavior. Removed unnecessary indentation
operations for log entries, streamlining the rendering
process.
This commit is contained in:
whoswhip
2025-07-16 23:00:42 -04:00
parent 4b4cebd517
commit 51744ca9c7
+1 -5
View File
@@ -311,18 +311,14 @@ namespace Spectrum
} }
ImGui.SeparatorText("Logs"); ImGui.SeparatorText("Logs");
ImGui.BeginChild("Logs", new Vector2(0, -34)); ImGui.BeginChild("Logs", new Vector2(0, -34), ImGuiChildFlags.AlwaysUseWindowPadding);
ImGui.Dummy(new Vector2(0, 4));
var _LogEntries = LogManager.LogEntries.ToList(); var _LogEntries = LogManager.LogEntries.ToList();
foreach (var log in _LogEntries) foreach (var log in _LogEntries)
{ {
ImGui.Indent(8);
ImGui.Text(log.ToString()); ImGui.Text(log.ToString());
ImGui.Unindent(8);
} }
ImGui.Dummy(new Vector2(0, 4));
ImGui.EndChild(); ImGui.EndChild();
ImGui.Dummy(new Vector2(0, 1)); ImGui.Dummy(new Vector2(0, 1));