Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiscreen support is very limited #966

Open
jacob-emery opened this issue Jan 18, 2018 · 5 comments
Open

Multiscreen support is very limited #966

jacob-emery opened this issue Jan 18, 2018 · 5 comments

Comments

@jacob-emery
Copy link

I have a Laptop and an external display. I encounted these 3 problems:

a) If I am on the SDDM screen with the external display disconnected and then I decide to connect the external display to my laptop, then happens a black screen. I managed to "partially" solve the problem by executing editing the file /usr/share/sddm/scripts/Xsetup
and then adding:
intern=eDP-1
extern=DP-1
if xrandr | grep "$extern disconnected"; then
xrandr --output "$extern" --off --output "$intern" --auto
else
xrandr --output "$intern" --off --output "$extern" --auto
fi
Now if I connect the screen, I won't get a black screen, but the external display won't display anything till I login. It is okay for me, but it would be of course better if we can really fix this.

b) You cannot really choose which display will be your primary. Although in KDE settings my primary desktop was the external one, I had some trouble with SDDM: always with the same tweak that I wrote above, in a), I solved the problem. I think we should make easily possible for people to choose which display should be the primary, which one should be left placed, which one should be placed to the right, and which shouldn't be displayed at all, at least till they log into the KDE Plasma desktop.

c) After making the tweak in a), the display that gets shown is now the correct one. There is still a minor bug now: when I power my machine and I see the SDDM Login screen on my DP-1 display, the mouse cursor is not centered like with the laptop screen, but is horizontally set more to the right. Vertically is correct, because it is in the middle. Just horizontally not. It would be pleasant to see the cursor in the center of the screen.

Except while connecting my laptop to an external display through a Display Port cable, I haven't encounted any other bugs. Thank you for reading my bug report!

@Vogtinator
Copy link
Contributor

The expected behaviour is to have sddm display on all attached screens. So there is no concept of a "primary monitor".

Can you upload the sddm log?

@rimrul
Copy link

rimrul commented Apr 23, 2018

There is a primary monitor. It'll have the it's first textbox focused. see #602, #573, #268, ... It appears in /src/greeter/ScreenModel.cpp#L49-L52.

I can reproduce the black screen on Kubuntu bionic beta 2 (SDDM v0.17.0). I've grabbed a log from journalctl|grep sddm.

