I have turned my monitor physically in portrait position. I adjusted Settings -> Displays so that the layout for my desktop is okay, but the login screen is still landscape.
I read that this problem could be fixed with following instructions:
sudo cp ~/.config/monitors.xml /var/lib/gdm3/.config/
sudo chown gdm:gdm /var/lib/gdm3/.config/monitors.xml
sudo systemctl restart gdm3
But to no avail, it just does not work. No matter if I reboot or even completely turn off and back on computer. The login screen remains in landscape position.
According to mutter documentation monitors.xml is read from /etc/xdg. Copied file there but it did not work either. This is clearly an issue that cannot be fixed with blind workarounds.
I edited /etc/xdg/monitors.xml so that there were different settings than in ~/.config/monitors.xml. After that some settings were applied in gdm process login screen while the rotation - it just wont budge, that change havae effects only in user process desktop. The problem is not the location of monitors.xml file, but how it takes effects on different processess, gdm land or user space.
Is it so that mutter under gdm does not have same capabilities than under user process desktop? If so, this is just banging head on the wall.
Could someone please explain the architecture behind all this gdm/mutter/gnome-shell mess?