Dolphin's selection color is stuck on stock Breeze blue outside a full Plasma session (unfixed upstream regression, see README) - dropped it for Thunar. Getting Thunar themed exposed a chain of GTK3-specific issues fixed along the way: !important is silently rejected by GTK3's CSS parser (not just deprioritized), the widget and icon themes resolve via completely different mechanisms under Hyprland (no XSETTINGS daemon), and Thunar's ExoIconView grid reads its selection color from a named @define-color instead of normal :selected matching. Folder icon colors are now generated to match the accent exactly (theme/icon_theme.py, no sudo) instead of snapping to a papirus-folders preset. Also adds the kde-colorscheme template (the missing piece KColorSchemeManager actually resolves ColorScheme= against) and new gtk_selection_color/gtk_selection_opacity palette keys with widget controls, following the existing bar/pill/popup color+opacity pattern. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Dujsk9jYfxUVLtb5B8eC94
74 lines
2.3 KiB
CSS
74 lines
2.3 KiB
CSS
/* Generated by theme/render.py from the active palette.
|
|
Edit the template at ~/.config/theme/templates/gtk3/gtk.css, not the output.
|
|
|
|
Blanket GTK3 override (applies to every GTK3 app: Thunar, Qalculate-gtk, etc.) - GSettings
|
|
(set in hyprland.lua's config.reloaded hook) picks the base Materia-dark theme, this then
|
|
forces the actual colors on top of it to match the palette.
|
|
|
|
No !important: GTK3's CSS parser doesn't support it at all (not "lower priority" -
|
|
it drops the whole declaration, "Junk at end of value" in GTK_DEBUG output). This file
|
|
is loaded at GTK_STYLE_PROVIDER_PRIORITY_USER, already above the theme's own CSS, so
|
|
plain declarations here win without it. */
|
|
|
|
* {
|
|
color: {foreground};
|
|
}
|
|
|
|
window, dialog, grid {
|
|
background-color: {background};
|
|
background-image: none;
|
|
}
|
|
|
|
entry, textview, textview text, text {
|
|
background-color: {background};
|
|
color: {accent};
|
|
border: 1px solid {accent};
|
|
border-radius: 6px;
|
|
box-shadow: none;
|
|
}
|
|
|
|
button {
|
|
background-color: {pill_color};
|
|
background-image: none;
|
|
border: 1px solid {color8};
|
|
border-radius: 6px;
|
|
box-shadow: none;
|
|
}
|
|
|
|
button:hover {
|
|
background-color: {color8};
|
|
border-color: {accent};
|
|
}
|
|
|
|
button label {
|
|
color: {foreground};
|
|
}
|
|
button:hover label {
|
|
color: {accent};
|
|
}
|
|
|
|
/* Thunar's grid is ExoIconView, an old custom widget that doesn't ask the style
|
|
context "what's my background for :selected" through normal CSS matching - it
|
|
looks up these named colors directly instead (gtk_style_context_lookup_color).
|
|
Redefining them is what actually recolors the selection there; .view:selected/
|
|
*:selected below do nothing for it, only for widgets that DO use normal matching. */
|
|
@define-color theme_selected_bg_color alpha({gtk_selection_color}, {gtk_selection_opacity});
|
|
@define-color theme_selected_fg_color {foreground};
|
|
@define-color theme_unfocused_selected_bg_color alpha({gtk_selection_color}, {gtk_selection_opacity});
|
|
@define-color theme_unfocused_selected_fg_color {foreground};
|
|
|
|
/* File-manager icon/list view (Thunar's grid, Materia's rounded selection pill) */
|
|
.view {
|
|
background-color: transparent;
|
|
color: {foreground};
|
|
}
|
|
|
|
.view:hover {
|
|
background-color: alpha({accent}, 0.18);
|
|
}
|
|
|
|
*:selected {
|
|
background-color: alpha({gtk_selection_color}, {gtk_selection_opacity});
|
|
color: {foreground};
|
|
}
|