This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Set "ForceFontDPI" globally such that it applies to SDDM

Tags: None
(comma "," separated)
mnagel
Registered Member
Posts
2
Karma
0
I have upgrade to Plasma Desktop (KDE5). For high resolution desktop there is the option "Force Font DPI" in the KCM font control panel. It works nicely, if the corresponding user is logged in. How do I set the same option globally such that also the login screen (SDDM) respects this option if no user is logged in?

The per-user config file is ~/.kde/share/config/kcmfonts and looks like
Code: Select all
[General]
dontChangeAASettings=true
forceFontDPI=120

I found this page https://kenno.wordpress.com/2012/07/22/kde4-system-wide-force-font-dpi-setting/ that gives the right file location for the global setting in case of Kubuntu. But this seems to be a distribution specific file location. I tried to copy the file into /usr/share/config but it has no effect.
luebking
Karma
0
sddm does not rely on KDE.
It however executes a script when setting up the server - usually located in /usr/share/sddm/scripts/Xsetup

add
Code: Select all
xrandr --dpi 200


there (and pick the favorable dpi instead of 200, of course)
mnagel
Registered Member
Posts
2
Karma
0
Code: Select all
xrandr --dpi 200


has not the same effect as "forceFontDPI". "forceFontDPI" only changes the DPI that is used to calculate how many pixels a certain font height has, but forceFontDPI keeps the screen resolution unaffected otherwise.

With forceFontDPI I get
Code: Select all
xrdb -query | egrep -i 'xft
Xft.dpi:        120
Xft.hinting:    -1
Xft.rgba:       none

but I still have
Code: Select all
xdpyinfo | egrep -i resolution
resolution:    209x209 dots per inch

otherwise. The latter should stay as it is, such that for example a DIN-A4 page still has the size of an actual DIN-A4 page if zoomed to 100%. You do not get this behaviour, if the overall DPI is set via xrandr.

Interestingly, sddm takes the ForceFontDPI setting into consideration if sddm is used a lock screen while a user is logged in (and the user has ForceFontDPI in its user profile). How do you explain the tip from the link I gave in the first post?
luebking
Karma
0
> if sddm is used a lock screen
It's not, ksmserver just uses the same qml.

> How do you explain the tip from the link I gave in the first post?
It says "KDE 4" and again: sddm has *nothing* to do with "KDE".

The solution however applies as well, just use

Code: Select all
echo 'Xft.dpi: 120' | xrdb -override


instead.


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], Sogou [Bot]