mirror of
https://github.com/ZoiteChat/zoitechat.git
synced 2026-03-17 11:10:18 +00:00
Updated chanview_apply_theme() in src/fe-gtk/chanview.c to apply the palette colors unconditionally (for tree view chanview), instead of branching on raw dark-mode enum checks. This keys behavior off the already-resolved palette output, which matches how setup_apply_to_sess() / palette_apply_dark_mode() flows are intended to work.
Preserved font handling exactly as before (input_style->font_desc when available). Added inline rationale comment clarifying that AUTO/light should continue using palette-managed colors and should not revert to GTK theme defaults in a way that clears custom colors.
This commit is contained in:
@@ -127,15 +127,15 @@ chanview_apply_theme (chanview *cv)
|
|||||||
if (input_style)
|
if (input_style)
|
||||||
font = input_style->font_desc;
|
font = input_style->font_desc;
|
||||||
|
|
||||||
if (fe_dark_mode_is_enabled () || prefs.hex_gui_dark_mode == ZOITECHAT_DARK_MODE_LIGHT)
|
/*
|
||||||
{
|
* setup_apply_to_sess() and palette_apply_dark_mode() treat all dark-mode
|
||||||
gtkutil_apply_palette (w, &colors[COL_BG], &colors[COL_FG], font);
|
* preference modes as palette-driven: dark uses curated dark colors, while
|
||||||
}
|
* light/auto-light use the user's saved palette.
|
||||||
else
|
*
|
||||||
{
|
* Keep chanview aligned with that resolved behavior so AUTO doesn't
|
||||||
/* Keep list font in sync while reverting colors to theme defaults. */
|
* accidentally revert to theme defaults and clear custom colors.
|
||||||
gtkutil_apply_palette (w, NULL, NULL, font);
|
*/
|
||||||
}
|
gtkutil_apply_palette (w, &colors[COL_BG], &colors[COL_FG], font);
|
||||||
}
|
}
|
||||||
|
|
||||||
static char *
|
static char *
|
||||||
|
|||||||
Reference in New Issue
Block a user