From 1d3b429f1b48fa648462dac95e5a9f44193eed04 Mon Sep 17 00:00:00 2001 From: Jon Kazama Date: Sat, 23 May 2026 09:02:30 +0200 Subject: [PATCH] style(format): apply csharpier and markdownlint reflow --- HellionChat/Configuration.cs | 1 + HellionChat/NameDisplayModes.cs | 30 +++---- HellionChat/Ui/ChatInputBar.cs | 17 ++-- HellionChat/Ui/ChatLogWindow.cs | 23 +++--- HellionChat/Ui/SettingsTabs/Appearance.cs | 25 +++--- HellionChat/Ui/SettingsTabs/Chat.cs | 18 +++-- HellionChat/Ui/SettingsTabs/DataAndPrivacy.cs | 22 ++++-- HellionChat/Ui/SettingsTabs/General.cs | 18 +++-- HellionChat/Ui/SettingsTabs/Tabs.cs | 78 +++++++++++++++---- HellionChat/Ui/SettingsTabs/Window.cs | 10 ++- HellionChat/Util/SenderNameDisplay.cs | 7 +- HellionChat/_Helpers/SenderNameFormatter.cs | 7 +- docs/ROADMAP.md | 1 + 13 files changed, 176 insertions(+), 81 deletions(-) diff --git a/HellionChat/Configuration.cs b/HellionChat/Configuration.cs index 2777af9..644bf42 100755 --- a/HellionChat/Configuration.cs +++ b/HellionChat/Configuration.cs @@ -196,6 +196,7 @@ public class Configuration : IPluginConfiguration public bool CollapseKeepUniqueLinks; public bool SymbolPickerEnabled = true; public bool PlaySounds = true; + // AUDIO-1: playback volume (0-1) for the three bundled custom sounds. public float CustomSoundVolume = 0.5f; diff --git a/HellionChat/NameDisplayModes.cs b/HellionChat/NameDisplayModes.cs index cbdc140..4f71448 100644 --- a/HellionChat/NameDisplayModes.cs +++ b/HellionChat/NameDisplayModes.cs @@ -22,19 +22,21 @@ public enum NameFormMode public static class NameDisplayModeExt { - public static string Name(this WorldSuffixMode mode) => mode switch - { - WorldSuffixMode.Never => HellionStrings.NameDisplay_WorldSuffix_Never, - WorldSuffixMode.OtherWorldOnly => HellionStrings.NameDisplay_WorldSuffix_OtherWorldOnly, - WorldSuffixMode.Always => HellionStrings.NameDisplay_WorldSuffix_Always, - _ => mode.ToString(), - }; + public static string Name(this WorldSuffixMode mode) => + mode switch + { + WorldSuffixMode.Never => HellionStrings.NameDisplay_WorldSuffix_Never, + WorldSuffixMode.OtherWorldOnly => HellionStrings.NameDisplay_WorldSuffix_OtherWorldOnly, + WorldSuffixMode.Always => HellionStrings.NameDisplay_WorldSuffix_Always, + _ => mode.ToString(), + }; - public static string Name(this NameFormMode mode) => mode switch - { - NameFormMode.Full => HellionStrings.NameDisplay_NameForm_Full, - NameFormMode.FirstNameOnly => HellionStrings.NameDisplay_NameForm_FirstNameOnly, - NameFormMode.Initials => HellionStrings.NameDisplay_NameForm_Initials, - _ => mode.ToString(), - }; + public static string Name(this NameFormMode mode) => + mode switch + { + NameFormMode.Full => HellionStrings.NameDisplay_NameForm_Full, + NameFormMode.FirstNameOnly => HellionStrings.NameDisplay_NameForm_FirstNameOnly, + NameFormMode.Initials => HellionStrings.NameDisplay_NameForm_Initials, + _ => mode.ToString(), + }; } diff --git a/HellionChat/Ui/ChatInputBar.cs b/HellionChat/Ui/ChatInputBar.cs index 079c0ec..3359f81 100644 --- a/HellionChat/Ui/ChatInputBar.cs +++ b/HellionChat/Ui/ChatInputBar.cs @@ -90,20 +90,27 @@ public sealed class ChatInputBar // UI-11: disclosure warning, visible only while an armed buffer is held // unchanged. Editing the buffer clears the condition automatically. - if (Plugin.Config.NotifyPluginDisclosure + if ( + Plugin.Config.NotifyPluginDisclosure && _disclosureArmedBuffer is not null - && _state.Buffer == _disclosureArmedBuffer) + && _state.Buffer == _disclosureArmedBuffer + ) { - ImGui.TextColored(ImGuiColors.DalamudYellow, HellionStrings.ChatInput_PluginDisclosure_Warning); + ImGui.TextColored( + ImGuiColors.DalamudYellow, + HellionStrings.ChatInput_PluginDisclosure_Warning + ); } } // TEST-MIRROR: ../_Helpers/CompactInputSubmitter.cs private void SubmitCompact(Tab tab) { - if (Plugin.Config.NotifyPluginDisclosure + if ( + Plugin.Config.NotifyPluginDisclosure && _state.Buffer != _disclosureArmedBuffer - && PluginDisclosureScanner.ContainsPrivateUseGlyph(_state.Buffer)) + && PluginDisclosureScanner.ContainsPrivateUseGlyph(_state.Buffer) + ) { // First send attempt on this exact buffer: arm and hold. The buffer // is kept, the warning renders, the user can press Enter again. diff --git a/HellionChat/Ui/ChatLogWindow.cs b/HellionChat/Ui/ChatLogWindow.cs index c2ac93c..6cc5e5a 100644 --- a/HellionChat/Ui/ChatLogWindow.cs +++ b/HellionChat/Ui/ChatLogWindow.cs @@ -5,10 +5,10 @@ using System.Runtime.InteropServices; using System.Text; using Dalamud.Bindings.ImGui; using Dalamud.Game.Addon.Lifecycle; -using Dalamud.Interface.Colors; using Dalamud.Game.Text.SeStringHandling; using Dalamud.Game.Text.SeStringHandling.Payloads; using Dalamud.Interface; +using Dalamud.Interface.Colors; using Dalamud.Interface.Style; using Dalamud.Interface.Utility; using Dalamud.Interface.Utility.Raii; @@ -721,9 +721,7 @@ public sealed class ChatLogWindow : Window // Window.IsFocused holds last frame's RootAndChildWindows focus, set // by Dalamud's WindowHost after Begin(). One-frame latency is // accepted. - BgAlpha = IsFocused - ? Plugin.Config.WindowOpacity - : Plugin.Config.WindowOpacityInactive; + BgAlpha = IsFocused ? Plugin.Config.WindowOpacity : Plugin.Config.WindowOpacityInactive; } LastViewport = ImGui.GetWindowViewport().Handle; @@ -1101,9 +1099,11 @@ public sealed class ChatLogWindow : Window if (ImGui.IsKeyDown(ImGuiKey.Enter) || ImGui.IsKeyDown(ImGuiKey.KeypadEnter)) { - if (Plugin.Config.NotifyPluginDisclosure + if ( + Plugin.Config.NotifyPluginDisclosure && Chat != _disclosureArmedBufferMain - && PluginDisclosureScanner.ContainsPrivateUseGlyph(Chat)) + && PluginDisclosureScanner.ContainsPrivateUseGlyph(Chat) + ) { // First send attempt on this exact buffer: arm and hold. // The warning renders below the input. @@ -1127,11 +1127,16 @@ public sealed class ChatLogWindow : Window // UI-11: disclosure warning for the main-window input, mirrors the // ChatInputBar path. Visible only while the armed buffer is held // unchanged; editing the buffer clears the condition. - if (Plugin.Config.NotifyPluginDisclosure + if ( + Plugin.Config.NotifyPluginDisclosure && _disclosureArmedBufferMain is not null - && Chat == _disclosureArmedBufferMain) + && Chat == _disclosureArmedBufferMain + ) { - ImGui.TextColored(ImGuiColors.DalamudYellow, HellionStrings.ChatInput_PluginDisclosure_Warning); + ImGui.TextColored( + ImGuiColors.DalamudYellow, + HellionStrings.ChatInput_PluginDisclosure_Warning + ); } // Process keybinds that have modifiers while the chat is focused. diff --git a/HellionChat/Ui/SettingsTabs/Appearance.cs b/HellionChat/Ui/SettingsTabs/Appearance.cs index 6dc985b..aa3044c 100644 --- a/HellionChat/Ui/SettingsTabs/Appearance.cs +++ b/HellionChat/Ui/SettingsTabs/Appearance.cs @@ -21,8 +21,7 @@ internal sealed class Appearance : ISettingsTab private string? _applyDismissedFor; - public string Name => - HellionStrings.Settings_Tab_Appearance + "###tabs-appearance"; + public string Name => HellionStrings.Settings_Tab_Appearance + "###tabs-appearance"; internal Appearance(Plugin plugin, Configuration mutable, ILogger logger) { @@ -50,7 +49,8 @@ internal sealed class Appearance : ISettingsTab private void DrawThemeSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Theme); if (!tree.Success) return; @@ -248,7 +248,8 @@ internal sealed class Appearance : ISettingsTab private void DrawFontsSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Fonts); if (!tree.Success) return; @@ -407,7 +408,8 @@ internal sealed class Appearance : ISettingsTab private void DrawColoursSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Colours); if (!tree.Success) return; @@ -535,7 +537,8 @@ internal sealed class Appearance : ISettingsTab private void DrawWindowStyleSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_WindowStyle); if (!tree.Success) return; @@ -616,7 +619,9 @@ internal sealed class Appearance : ISettingsTab { Mutable.WindowOpacityInactive = inactiveOpacityPercent / 100f; } - ImGuiUtil.HelpMarker(HellionStrings.Settings_ThemeAndLayout_WindowOpacityInactive_Description); + ImGuiUtil.HelpMarker( + HellionStrings.Settings_ThemeAndLayout_WindowOpacityInactive_Description + ); } } @@ -624,7 +629,8 @@ internal sealed class Appearance : ISettingsTab private void DrawTimestampSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Timestamps); if (!tree.Success) return; @@ -667,7 +673,8 @@ internal sealed class Appearance : ISettingsTab private void DrawAnimationsSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Animations); if (!tree.Success) return; diff --git a/HellionChat/Ui/SettingsTabs/Chat.cs b/HellionChat/Ui/SettingsTabs/Chat.cs index 8653d6a..0561af3 100644 --- a/HellionChat/Ui/SettingsTabs/Chat.cs +++ b/HellionChat/Ui/SettingsTabs/Chat.cs @@ -57,7 +57,8 @@ internal sealed class Chat : ISettingsTab private void DrawMessagesSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Messages); if (!tree.Success) return; @@ -135,7 +136,8 @@ internal sealed class Chat : ISettingsTab private void DrawInputPreviewSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_InputPreview); if (!tree.Success) return; @@ -185,7 +187,8 @@ internal sealed class Chat : ISettingsTab private void DrawAutoTellTabsSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_AutoTellTabs); if (!tree.Success) return; @@ -254,7 +257,8 @@ internal sealed class Chat : ISettingsTab private void DrawEmotesSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Emotes); if (!tree.Success) return; @@ -369,7 +373,8 @@ internal sealed class Chat : ISettingsTab private void DrawLinksTooltipsSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_LinksTooltips); if (!tree.Success) return; @@ -403,7 +408,8 @@ internal sealed class Chat : ISettingsTab private void DrawNoviceNetworkSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_NoviceNetwork); if (!tree.Success) return; diff --git a/HellionChat/Ui/SettingsTabs/DataAndPrivacy.cs b/HellionChat/Ui/SettingsTabs/DataAndPrivacy.cs index e96609b..0d2f390 100644 --- a/HellionChat/Ui/SettingsTabs/DataAndPrivacy.cs +++ b/HellionChat/Ui/SettingsTabs/DataAndPrivacy.cs @@ -152,22 +152,28 @@ internal sealed class DataAndPrivacy : ISettingsTab if (sectionJustEntered) ShowAdvanced = ImGui.GetIO().KeyShift; - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); DrawPrivacyFilterSection(); ImGui.Spacing(); - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); DrawStorageSection(); ImGui.Spacing(); - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); DrawRetentionSection(); ImGui.Spacing(); - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); DrawCleanupSection(); ImGui.Spacing(); - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); DrawExportSection(); ImGui.Spacing(); - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); DrawDatabaseSection(); } @@ -960,7 +966,9 @@ internal sealed class DataAndPrivacy : ISettingsTab return; ImGui.Spacing(); - using var advTree = ImRaii.TreeNode(HellionStrings.Settings_DataManagement_Advanced_Heading); + using var advTree = ImRaii.TreeNode( + HellionStrings.Settings_DataManagement_Advanced_Heading + ); if (!advTree.Success) return; diff --git a/HellionChat/Ui/SettingsTabs/General.cs b/HellionChat/Ui/SettingsTabs/General.cs index 1e48b42..927be98 100644 --- a/HellionChat/Ui/SettingsTabs/General.cs +++ b/HellionChat/Ui/SettingsTabs/General.cs @@ -33,7 +33,8 @@ internal sealed class General : ISettingsTab private void DrawInputSection(bool sectionJustEntered) { // Collapse every time the tab is freshly entered so state doesn't bleed across sessions. - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Input); if (!tree.Success) return; @@ -86,7 +87,8 @@ internal sealed class General : ISettingsTab private void DrawSoundSection(bool sectionJustEntered) { // Collapse every time the tab is freshly entered so state doesn't bleed across sessions. - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Sound); if (!tree.Success) return; @@ -113,14 +115,19 @@ internal sealed class General : ISettingsTab Mutable.CustomSoundVolume = customSoundVolumePercent / 100f; } // Show the functional description and the per-tab navigation hint together. - ImGuiUtil.HelpMarker(HellionStrings.Settings_General_CustomSoundVolume_Description + "\n\n" + HellionStrings.Settings_Section_Sound_TabsHint); + ImGuiUtil.HelpMarker( + HellionStrings.Settings_General_CustomSoundVolume_Description + + "\n\n" + + HellionStrings.Settings_Section_Sound_TabsHint + ); } } private void DrawLanguageSection(bool sectionJustEntered) { // Collapse every time the tab is freshly entered so state doesn't bleed across sessions. - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Language); if (!tree.Success) return; @@ -191,7 +198,8 @@ internal sealed class General : ISettingsTab private void DrawPerformanceSection(bool sectionJustEntered) { // Collapse every time the tab is freshly entered so state doesn't bleed across sessions. - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Performance); if (!tree.Success) return; diff --git a/HellionChat/Ui/SettingsTabs/Tabs.cs b/HellionChat/Ui/SettingsTabs/Tabs.cs index 4bd008d..15f2d8c 100755 --- a/HellionChat/Ui/SettingsTabs/Tabs.cs +++ b/HellionChat/Ui/SettingsTabs/Tabs.cs @@ -177,8 +177,13 @@ internal sealed class Tabs : ISettingsTab // ── Sub-section: Channels ───────────────────────────────────────── // First because it answers "what does this tab collect?" — most important. - if (sectionJustEntered) ImGui.SetNextItemOpen(false); - using (var secChannels = ImRaii.TreeNode(HellionStrings.Settings_Section_Tab_Channels + $"##sec-channels-{i}")) + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); + using ( + var secChannels = ImRaii.TreeNode( + HellionStrings.Settings_Section_Tab_Channels + $"##sec-channels-{i}" + ) + ) { if (secChannels.Success) { @@ -195,8 +200,13 @@ internal sealed class Tabs : ISettingsTab ImGui.Spacing(); // ── Sub-section: Display ────────────────────────────────────────── - if (sectionJustEntered) ImGui.SetNextItemOpen(false); - using (var secDisplay = ImRaii.TreeNode(HellionStrings.Settings_Section_Tab_Display + $"##sec-display-{i}")) + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); + using ( + var secDisplay = ImRaii.TreeNode( + HellionStrings.Settings_Section_Tab_Display + $"##sec-display-{i}" + ) + ) { if (secDisplay.Success) { @@ -226,15 +236,23 @@ internal sealed class Tabs : ISettingsTab // Only relevant when the global hide-when-inactive is on. if (Mutable.HideWhenInactive) - ImGui.Checkbox(Language.Options_Tabs_InactivityBehaviour, ref tab.UnhideOnActivity); + ImGui.Checkbox( + Language.Options_Tabs_InactivityBehaviour, + ref tab.UnhideOnActivity + ); } } ImGui.Spacing(); // ── Sub-section: Notification ───────────────────────────────────── - if (sectionJustEntered) ImGui.SetNextItemOpen(false); - using (var secNotif = ImRaii.TreeNode(HellionStrings.Settings_Section_Tab_Notification + $"##sec-notif-{i}")) + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); + using ( + var secNotif = ImRaii.TreeNode( + HellionStrings.Settings_Section_Tab_Notification + $"##sec-notif-{i}" + ) + ) { if (secNotif.Success) { @@ -308,7 +326,10 @@ internal sealed class Tabs : ISettingsTab } else { - Plugin.CustomAudioPlayer.Play((int)previewId - 16, Mutable.CustomSoundVolume); + Plugin.CustomAudioPlayer.Play( + (int)previewId - 16, + Mutable.CustomSoundVolume + ); } } } @@ -340,15 +361,24 @@ internal sealed class Tabs : ISettingsTab Mutable.CustomSoundVolume = customSoundVolumePercent / 100f; } // Applies globally — same value as in General → Sound. - ImGuiUtil.HelpMarker(HellionStrings.Settings_General_CustomSoundVolume_Description + "\n\n" + HellionStrings.Settings_Section_Tab_Volume_AllTabsHint); + ImGuiUtil.HelpMarker( + HellionStrings.Settings_General_CustomSoundVolume_Description + + "\n\n" + + HellionStrings.Settings_Section_Tab_Volume_AllTabsHint + ); } } ImGui.Spacing(); // ── Sub-section: Input ──────────────────────────────────────────── - if (sectionJustEntered) ImGui.SetNextItemOpen(false); - using (var secInput = ImRaii.TreeNode(HellionStrings.Settings_Section_Tab_Input + $"##sec-input-{i}")) + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); + using ( + var secInput = ImRaii.TreeNode( + HellionStrings.Settings_Section_Tab_Input + $"##sec-input-{i}" + ) + ) { if (secInput.Success) { @@ -358,7 +388,8 @@ internal sealed class Tabs : ISettingsTab if (!tab.InputDisabled) { var input = - tab.Channel?.ToChatType().Name() ?? Language.Options_Tabs_NoInputChannel; + tab.Channel?.ToChatType().Name() + ?? Language.Options_Tabs_NoInputChannel; using ( var combo = ImGuiUtil.BeginComboVertical( Language.Options_Tabs_InputChannel, @@ -390,7 +421,10 @@ internal sealed class Tabs : ISettingsTab var player = Plugin.ObjectTable.LocalPlayer; if (tab.Channel == InputChannel.Tell && player != null) { - ImGui.Checkbox(Language.Options_Tabs_SenderMessages, ref tab.AllSenderMessages); + ImGui.Checkbox( + Language.Options_Tabs_SenderMessages, + ref tab.AllSenderMessages + ); ImGuiUtil.HelpText(Language.Options_Help_SenderMessages); var worlds = Sheets @@ -444,7 +478,9 @@ internal sealed class Tabs : ISettingsTab ) { selectedWorld = idx; - tab.TellTarget.World = worlds[selectedWorld].RowId; + tab.TellTarget.World = worlds[ + selectedWorld + ].RowId; } if (lastDc == world.DataCenter.RowId) @@ -474,8 +510,13 @@ internal sealed class Tabs : ISettingsTab ImGui.Spacing(); // ── Sub-section: Pop-out window ─────────────────────────────────── - if (sectionJustEntered) ImGui.SetNextItemOpen(false); - using (var secPopOut = ImRaii.TreeNode(HellionStrings.Settings_Section_Tab_PopOut + $"##sec-popout-{i}")) + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); + using ( + var secPopOut = ImRaii.TreeNode( + HellionStrings.Settings_Section_Tab_PopOut + $"##sec-popout-{i}" + ) + ) { if (secPopOut.Success) { @@ -500,7 +541,10 @@ internal sealed class Tabs : ISettingsTab ImGuiSliderFlags.AlwaysClamp ); - ImGui.Checkbox(Language.Options_Tabs_IndependentHide, ref tab.IndependentHide); + ImGui.Checkbox( + Language.Options_Tabs_IndependentHide, + ref tab.IndependentHide + ); if (tab.IndependentHide) { using var __ = ImRaii.PushIndent(10.0f); diff --git a/HellionChat/Ui/SettingsTabs/Window.cs b/HellionChat/Ui/SettingsTabs/Window.cs index 58056d3..38e2e28 100644 --- a/HellionChat/Ui/SettingsTabs/Window.cs +++ b/HellionChat/Ui/SettingsTabs/Window.cs @@ -29,7 +29,8 @@ internal sealed class Window : ISettingsTab private void DrawHideSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Hide); if (!tree.Success) { @@ -83,7 +84,8 @@ internal sealed class Window : ISettingsTab private void DrawInactivityHideSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_InactivityHide); if (!tree.Success) { @@ -166,7 +168,8 @@ internal sealed class Window : ISettingsTab private void DrawFrameSection(bool sectionJustEntered) { - if (sectionJustEntered) ImGui.SetNextItemOpen(false); + if (sectionJustEntered) + ImGui.SetNextItemOpen(false); using var tree = ImRaii.TreeNode(HellionStrings.Settings_Section_Frame); if (!tree.Success) { @@ -192,5 +195,4 @@ internal sealed class Window : ISettingsTab ImGuiUtil.HelpMarker(HellionStrings.Settings_Window_ResetPosition_Description); } } - } diff --git a/HellionChat/Util/SenderNameDisplay.cs b/HellionChat/Util/SenderNameDisplay.cs index 9446076..3ee9c89 100644 --- a/HellionChat/Util/SenderNameDisplay.cs +++ b/HellionChat/Util/SenderNameDisplay.cs @@ -66,7 +66,12 @@ internal static class SenderNameDisplay var isHomeWorld = payload.World.RowId == Plugin.PlayerState.HomeWorld.RowId; var formatted = SenderNameFormatter.Format( - payload.PlayerName, worldName, isHomeWorld, formMode, suffixMode); + payload.PlayerName, + worldName, + isHomeWorld, + formMode, + suffixMode + ); // Render-only copy: replace the whole sender span (name text, world // text, and any cross-world icon) with one formatted chunk that keeps diff --git a/HellionChat/_Helpers/SenderNameFormatter.cs b/HellionChat/_Helpers/SenderNameFormatter.cs index a17d3dc..a47b11b 100644 --- a/HellionChat/_Helpers/SenderNameFormatter.cs +++ b/HellionChat/_Helpers/SenderNameFormatter.cs @@ -14,7 +14,8 @@ public static class SenderNameFormatter string worldName, bool isHomeWorld, NameFormMode formMode, - WorldSuffixMode suffixMode) + WorldSuffixMode suffixMode + ) { var name = FormatName(fullName, formMode); @@ -26,9 +27,7 @@ public static class SenderNameFormatter _ => !isHomeWorld, }; - return showWorld && !string.IsNullOrEmpty(worldName) - ? $"{name}@{worldName}" - : name; + return showWorld && !string.IsNullOrEmpty(worldName) ? $"{name}@{worldName}" : name; } private static string FormatName(string fullName, NameFormMode mode) diff --git a/docs/ROADMAP.md b/docs/ROADMAP.md index 37c0c9e..09d3844 100644 --- a/docs/ROADMAP.md +++ b/docs/ROADMAP.md @@ -29,6 +29,7 @@ Channels, Data & Privacy, About). Each tab uses collapsible sections grouped by type; sections start collapsed on every tab-open. Delivered from the originally-planned v1.5.5b bundle: + - **UI-7** — Sender-name display options: world-suffix mode (Never / Other worlds only / Always) and name-format mode (Full name / First name only / Initials). Lives in Chat → Messages. - **UI-11** — Pre-send warning when a message contains plugin-only symbols. Toggle in