mijorus / smile

An emoji picker for linux, with custom tags support and localization. I'll also put some random emojis here πŸ¦πŸΎπŸ¦”πŸ¦‡
https://mijorus.it/projects/smile
GNU General Public License v3.0
237 stars 13 forks source link

Won't use dark theme #17

Closed ttytm closed 1 year ago

ttytm commented 2 years ago

I'm dying without dark theme. Can't make it work :/

currently on pop os

ttytm commented 2 years ago

Okay building from source instead of installing from flathub saved me ❀

But only when running without installation. When installing it, no more dark theme is used 😒. But not a big deal to run it via script or alias than πŸ‘οΈ.

In any case thanks for building the app m8!

Edit: Oh wow I'm confused sometimes it works, sometimes it doesn't when using the same command / shortcut. A random result which theme is used.

mijorus commented 2 years ago

The app does not force any theme, should follow the GTK theme set on flatpak.

Btw I am on PopOS too, but never encountered this problem. Are you using extensions / scripts to change your desktop theme from light to dark?

proninyaroslav commented 2 years ago

Flatpak & freedesktop have added a dbus item for checking dark mode preference.

Spec:

Portal API Reference

Portal interfaces are available to sandboxed applications with the default filtered session bus access of Flatpak. Unless otherwise specified, they appear under the bus name org.freedesktop.portal.Desktop and the object path /org/freedesktop/portal/desktop on the session bus.

This interface provides read-only access to a small number of host settings required for toolkits similar to XSettings. It is not for general purpose settings.

Currently the interface provides the following keys:

org.freedesktop.appearance color-scheme u

Indicates the system's preferred color scheme. Supported values are:
0: No preference
1: Prefer dark appearance
2: Prefer light appearance

Unknown values should be treated as 0 (no preference).

Can be checked from terminal with:

dbus-send --print-reply --dest=org.freedesktop.portal.Desktop /org/freedesktop/portal/desktop org.freedesktop.portal.Settings.Read string:'org.freedesktop.appearance' string:'color-scheme'
VarLad commented 2 years ago

@mijorus I can report the same problem on Fedora 36 GNOME 42

ttytm commented 2 years ago

What I can add after opening this issue is that after some experimentation it pretty much worked without any more issues since then. Unfortunately I don't remember exactly what I did, so I'm coming here feeling a bit guilty of not being able to provide a proper reproduction out of the top of my head. It's definitely built from source and I think it was working on integrating GTK themes into flatpak that solved it. There are many threads on this topic.

In the end the good news is that it's definitely possible on the user side.

mijorus commented 2 years ago

Sorry guys but I've been busy lately; I'm looking into this issue now