Repository navigation
Give the selected tab its own fill on the tab bar [patch] - #163
Merged
Merged
Conversation
ImGui fills a dock node's tab bar with TitleBgActive or TitleBg, and TabSelected and TabDimmedSelected resolved to those same colors, so the selected tab had no fill of its own while unselected tabs stood out. The selected tabs now sit one priority step above their bar, and TabHovered moves up a step so hovering still reads differently from being selected. Fixes #161 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017vfJW5kPDQWGc94xTwvzds
…matches-title-bar # Conflicts: # ThemeProvider.Test/ImGuiPaletteMapperTests.cs
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Fixes #161
Problem
ImGui fills a dock node's tab bar with
TitleBgActivewhen it is focused andTitleBgwhen it isn't, and draws the selected tab withTabSelected/TabDimmedSelected. The mapper gave each selected-tab slot the same request as the bar under it (Primary / VeryLowandNeutral / Low). So in all 38 themes the selected tab had no fill of its own, and only the unselected tabs stood out.Change
TabSelectedPrimary / VeryLow(=TitleBgActive)Primary / LowTabHoveredPrimary / LowPrimary / MediumLowTabDimmedSelectedNeutral / Low(=TitleBg)Neutral / MediumLowIn both focus states the selected tab now sits one priority step above the bar, and unselected tabs keep their existing colours.
TabHoveredmoves up one step so hovering a tab still looks different from selecting it. The new fills use the same steps asButtonHovered/ButtonActiveandFrameBgHovered, which already carry body text.New test
MapTheme_SelectedTabsDifferFromTheirTabBarchecksTabSelected != TitleBgActive,TabDimmedSelected != TitleBgandTabHovered != TabSelectedfor every registered theme.This edits the same file as #162 (the fix for #160), but in different hunks.
Verification
Catppuccin Latte: TabSelected is drawn in the TitleBgActive color).ThemeProvider.Testsuite passes: 90/90.Generated by Claude Code