Modifying Themes

This is not the solution. As you have several background color for a widget. This depends on the Gtk.StateFlags (Gtk.StateFlags)

I recently had to use this when adding colors to a popup menu ( See New way to add tags in GraphView by SNoiraud · Pull Request #519 · gramps-project/addons-source · GitHub )

Depending on the background brightness, I set the text color to either white, either black.

1 Like

The Themes is a recent addon. Before that, to use anything other than the light or dark Adwaita was cumbersome. With the addon, you can download and use virtually any theme out there many with the dark theme option. But as not everyone installs all addons, the dark option on Colors is still needed.

1 Like

Seeing as the Gdk call used a RGBa color space, I tried using a 25% opaque alpha channel, bumping the first level down from a color highlight to a brightness change highlight and re-ordered the colors according to how they are arranged on a color wheel. (Which add context… following the color wheel ordering implies a progression.)

The alpha channel works well for both Light & dark themes. And it seems a bit more subtle to me.

image
image

FilterParams.py Lines 138 and (updated) 139

        self.categories_translated = [_(cat) for cat in self.categories]
        self.colors = [
             Gdk.RGBA(0.75,0.75,0.75, 0.250),
             Gdk.RGBA(0.75,0.75,0.99, 0.250),
             Gdk.RGBA(0.75,0.99,0.99, 0.250),
             Gdk.RGBA(0.75,0.99,0.75, 0.250),
             Gdk.RGBA(0.99,0.99,0.75, 0.250),
             Gdk.RGBA(0.99,0.75,0.75, 0.250),
             Gdk.RGBA(0.99,0.75,0.99, 0.250),
        ]

FilterParams tool addon Version: 1.1.5 in Adwaita theme on Fedora

The Gtk4 theme is reportedly a very flat theme that seems to annoy some people. To defuse probable user complaints when we switchover, perhaps Gramps 5.3 should roll the Themes add-on into the Core and, to highlight the new feature, include a highly wildly differing theme to previous version… but be bundled with (or have an add-on) of the previous theme too. So when Gtk changes, people will be comfortable with switching things up.

More importantly, perhaps the location for themes could be consolidated in the currently empty CSS folder Gramps User Directory space. It could encourage CSS artists.

Adwaita from Fedora :

Win32 from Fedora :

Mint-X-Blue (dark) from Fedora:

Mint-X-Blue from Fedora:

Mint-Y-Blue from Fedora: