diff options
author | Thomas Tuegel <ttuegel@gmail.com> | 2016-08-23 08:22:11 -0500 |
---|---|---|
committer | Thomas Tuegel <ttuegel@gmail.com> | 2016-08-23 12:00:16 -0500 |
commit | 1df7279384550249717061c28bf2d914801d28db (patch) | |
tree | 6139a0ec9b3ef31c1debabaf8346dc038e8179aa | |
parent | 1ad6cff9a74c233741bb57157df2784f3c138da6 (diff) | |
download | nixlib-1df7279384550249717061c28bf2d914801d28db.tar nixlib-1df7279384550249717061c28bf2d914801d28db.tar.gz nixlib-1df7279384550249717061c28bf2d914801d28db.tar.bz2 nixlib-1df7279384550249717061c28bf2d914801d28db.tar.lz nixlib-1df7279384550249717061c28bf2d914801d28db.tar.xz nixlib-1df7279384550249717061c28bf2d914801d28db.tar.zst nixlib-1df7279384550249717061c28bf2d914801d28db.zip |
kde5.startkde: update from plasma-workspace-5.7.3
* Read the screen scale factor (for HiDPI displays) from KScreen correctly. * Disable automaticy scale factor detection in Qt applications. * Force font DPI at startup, if requested. * Allow kded to invoke kbuildsycoca5 automatically.
-rwxr-xr-x | pkgs/desktops/kde-5/plasma/startkde/startkde.sh | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/pkgs/desktops/kde-5/plasma/startkde/startkde.sh b/pkgs/desktops/kde-5/plasma/startkde/startkde.sh index c0d5f6dbf59a..5d415062235b 100755 --- a/pkgs/desktops/kde-5/plasma/startkde/startkde.sh +++ b/pkgs/desktops/kde-5/plasma/startkde/startkde.sh @@ -119,9 +119,12 @@ if test $returncode -ne 0; then fi [ -r $configDir/startupconfig ] && . $configDir/startupconfig -if test "$kdeglobals_kscreen_scalefactor" -ne 1; then - export QT_DEVICE_PIXEL_RATIO=$kdeglobals_kscreen_scalefactor +if [ "$kdeglobals_kscreen_screenscalefactors" ]; then + export QT_SCREEN_SCALE_FACTORS="$kdeglobals_kscreen_screenscalefactors" fi +#Manually disable auto scaling because we are scaling above +#otherwise apps that manually opt in for high DPI get auto scaled by the developer AND manually scaled by us +export QT_AUTO_SCREEN_SCALE_FACTOR=0 XCURSOR_PATH=~/.icons IFS=":" read -r -a xdgDirs <<< "$XDG_DATA_DIRS" @@ -159,6 +162,12 @@ unset THEME # xsetroot -cursor_name left_ptr +if test "$kcmfonts_general_forcefontdpi" -ne 0; then + xrdb -quiet -merge -nocpp <<EOF +Xft.dpi: $kcmfonts_general_forcefontdpi +EOF +fi + dl=$DESKTOP_LOCKED unset DESKTOP_LOCKED # Don't want it in the environment @@ -240,7 +249,7 @@ KDE_SESSION_VERSION=5 export KDE_SESSION_VERSION xprop -root -f KDE_SESSION_VERSION 32c -set KDE_SESSION_VERSION 5 -KDE_SESSION_UID=`id -ru` +KDE_SESSION_UID=$(id -ru) export KDE_SESSION_UID XDG_CURRENT_DESKTOP=KDE @@ -278,11 +287,6 @@ fi qdbus org.kde.KSplash /KSplash org.kde.KSplash.setStage kinit -# (NixOS) Run kbuildsycoca5 before starting the user session because things -# may be missing or moved if they have run nixos-rebuild and it may not be -# possible for them to start Konsole to run it manually! -kbuildsycoca5 - # finally, give the session control to the session manager # see kdebase/ksmserver for the description of the rest of the startup sequence # if the KDEWM environment variable has been set, then it will be used as KDE's |