You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
First off — thanks for nchat, it themes beautifully into terminal-palette setups since empty/named colors inherit the terminal.
Problem
The currently selected item (chat list row, list dialog item, selected message) can only be styled via the *_attr_selected attributes (reverse/bold/italic/underline). There is no way to give the selection an explicit color. For theming pipelines that derive all UI colors from a wallpaper palette (pywal and similar), reverse video is the one element that can't be made palette-consistent — it produces a bright foreground-colored block regardless of theme.
Proposal
Add optional selected-color parameters, empty by default (= exactly today's behavior, zero migration needed since Config::Load merges defaults):
When set, the selected item uses this color pair in addition to its _attr_selected attribute. Precedence for the highlighted item: selected color over unread (list), shaded (dialog) and sent/recv/usercolor (history) — documented in README.
builds warning-clean (-DHAS_TELEGRAM=OFF -DHAS_WHATSAPP=OFF -DHAS_DUMMY=ON), formatted with ./make.sh src
verified with the dummy protocol: defaults render byte-identical to master; with e.g. list_color_selected_bg=red the selected row emits the expected SGR
existing theme files keep working unchanged (missing keys fall back to defaults); happy to also update the 14 theme dumps if you prefer them explicit
Per CONTRIBUTING.md I'm opening this issue first — happy to submit the PR if you're open to the feature, and to adjust naming/scope to your preference.
First off — thanks for nchat, it themes beautifully into terminal-palette setups since empty/named colors inherit the terminal.
Problem
The currently selected item (chat list row, list dialog item, selected message) can only be styled via the
*_attr_selectedattributes (reverse/bold/italic/underline). There is no way to give the selection an explicit color. For theming pipelines that derive all UI colors from a wallpaper palette (pywal and similar), reverse video is the one element that can't be made palette-consistent — it produces a bright foreground-colored block regardless of theme.Proposal
Add optional selected-color parameters, empty by default (= exactly today's behavior, zero migration needed since
Config::Loadmerges defaults):When set, the selected item uses this color pair in addition to its
_attr_selectedattribute. Precedence for the highlighted item: selected color over unread (list), shaded (dialog) and sent/recv/usercolor (history) — documented in README.Working patch
I have a tested implementation ready on my fork (~79 lines, one commit):
https://github.com/erdivartanovich/nchat/tree/feature/selected-colors
Design notes:
UiColorConfig::HasColor(param)gates every swap, so unset keys never allocate a pair and never touch the existing render pathswattroff/wattronto avoidCOLOR_PAIRbit OR-ing (the gotcha noted in feat: add group chat colors (green) in sidebar with wattrset fix #513)-DHAS_TELEGRAM=OFF -DHAS_WHATSAPP=OFF -DHAS_DUMMY=ON), formatted with./make.sh srclist_color_selected_bg=redthe selected row emits the expected SGRPer CONTRIBUTING.md I'm opening this issue first — happy to submit the PR if you're open to the feature, and to adjust naming/scope to your preference.