fix(auto-tell-tabs): make greeted toggle button more compact and transparent
This commit is contained in:
@@ -1334,11 +1334,16 @@ public sealed class ChatLogWindow : Window
|
|||||||
// Greeted toggle sits left of the selectable so the
|
// Greeted toggle sits left of the selectable so the
|
||||||
// click areas stay separate. The icon also doubles
|
// click areas stay separate. The icon also doubles
|
||||||
// as the visual "I'm done with this person" cue.
|
// as the visual "I'm done with this person" cue.
|
||||||
|
// Compact frame padding keeps the icon dezent next
|
||||||
|
// to the tab name instead of a chunky button block.
|
||||||
var greetedIcon = tab.IsGreeted ? FontAwesomeIcon.CheckCircle : FontAwesomeIcon.Check;
|
var greetedIcon = tab.IsGreeted ? FontAwesomeIcon.CheckCircle : FontAwesomeIcon.Check;
|
||||||
var greetedTooltip = tab.IsGreeted
|
var greetedTooltip = tab.IsGreeted
|
||||||
? HellionStrings.AutoTellTabs_GreetedTooltip
|
? HellionStrings.AutoTellTabs_GreetedTooltip
|
||||||
: HellionStrings.AutoTellTabs_UnGreetedTooltip;
|
: HellionStrings.AutoTellTabs_UnGreetedTooltip;
|
||||||
|
|
||||||
|
using (ImRaii.PushStyle(ImGuiStyleVar.FramePadding, new Vector2(2, 1)))
|
||||||
|
using (ImRaii.PushColor(ImGuiCol.Button, 0))
|
||||||
|
{
|
||||||
if (ImGuiUtil.IconButton(greetedIcon, $"greeted-{tabI}", greetedTooltip))
|
if (ImGuiUtil.IconButton(greetedIcon, $"greeted-{tabI}", greetedTooltip))
|
||||||
{
|
{
|
||||||
if (tab.IsGreeted)
|
if (tab.IsGreeted)
|
||||||
@@ -1350,6 +1355,7 @@ public sealed class ChatLogWindow : Window
|
|||||||
Plugin.AutoTellTabsService.MarkGreeted(tab);
|
Plugin.AutoTellTabsService.MarkGreeted(tab);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
ImGui.SameLine();
|
ImGui.SameLine();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user