Apr 23 19:02:53 x1c3 sddm[792]: Initializing...
Apr 23 19:02:53 x1c3 sddm[792]: Logind interface found
Apr 23 19:02:53 x1c3 sddm[792]: Starting...
Apr 23 19:02:53 x1c3 sddm[792]: Adding new display on vt 1 ...
Apr 23 19:02:53 x1c3 sddm[792]: Loading theme configuration from ""
Apr 23 19:02:53 x1c3 sddm[792]: Display server starting...
Apr 23 19:02:53 x1c3 sddm[792]: Running: /usr/bin/X -nolisten tcp -auth /var/run/sddm/{6b4bce50-4317-47e6-981f-e43b42e3663a} -background none -noreset -displayfd 18 -seat seat0 vt1
Apr 23 19:02:54 x1c3 sddm[792]: Setting default cursor
Apr 23 19:02:54 x1c3 sddm[792]: Running display setup script  "/usr/share/sddm/scripts/Xsetup"
Apr 23 19:02:54 x1c3 sddm[792]: Display server started.
Apr 23 19:02:54 x1c3 sddm[792]: Socket server starting...
Apr 23 19:02:54 x1c3 sddm[792]: Socket server started.
Apr 23 19:02:54 x1c3 sddm[792]: Loading theme configuration from "/usr/share/sddm/themes/breeze/theme.conf"
Apr 23 19:02:54 x1c3 sddm[792]: Greeter starting...
Apr 23 19:02:54 x1c3 sddm[792]: Adding cookie to "/var/run/sddm/{6b4bce50-4317-47e6-981f-e43b42e3663a}"
Apr 23 19:02:54 x1c3 sddm-helper[826]: [PAM] Starting...
Apr 23 19:02:54 x1c3 sddm-helper[826]: [PAM] Authenticating...
Apr 23 19:02:54 x1c3 sddm-helper[826]: [PAM] returning.
Apr 23 19:02:54 x1c3 sddm-helper[826]: pam_unix(sddm-greeter:session): session opened for user sddm by (uid=0)
Apr 23 19:02:54 x1c3 systemd[1]: Created slice User Slice of sddm.
Apr 23 19:02:54 x1c3 systemd-logind[639]: New session 1 of user sddm.
Apr 23 19:02:54 x1c3 systemd[1]: Started Session 1 of user sddm.
Apr 23 19:02:54 x1c3 systemd[829]: pam_unix(systemd-user:session): session opened for user sddm by (uid=0)
Apr 23 19:02:54 x1c3 sddm[792]: Greeter session started successfully
Apr 23 19:02:54 x1c3 sddm-greeter[840]: High-DPI autoscaling not Enabled
Apr 23 19:02:54 x1c3 sddm-greeter[840]: Loading theme configuration from "/usr/share/sddm/themes/breeze/theme.conf"
Apr 23 19:02:54 x1c3 sddm-greeter[840]: Reading from "/usr/share/xsessions/plasma.desktop"
Apr 23 19:02:54 x1c3 sddm-greeter[840]: Reading from "/usr/share/wayland-sessions/plasmawayland.desktop"
Apr 23 19:02:54 x1c3 sddm-greeter[840]: Connected to the daemon.
Apr 23 19:02:54 x1c3 sddm[792]: Message received from greeter: Connect
Apr 23 19:02:54 x1c3 sddm-greeter[840]: Loading file:///usr/share/sddm/themes/breeze/Main.qml...
Apr 23 19:02:54 x1c3 sddm-greeter[840]: QObject: Cannot create children for a parent that is in a different thread.
Apr 23 19:02:54 x1c3 sddm-greeter[840]: QObject: Cannot create children for a parent that is in a different thread.
Apr 23 19:02:54 x1c3 sddm-greeter[840]: QObject: Cannot create children for a parent that is in a different thread.
Apr 23 19:02:54 x1c3 sddm-greeter[840]: QObject::installEventFilter(): Cannot filter events for objects in a different thread.
Apr 23 19:02:54 x1c3 sddm-greeter[840]: QObject: Cannot create children for a parent that is in a different thread.
Apr 23 19:02:54 x1c3 sddm-greeter[840]: QObject: Cannot create children for a parent that is in a different thread.
Apr 23 19:02:54 x1c3 sddm-greeter[840]: QObject::installEventFilter(): Cannot filter events for objects in a different thread.
Apr 23 19:02:54 x1c3 sddm-greeter[840]: Cannot watch QRC-like path ":/icons/hicolor/index.theme"
Apr 23 19:02:55 x1c3 dbus-daemon[614]: [system] Activating via systemd: service name='org.freedesktop.UPower' unit='upower.service' requested by ':1.21' (uid=118 pid=840 comm="/usr/bin/sddm-greeter --socket /tmp/sddm-:0-oeXHKb" label="unconfined")
Apr 23 19:02:55 x1c3 sddm-greeter[840]: Adding view for "eDP-1" QRect(0,0 1920x1080)
Apr 23 19:02:55 x1c3 sddm-greeter[840]: Loading file:///usr/share/sddm/themes/breeze/Main.qml...
Apr 23 19:02:55 x1c3 sddm-greeter[840]: Adding view for "DP-2-2" QRect(1920,0 1920x1080)
Apr 23 19:02:55 x1c3 sddm-greeter[840]: Message received from daemon: Capabilities
Apr 23 19:02:55 x1c3 sddm-greeter[840]: Message received from daemon: HostName
Apr 23 19:03:01 x1c3 sddm-helper[826]: [PAM] Closing session
Apr 23 19:03:01 x1c3 sddm-helper[826]: pam_unix(sddm-greeter:session): session closed for user sddm
Apr 23 19:03:01 x1c3 sddm-helper[826]: [PAM] Ended.
Apr 23 19:03:01 x1c3 sddm[792]: Auth: sddm-helper exited successfully
Apr 23 19:03:01 x1c3 sddm[792]: Greeter stopped.
Apr 23 19:03:57 x1c3 sddm[792]: Signal received: SIGTERM
Apr 23 19:03:57 x1c3 sddm[792]: Socket server stopping...
Apr 23 19:03:57 x1c3 sddm[792]: Socket server stopped.
Apr 23 19:03:57 x1c3 sddm[792]: Display server stopping...
Apr 23 19:03:57 x1c3 systemd[1]: Stopping Session 1 of user sddm.
Apr 23 19:03:57 x1c3 systemd[1]: Stopped Session 1 of user sddm.
Apr 23 19:03:57 x1c3 systemd[830]: pam_unix(systemd-user:session): session closed for user sddm
Apr 23 19:03:57 x1c3 systemd[1]: Removed slice User Slice of sddm.
Apr 23 19:03:59 x1c3 sddm[792]: Display server stopped.
Apr 23 19:03:59 x1c3 sddm[792]: Running display stop script  "/usr/share/sddm/scripts/Xstop"

These are the entries after I unplugged the external monitor(DP-2-2):

Apr 23 19:03:01 x1c3 sddm-helper[826]: [PAM] Closing session
Apr 23 19:03:01 x1c3 sddm-helper[826]: pam_unix(sddm-greeter:session): session closed for user sddm
Apr 23 19:03:01 x1c3 sddm-helper[826]: [PAM] Ended.
Apr 23 19:03:01 x1c3 sddm[792]: Auth: sddm-helper exited successfully
Apr 23 19:03:01 x1c3 sddm[792]: Greeter stopped.

The SIGTERM after that is me forcefully shutting down, after I wasn't able to login blindly or switch to a TTY or get any form of control over the system. The earlier entries are identical to a successful login, so that seems to be all she wrote.

/var/log/sddm.log is empty. Are there any other logs that could help?

@Vogtinator
Copy link
Contributor

There is a primary monitor. It'll have the it's first textbox focused.

Yes, but outside of that it's not treated specially.

Apr 23 19:02:55 x1c3 sddm-greeter[840]: Adding view for "eDP-1" QRect(0,0 1920x1080)
Apr 23 19:02:55 x1c3 sddm-greeter[840]: Loading file:///usr/share/sddm/themes/breeze/Main.qml...
Apr 23 19:02:55 x1c3 sddm-greeter[840]: Adding view for "DP-2-2" QRect(1920,0 1920x1080)

Indicates that sddm shows two greeters. DP-2-2 is black?

@rimrul
Copy link

rimrul commented Apr 23, 2018

DP-2-2 is black?

No. Both show their greeter, DP-2-2 gets disconnected, eDP-1 goes black.

@rimrul
Copy link

rimrul commented Apr 23, 2018

I've had the same thing happen when booting without DP-2-2 and then connecting DP-2-2 or starting with the laptop closed and then opening thelaptop, thus "adding" eDP-1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants