You are not logged in.
I have a problem with switching output from laptop screen to VGA and back. If I do so font in all newly started applications is larger than usual (even in simple ones, like dmenu). If I cycle outputs again the font grows more. If I make many cycles it eventually becomes enormous. The problem is fixed by X server restart (XMonad restart doesn't help).
Setup
I use XMonad launched with startx. Output is switched by xrandr called in a udev rule, if it makes sense. Here is the output of xrandr:
Screen 0: minimum 8 x 8, current 1366 x 768, maximum 32767 x 32767
LVDS1 connected (normal left inverted right x axis y axis)
1280x800 59.99 + 50.00
1024x768 60.00
800x600 60.32 56.25
640x480 59.94
640x400 60.00
DP1 disconnected (normal left inverted right x axis y axis)
DP2 disconnected (normal left inverted right x axis y axis)
DP3 disconnected (normal left inverted right x axis y axis)
HDMI1 disconnected (normal left inverted right x axis y axis)
HDMI2 disconnected (normal left inverted right x axis y axis)
VGA1 connected 1366x768+0+0 (normal left inverted right x axis y axis) 410mm x 230mm
1366x768 59.79*+
1280x800 59.81
1280x720 60.00
1024x768 75.08 70.07 60.00
832x624 74.55
800x600 72.19 75.00 60.32 56.25
640x480 75.00 72.81 66.67 60.00
720x400 70.08
VIRTUAL1 disconnected (normal left inverted right x axis y axis)I use only one monitor at once.
The problem has persisted for a long time (and for a lot of upgrades), but I understood that it is connected with output switching only recently.
Any help would be appreciated.
Last edited by NZinov (2016-01-22 20:21:54)
Offline
Output is switched by xrandr called in a udev rule, if it makes sense.
Please post the udev rule (and the name of the file containing the rule).
Check the DPI before and after the fonts "grow"
xdpyinfo|grep dotsJin, Jîyan, Azadî
Offline
Thanks for your quick reply, Head_on_a_Stick!
I checked DPI and there is definitely a problem! Here is the output (each command after another output switch)
xdpyinfo|grep dots
resolution: 96x97 dots per inch
$ xdpyinfo|grep dots
resolution: 97x97 dots per inch
$ xdpyinfo|grep dots
resolution: 97x97 dots per inch
$ xdpyinfo|grep dots
resolution: 97x98 dots per inch
$ xdpyinfo|grep dots
resolution: 97x98 dots per inch
$ xdpyinfo|grep dots
resolution: 97x98 dots per inch
$ xdpyinfo|grep dots
resolution: 98x98 dots per inch
$ xdpyinfo|grep dots
resolution: 98x98 dots per inchHere is the udev rule under rules.d:
$ cat 90-dock-hotplug.rules
KERNEL=="dock.2", ATTR{docked}=="1", ENV{DISPLAY}=":0", ENV{XAUTHORITY}="/home/nikolay/.Xauthority",RUN+="/usr/bin/xrandr --output VGA1 --auto --output LVDS1 --off"
KERNEL=="dock.2", ATTR{docked}=="0", ENV{DISPLAY}=":0", ENV{XAUTHORITY}="/home/nikolay/.Xauthority",RUN+="/usr/bin/xrandr --output VGA1 --off --output LVDS1 --auto"My laptop is a thinkpad x200 and I have a docking station. This rules checks if that station is connected.
Thanks for you help!
Last edited by NZinov (2016-01-22 08:16:50)
Offline
Going to read smth about DPI on the wiki.)
Offline
You can try setting the DPI explicitly in your `startx` command:
startx -- -dpi 96(other methods are available)
Jin, Jîyan, Azadî
Offline
Thank you very much, Head_on_a_Stick! This worked for me.
Offline
Excellent!
Please add [SOLVED] to the thread title for the benefit of others ![]()
Jin, Jîyan, Azadî
Offline