Bug 473338 - Screen recording dialog shows nonsensical output name
Summary: Screen recording dialog shows nonsensical output name
Status: RESOLVED FIXED
Alias: None
Product: xdg-desktop-portal-kde
Classification: Plasma
Component: general (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords: qt6
: 480615 (view as bug list)
Depends on:
Blocks:
 
Reported: 2023-08-13 14:34 UTC by Nicolas Fella
Modified: 2024-02-13 17:40 UTC (History)
4 users (show)

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


Attachments
Screenshot (65.00 KB, image/png)
2023-08-13 14:35 UTC, Nicolas Fella
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nicolas Fella 2023-08-13 14:34:43 UTC
STEPS TO REPRODUCE
1. Start a screen recording 

OBSERVED RESULT
The screen chooser dialog shows my laptop's screen as "0x103D/0" (see screenshot)

EXPECTED RESULT
It should show a better name, like "Laptop screen"

SOFTWARE/OS VERSIONS
KDE Plasma Version: master
KDE Frameworks Version: master
Qt Version: 6.5.2

ADDITIONAL INFORMATION
Wayland

The string matches QScreen::model() for that screen

QScreen::name() is "eDP-1"
QScreen::manufacturer is "AU Optronics"
Comment 1 Nicolas Fella 2023-08-13 14:35:13 UTC
Created attachment 160932 [details]
Screenshot
Comment 2 Nate Graham 2023-09-05 21:30:33 UTC
Can reproduce. Didn't see this in KF5, so it's a KF6/Plasma 6 regression.
Comment 3 Aleix Pol 2023-09-05 22:02:15 UTC
Assigning to KWin, I can see the same weird non-sensical name using the "wayland-info" tool (I guess it would also with WAYLAND_DEBUG=1).

interface: 'zxdg_output_manager_v1',                     version:  3, name: 33
        xdg_output_v1
                output: 49
                name: 'eDP-1'
                description: 'BOE 0x08EE/0'
                logical_x: 0, logical_y: 0
                logical_width: 1920, logical_height: 1080
Comment 4 Vlad Zahorodnii 2023-11-22 10:27:54 UTC
That strange number comes from EDID. In Plasma 6, the output description format has changed so if the monitor name is available, it's going to be formatted as "monitor name/serial number".
Comment 5 Vlad Zahorodnii 2023-11-22 10:33:10 UTC
That's not really a kwin bug, it looks like xdp displays the model string. In addition to that, the OutputsModel incorrectly detects the type of the screen. The model doesn't contain connector name, QScreen::name() does so (although it's not guaranteed from the protocols perspective).
Comment 6 Bug Janitor Service 2023-11-22 10:35:56 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/xdg-desktop-portal-kde/-/merge_requests/251
Comment 7 Nicolas Fella 2024-02-01 13:02:38 UTC
*** Bug 480615 has been marked as a duplicate of this bug. ***
Comment 8 Vlad Zahorodnii 2024-02-13 13:30:58 UTC
Git commit 730f45c1851cc409bfcf8b0ad569cde40e17119c by Vlad Zahorodnii.
Committed on 13/02/2024 at 13:29.
Pushed by vladz into branch 'master'.

Fix connector type detection

The output model string doesn't contain the connector type. The output
name is not guaranteed either, but it's the best what we've got.

M  +2    -2    src/outputsmodel.cpp

https://invent.kde.org/plasma/xdg-desktop-portal-kde/-/commit/730f45c1851cc409bfcf8b0ad569cde40e17119c
Comment 9 Vlad Zahorodnii 2024-02-13 13:31:06 UTC
Git commit a428032f5e591a48105eeeb7044f6f7ecae639ef by Vlad Zahorodnii.
Committed on 13/02/2024 at 13:29.
Pushed by vladz into branch 'master'.

Format better human readable output descriptions

M  +27   -3    src/outputsmodel.cpp

https://invent.kde.org/plasma/xdg-desktop-portal-kde/-/commit/a428032f5e591a48105eeeb7044f6f7ecae639ef
Comment 10 Bug Janitor Service 2024-02-13 13:31:33 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/xdg-desktop-portal-kde/-/merge_requests/271
Comment 11 Vlad Zahorodnii 2024-02-13 13:34:06 UTC
Git commit c0dc10587a7e8dda4768fa1d87f97ed83103d31d by Vlad Zahorodnii.
Committed on 13/02/2024 at 13:31.
Pushed by vladz into branch 'Plasma/6.0'.

Fix connector type detection

The output model string doesn't contain the connector type. The output
name is not guaranteed either, but it's the best what we've got.


(cherry picked from commit 730f45c1851cc409bfcf8b0ad569cde40e17119c)

M  +2    -2    src/outputsmodel.cpp

https://invent.kde.org/plasma/xdg-desktop-portal-kde/-/commit/c0dc10587a7e8dda4768fa1d87f97ed83103d31d
Comment 12 Vlad Zahorodnii 2024-02-13 13:36:54 UTC
Git commit 2881858b0d079b5202990c0803260978124dd984 by Vlad Zahorodnii.
Committed on 13/02/2024 at 13:34.
Pushed by vladz into branch 'Plasma/6.0'.

Format better human readable output descriptions


(cherry picked from commit a428032f5e591a48105eeeb7044f6f7ecae639ef)

M  +27   -3    src/outputsmodel.cpp

https://invent.kde.org/plasma/xdg-desktop-portal-kde/-/commit/2881858b0d079b5202990c0803260978124dd984