diff --git a/HellionChat/Ui/StatusBar.cs b/HellionChat/Ui/StatusBar.cs index 71c8d62..8883b92 100644 --- a/HellionChat/Ui/StatusBar.cs +++ b/HellionChat/Ui/StatusBar.cs @@ -144,14 +144,20 @@ internal sealed class StatusBar ImGui.TextUnformatted(_cachedTellsText); } - // Slot 5: version, right-aligned, muted + // Slot 5: version, right-aligned, muted. Hidden when the window is + // too narrow to fit all five slots — the other four need ~200 px + // before the version text starts clipping into them. var versionText = $"v{Plugin.Interface.Manifest.AssemblyVersion} · Hellion"; var versionWidth = ImGui.CalcTextSize(versionText).X; var contentRegionMax = ImGui.GetContentRegionMax().X; - ImGui.SameLine(contentRegionMax - versionWidth); - using (ImRaii.PushColor(ImGuiCol.Text, ColourUtil.RgbaToAbgr(theme.Colors.TextMuted))) + const float MinOtherSlotsWidth = 200f; + if (contentRegionMax - versionWidth > MinOtherSlotsWidth) { - ImGui.TextUnformatted(versionText); + ImGui.SameLine(contentRegionMax - versionWidth); + using (ImRaii.PushColor(ImGuiCol.Text, ColourUtil.RgbaToAbgr(theme.Colors.TextMuted))) + { + ImGui.TextUnformatted(versionText); + } } }