[fix] use cosmic xdg
This commit is contained in:
parent
469e010103
commit
f9d5ec2a63
3 changed files with 20 additions and 1 deletions
|
|
@ -49,7 +49,7 @@ in {
|
|||
config = {
|
||||
common = {
|
||||
default = [ "kde" ];
|
||||
"org.freedesktop.impl.portal.FileChooser" = [ "kde" ];
|
||||
"org.freedesktop.impl.portal.FileChooser" = [ "cosmic" ];
|
||||
"org.freedesktop.impl.portal.Access" = [ "kde" ];
|
||||
"org.freedesktop.impl.portal.OpenUri" = [ "kde" ];
|
||||
"org.freedesktop.impl.portal.Desktop" = [ "kde" ];
|
||||
|
|
|
|||
|
|
@ -63,11 +63,29 @@ export MOZ_ENABLE_WAYLAND=1
|
|||
export QT_QPA_PLATFORM="wayland;xcb"
|
||||
export QT_AUTO_SCREEN_SCALE_FACTOR=1
|
||||
export QT_ENABLE_HIGHDPI_SCALING=1
|
||||
export DCONF_PROFILE=cosmic
|
||||
|
||||
# Set the QT platform theme to CuteCosmic. Fallback to qt6ct if CuteCosmic is not installed.
|
||||
if [ -z "$QT_QPA_PLATFORMTHEME" ]; then
|
||||
export QT_QPA_PLATFORMTHEME=cosmic
|
||||
for QT_PLUGIN_PATH in /usr/lib{*,/*}/qt6/plugins; do
|
||||
if [ -f "''${QT_PLUGIN_PATH}/platformthemes/libcutecosmictheme.so" ]; then
|
||||
# CuteCosmic found, no need for a fallback.
|
||||
export QT_QPA_PLATFORMTHEME=cosmic
|
||||
break
|
||||
elif [ -f "''${QT_PLUGIN_PATH}/platformthemes/libqt6ct.so" ] || [ -f "''${QT_PLUGIN_PATH}/platformthemes/libqt5ct.so" ]; then
|
||||
# Fallback to qt6ct, but keep looking for CuteCosmic.
|
||||
# Note that "qt5ct" is compatible with both qt5ct and qt6ct.
|
||||
export QT_QPA_PLATFORMTHEME=qt5ct
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
if command -v systemctl >/dev/null; then
|
||||
# set environment variables for new units started by user service manager
|
||||
systemctl --user import-environment XDG_SESSION_TYPE XDG_CURRENT_DESKTOP
|
||||
fi
|
||||
|
||||
# Run cosmic-session
|
||||
if [[ -z "''${DBUS_SESSION_BUS_ADDRESS}" ]]; then
|
||||
exec dbus-run-session -- ${pkgs.cosmic-session}/bin/cosmic-session niri
|
||||
|
|
|
|||
|
|
@ -195,6 +195,7 @@
|
|||
melpaPackages.gptel-agent
|
||||
melpaPackages.aidermacs
|
||||
melpaPackages.async
|
||||
treesit-grammars.with-all-grammars
|
||||
pkgs.ispell
|
||||
pkgs.mu
|
||||
pkgs.openjdk
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue