Hi,
My original goal was to activate fcitx5 input methods in various Chromium-based apps. The search lands on passing the flag --gtk-version=4
, which works on natively installed applications. However, I recently migrated my browser (Brave, in particular) from AUR to Flatpak, and I couldn’t get the same result as the natively installed version.
With ozone-platform-hint
is already set to ‘auto’ in ‘brave://flags’ section, and
‘brave --gtk-version=4’ would work when natively installed (with AUR),
My first attempt is quite naive:
$ flatpak run com.brave.Browser --gtk-version=4
However, I still cannot activate fcitx5. A quick check unveils the actual processes are still referencing GTK3:
#!/bin/bash
for pid in $(pidof brave); do
grep -i gtk /proc/"$pid"/maps
done
797853600000-797853690000 r--p 00000000 00:1e 19369435 /usr/lib/x86_64-linux-gnu/libgtk-3.so.0.2409.32
797853690000-797853a40000 r-xp 00090000 00:1e 19369435 /usr/lib/x86_64-linux-gnu/libgtk-3.so.0.2409.32
797853a40000-797853dbc000 r--p 00440000 00:1e 19369435 /usr/lib/x86_64-linux-gnu/libgtk-3.so.0.2409.32
797853dbc000-797853dcc000 r--p 007bb000 00:1e 19369435 /usr/lib/x86_64-linux-gnu/libgtk-3.so.0.2409.32
797853dcc000-797853dce000 rw-p 007cb000 00:1e 19369435 /usr/lib/x86_64-linux-gnu/libgtk-3.so.0.2409.32
79785ccca000-79785cccb000 r--p 00000000 00:1e 6354350 /usr/share/locale/en/LC_MESSAGES/gtk30-properties.mo
79785cccb000-79785cccc000 r--p 00000000 00:1e 211718 /usr/share/locale/en/LC_MESSAGES/gtk30.mo
The environment variables set for com.brave.Browser
are:
XMODIFIERS=@im=fcitx
QT_IM_MODULE=fcitx
GTK_IM_MODULE=fcitx
DCONF_USER_CONFIG_DIR=.config/dconf
XCURSOR_PATH=/run/host/user-share/icons:/run/host/share/icons
GTK_PATH=/app/lib/gtkmodules
GIO_EXTRA_MODULES=/app/lib/gio/modules
GSETTINGS_BACKEND=dconf
Is there a way to tell those apps to use GTK4?
Thanks