Bug 431956 - Window titlebar is taller when running on wayland
Summary: Window titlebar is taller when running on wayland
Status: RESOLVED INTENTIONAL
Alias: None
Product: kwin
Classification: Plasma
Component: wayland-generic (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-01-22 20:34 UTC by MScattolin
Modified: 2021-02-19 16:26 UTC (History)
2 users (show)

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


Attachments
this shows a wayland screenshot(under) with a X11 screenshot(above) (57.24 KB, image/png)
2021-01-22 20:34 UTC, MScattolin
Details

Note You need to log in before you can comment on or make changes to this bug.
Description MScattolin 2021-01-22 20:34:57 UTC
Created attachment 135072 [details]
this shows a wayland screenshot(under) with a X11 screenshot(above)

SUMMARY


STEPS TO REPRODUCE
1. Start plasma on wayland
2. Titlebars are bigger than the same configuration on X11
3. -

OBSERVED RESULT
Considerably taller window titlebar when running on wayland

EXPECTED RESULT,
Given that both use the same font, fontsize, and titlebar size on systemsettings, they should have the same size.

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 5.10.9
(available in About System)
KDE Plasma Version: 5.20.90
KDE Frameworks Version: 5.78.0
Qt Version: 5.15.2

ADDITIONAL INFORMATION
It seems something related to the font/size, as changing fonts alter this behaviour. I am using Fira Sans 11pt as window title. I am also using it under 94dpi, if it matters.
This issue happens for quite some time now. I'm reporting it after seeing it still happens on the latest plasma beta (5.20.90)
Comment 1 Nate Graham 2021-01-26 06:14:24 UTC
Does this happen with other window decoration themes, or just Breeze?

Also does it happen with Noto Sans 10 or Noto Sans 11?
Comment 2 Bug Janitor Service 2021-02-10 04:33:14 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 3 MScattolin 2021-02-17 16:48:23 UTC
(In reply to Nate Graham from comment #1)
> Does this happen with other window decoration themes, or just Breeze?
> 
> Also does it happen with Noto Sans 10 or Noto Sans 11?

I can confirm it happens on oxygen as well, so maybe this should be moved to kwin?
Regarding the fonts, it does not happen with noto, the panel scales when changing from 11 to 12, on both wayland and x11. Fira does the same on X11, but the titlebar scales with size 11 on wayland only.
This is more like defect than properly a bug, but it can look pretty odd when using (not so) non standard fonts.

Since the titlebar size seems tied to glyph size, is it done differently on wayland?
Comment 4 Nate Graham 2021-02-19 15:37:44 UTC
Thanks for the info.
Comment 5 Nate Graham 2021-02-19 15:38:20 UTC
This may be intentional, but I'll let the KWin people confirm or deny that.
Comment 6 Vlad Zahorodnii 2021-02-19 16:21:24 UTC
> 94dpi

Decoration units are based on font metrics. On Wayland, we have 96dpi.
Comment 7 Nate Graham 2021-02-19 16:26:53 UTC
Ah right, yeah. In fact on Wayland we don't even let you change the font DPI; you have to adjust the font size or use the normal scaling system.