Bug 428137 - Secondary monitor comes up blank
Summary: Secondary monitor comes up blank
Status: RESOLVED WORKSFORME
Alias: None
Product: plasmashell
Classification: Plasma
Component: generic-multiscreen (show other bugs)
Version: 5.20.0
Platform: Other FreeBSD
: NOR normal
Target Milestone: 1.0
Assignee: Aleix Pol
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-10-23 12:45 UTC by groot
Modified: 2020-10-25 21:23 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
screenshot 1 - monitor configuration (35.97 KB, image/png)
2020-10-23 12:53 UTC, groot
Details

Note You need to log in before you can comment on or make changes to this bug.
Description groot 2020-10-23 12:45:24 UTC
This is on FreeBSD with just-updated packages, e.g.
- plasma5-kwin-5.20.0_1
- qt5-core-5.15.0_2

After logging in (from SDDM), my left-hand (secondary) monitor is blank. My right-hand (primary) monitor shows an image. 

- Applications that I had started on the secondary monitor, are placed there "as usual" in this session: I just can't see them. 
- I can move the mouse onto the second monitor.
- While the mouse is on the second monitor (showing just blackness), I can alt-space, start application, etc. The application shows up in the task manager, which is on the primary monitor.
- Mousing around on the second monitor changes the cursor shape as I pass over the UI elements in applications on the second montor (e.g. the titlebar, splitters, and links -- I know Quasselclient is **there**, I just can't see it).

XRandR knows about the monitor:

```
Screen 0: minimum 8 x 8, current 3640 x 1920, maximum 16384 x 16384
VGA-0 disconnected (normal left inverted right x axis y axis)
DVI-D-0 connected 1080x1920+0+0 right (normal left inverted right x axis y axis) 531mm x 299mm
   1920x1080     60.00*+
   1680x1050     59.95  
   1600x1200     60.00  
   1440x900      59.89  
   1280x1024     60.02  
   1280x960      60.00  
   1152x720      60.00  
   1024x768      60.00  
   800x600       60.32    56.25  
   640x480       59.94  
HDMI-0 connected primary 2560x1440+1080+240 (normal left inverted right x axis y axis) 553mm x 311mm
   2560x1440     59.95*+
   1920x1080     60.00    59.94    50.00    60.00    50.04  
   1680x1050     59.95  
   1440x900      59.89  
   1280x1440     59.91  
   1280x1024     75.02    60.02  
   1280x960      60.00  
   1280x720      60.00    59.94    50.00  
   1024x768      75.03    70.07    60.00  
   800x600       75.00    72.19    60.32    56.25  
   720x576       50.00  
   720x480       59.94  
   640x480       75.00    72.81    59.94    59.93  
```

Running `kscreen-console` tells me both are known and enabled:

```
START: Requesting Config
Received config. Took 25 milliseconds
Screen:
        maxSize: QSize(16384, 16384)
        minSize: QSize(8, 8)
        currentSize: QSize(3640, 1920)

-----------------------------------------------------

Id:  637
Name:  "VGA-0"
Type:  "VGA"
Connected:  false

-----------------------------------------------------

Id:  638
Name:  "DVI-D-0"
Type:  "DVI"
Connected:  true
Enabled:  true
Primary:  false
Rotation:  8
Pos:  QPoint(0,0)
MMSize:  QSize(531, 299)
FollowPreferredMode:  false
Size:  QSize(1920, 1080)
Scale:  1
Clones:  None
Mode:  "639"
Preferred Mode:  "639"
Preferred modes:  ("639")
Modes: 
         "639"    ""   QSize(1920, 1080)   60
         "640"    ""   QSize(1680, 1050)   59.9543
         "641"    ""   QSize(1600, 1200)   60
         "642"    ""   QSize(1440, 900)   59.8874
         "643"    ""   QSize(1280, 1024)   60.0197
         "644"    ""   QSize(1280, 960)   60
         "645"    ""   QSize(1152, 720)   60.0009
         "646"    ""   QSize(1024, 768)   60.0038
         "647"    ""   QSize(800, 600)   60.3165
         "648"    ""   QSize(800, 600)   56.25
         "649"    ""   QSize(640, 480)   59.9405
EDID Info: 
        Device ID:  "xrandr-PLX2483H-1127950905734"
        Name:  "PLX2483H"
        Vendor:  ""
        Serial:  "1127950905734"
        EISA ID:  ""
        Hash:  "9e2f64f8ff5f7f5584f7b25d6326e394"
        Width:  53
        Height:  30
        Gamma:  2.2
        Red:  QQuaternion(scalar:1, vector:(0.648438, 0.332031, 0))
        Green:  QQuaternion(scalar:1, vector:(0.314453, 0.612305, 0))
        Blue:  QQuaternion(scalar:1, vector:(0.149414, 0.0585938, 0))
        White:  QQuaternion(scalar:1, vector:(0.313477, 0.329102, 0))

-----------------------------------------------------

Id:  650
Name:  "HDMI-0"
Type:  "HDMI"
Connected:  true
Enabled:  true
Primary:  true
Rotation:  1
Pos:  QPoint(1080,240)
MMSize:  QSize(553, 311)
FollowPreferredMode:  false
Size:  QSize(2560, 1440)
Scale:  1
Clones:  None
Mode:  "651"
Preferred Mode:  "651"
Preferred modes:  ("651")
Modes: 
         "639"    ""   QSize(1920, 1080)   60
         "640"    ""   QSize(1680, 1050)   59.9543
         "642"    ""   QSize(1440, 900)   59.8874
         "643"    ""   QSize(1280, 1024)   60.0197
         "644"    ""   QSize(1280, 960)   60
         "646"    ""   QSize(1024, 768)   60.0038
         "647"    ""   QSize(800, 600)   60.3165
         "648"    ""   QSize(800, 600)   56.25
         "649"    ""   QSize(640, 480)   59.9405
         "651"    ""   QSize(2560, 1440)   59.9506
         "652"    ""   QSize(1920, 1080)   59.9394
         "653"    ""   QSize(1920, 1080)   50
         "654"    ""   QSize(1920, 1080)   29.9984
         "655"    ""   QSize(1920, 1080)   25.0222
         "656"    ""   QSize(1280, 1440)   59.9126
         "657"    ""   QSize(1280, 1024)   75.0247
         "658"    ""   QSize(1280, 720)   60
         "659"    ""   QSize(1280, 720)   59.9434
         "660"    ""   QSize(1280, 720)   50
         "661"    ""   QSize(1024, 768)   75.0286
         "662"    ""   QSize(1024, 768)   70.0694
         "663"    ""   QSize(800, 600)   75
         "664"    ""   QSize(800, 600)   72.1876
         "665"    ""   QSize(720, 576)   50
         "666"    ""   QSize(720, 480)   59.9401
         "667"    ""   QSize(640, 480)   75
         "668"    ""   QSize(640, 480)   72.8088
         "669"    ""   QSize(640, 480)   59.9286
EDID Info: 
        Device ID:  "xrandr-Q2577W-ADQG69A000505"
        Name:  "Q2577W"
        Vendor:  ""
        Serial:  "ADQG69A000505"
        EISA ID:  ""
        Hash:  "e78150fac4dac08445b87ab73389c65a"
        Width:  55
        Height:  31
        Gamma:  2.2
        Red:  QQuaternion(scalar:1, vector:(0.661133, 0.332031, 0))
        Green:  QQuaternion(scalar:1, vector:(0.301758, 0.613281, 0))
        Blue:  QQuaternion(scalar:1, vector:(0.149414, 0.0595703, 0))
        White:  QQuaternion(scalar:1, vector:(0.313477, 0.329102, 0))

```

(You can tell from the layout information that my desktop is "T" shaped, with the T lying on its side: the secondary monitor is rotated 90 degrees and the primary monitor has a slightly weird position so that it "connects" to the middle 1440 pixels of the secondary monitor)

Vaguely related BRs:
 - https://bugs.kde.org/show_bug.cgi?id=369450 (multiple monitors blank)
 - https://bugs.kde.org/show_bug.cgi?id=372298 (multihead inoperative on second screen)
 - https://bugs.kde.org/show_bug.cgi?id=413329 (dual monitor config breaks)

I have a kscreen config file dated today, from when I logged in:

```
[
    {
        "enabled": true,
        "id": "9e2f64f8ff5f7f5584f7b25d6326e394",
        "metadata": {
            "fullname": "xrandr-PLX2483H-1127950905734",
            "name": "DVI-D-0"
        },
        "mode": {
            "refresh": 60,
            "size": {
                "height": 1080,
                "width": 1920
            }
        },
        "pos": {
            "x": 0,
            "y": 0
        },
        "primary": false,
        "rotation": 8,
        "scale": 1
    },
    {
        "enabled": true,
        "id": "e78150fac4dac08445b87ab73389c65a",
        "metadata": {
            "fullname": "xrandr-Q2577W-ADQG69A000505",
            "name": "HDMI-0"
        },
        "mode": {
            "refresh": 59.9505500793457,
            "size": {
                "height": 1440,
                "width": 2560
            }
        },
        "pos": {
            "x": 1080,
            "y": 240
        },
        "primary": true,
        "rotation": 1,
        "scale": 1
    }
]
```

The ids in that file refer to monitor information, which also exists and seems to be correct. The file outputs/9e2f64f8ff5f7f5584f7b25d6326e394 contains this:

```
{
    "id": "9e2f64f8ff5f7f5584f7b25d6326e394",
    "metadata": {
        "fullname": "xrandr-PLX2483H-1127950905734",
        "name": "DVI-D-0"
    },
    "mode": {
        "refresh": 60,
        "size": {
            "height": 1080,
            "width": 1920
        }
    },
    "rotation": 8,
    "scale": 1
}
```
Comment 1 groot 2020-10-23 12:51:42 UTC
Some other testing bits:

 - alt-space, "display" and pick "Display Configuration".
 - this shows me the configuration in screenshot 1 "monitor configuration". In spite of the KCM showing me two monitors, the left-hand one (secondary) is still blank.
 - I can click on "Identify" and only the primary monitor shows an OSD identifying it.
 - I can use spectacle to take a screenshot of the whole desktop, and see quassel on the secondary monitor (in spite of it looking like it's just black / blank).

In order to solve this -- for the current session -- I do the following:
 - drag the secondary monitor somewhere else, e.g. to the right-hand side of the  primary monitor
 - click "apply". Now there is an image on the monitor.
 - drag the secondary monitor back to "where it belongs" and click "apply" again.
Comment 2 groot 2020-10-23 12:53:07 UTC
Created attachment 132658 [details]
screenshot 1 - monitor configuration
Comment 3 groot 2020-10-23 14:57:47 UTC
While logging in, I do notice that there's *briefly* a KDE / Plasma splash shown on the secondary monitor, and then it blanks out. And stays blank until I perform the workaround.

Another thing is I have a ~/.local/share/kscreen/e5b666f26544853109f6a7cbd83eb904 and also a file in control/configs/ with the same hash. The latter has an entry for the secondary monitor only.
Comment 4 groot 2020-10-25 21:23:18 UTC
.. and now, whatever it was that I did (frown at the machine? restart?) it **does** come up with two monitors, but applications that were on monitor 2 (left-hand) at logout are all moved over to the primary monitor. Writing this off as "tl; can't be arsed to debug further"