How to launch Geary mail app in dark mode

Lately I’ve been working on getting all of my commonly used applications to respect Crimson’s dark mode setting.

Geary doesn’t yet honor PureOS’ dark mode toggle but there’s a workaround when launching the app from the terminal. You could also make a custom Geary dark mode .desktop shortcut file with this.

flatpak run --env=GTK_THEME=Adwaita-dark org.gnome.Geary

2 Likes

You can use this single command for Crimson:

gsettings set org.gnome.desktop.interface gtk-theme "Adwaita-dark"
3 Likes

Is that functionally any different than the Dark Mode option on the Crimson Gnome Power menu?

Screenshot from 2024-06-24 06-19-54

1 Like

Yes, it is entirely separate.

How exactly so? I guess I’m not understanding why a person would configure gsettings when the Dark Mode button is available. Is the idea that dark mode can be enabled globally for certain problem apps such as Geary that don’t respect the Dark Mode button?

2 Likes

The Dark Mode button does not affect every application, so the command I provided handles the rest.

You are right. The purpose of that control is to toggle the color scheme globally. However, GTK3 applications are expected to be rewritten with GTK4 and libadwaita for that to work. Geary is still GTK3 and it does not support the new GNOME dark color scheme yet, so a workaround is to change the GTK3 theme to force a different look on Geary. Awaita Dark GTK3 theme looks similar but not the same as the dark color scheme of libadwaita. By the way, libadwaita is a fork of libhandy being developed by the same team.

2 Likes

Would this work on Byzantium?

I could try, but how do I unset it afterwords?

1 Like

Yes, you can revert to the default theme using this command:

gsettings set org.gnome.desktop.interface gtk-theme "Adwaita"
1 Like

Thanks. Most apps dark now except Web, Fractal, Pipeline, Podcasts, Flare, etc.

1 Like

You probably already did this already, but Byzantium requires another command for the rest of the applications to use dark mode:

gsettings set org.gnome.desktop.interface color-scheme "prefer-dark"

prefer-dark is the equivalent of the Dark Mode toggle in Crimson.

2 Likes

I should probably add that PureOS provided Geary 43 respects Dark Made while Flathub flatpak provided Geary 46 does not. So what initially inspired this thread turned out to be a regression of Geary 46, which also broke some single and combination keyboard shortcuts.

Been happy using Geary 43 since.

1 Like

From FlatSeal, try:
image

2 Likes

are you running Geary v46 from Flathub?

Flatseal saved me from a maddening problem with Gnome Web (epiphany) that wouldn’t render any pages, handy utility.

1 Like

I think so… PureOS Store is not playing nice right now and it’s too late to look up the flatpak cli now.

1 Like