[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-28 Thread David Edmundson
https://bugs.kde.org/show_bug.cgi?id=465850

--- Comment #14 from David Edmundson  ---
Git commit 43481ac90728ade84643dc83da108462e9951830 by David Edmundson.
Committed on 28/02/2023 at 23:02.
Pushed by davidedmundson into branch 'Plasma/5.27'.

backends/wayland: Round passed scale

Converting to wl_fixed is lossy. Especially for non-round values like
1.15.

This causes various visual glitches and off sizes.
Given we're using units of 120ths for the fractional scale protocol it
makes sense to fix the passed values for anything else over the wayland
protocol.


(cherry picked from commit 3b7b173ada8152df9160506ab14c396ca230c1d9)

M  +6-1backends/kwayland/waylandoutputdevice.cpp

https://invent.kde.org/plasma/libkscreen/commit/43481ac90728ade84643dc83da108462e9951830

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-28 Thread Bug Janitor Service
https://bugs.kde.org/show_bug.cgi?id=465850

--- Comment #13 from Bug Janitor Service  ---
A possibly relevant merge request was started @
https://invent.kde.org/plasma/libkscreen/-/merge_requests/110

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-28 Thread David Edmundson
https://bugs.kde.org/show_bug.cgi?id=465850

--- Comment #12 from David Edmundson  ---
Git commit 3b7b173ada8152df9160506ab14c396ca230c1d9 by David Edmundson.
Committed on 28/02/2023 at 22:44.
Pushed by davidedmundson into branch 'master'.

backends/wayland: Round passed scale

Converting to wl_fixed is lossy. Especially for non-round values like
1.15.

This causes various visual glitches and off sizes.
Given we're using units of 120ths for the fractional scale protocol it
makes sense to fix the passed values for anything else over the wayland
protocol.

M  +6-1backends/kwayland/waylandoutputdevice.cpp

https://invent.kde.org/plasma/libkscreen/commit/3b7b173ada8152df9160506ab14c396ca230c1d9

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-24 Thread Nate Graham
https://bugs.kde.org/show_bug.cgi?id=465850

Nate Graham  changed:

   What|Removed |Added

 CC||adr...@nievergelt-merz.ch

--- Comment #11 from Nate Graham  ---
*** Bug 466311 has been marked as a duplicate of this bug. ***

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-23 Thread Nate Graham
https://bugs.kde.org/show_bug.cgi?id=465850

Nate Graham  changed:

   What|Removed |Added

   Version Fixed In||5.27.2

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-22 Thread bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=465850

--- Comment #10 from gudvinr+...@gmail.com ---
Can confirm that desktop size is 2226x1252 now and there are no issues with
different scaling for client apps as well (at least in mpv that I had problem
with before).

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-20 Thread Vlad Zahorodnii
https://bugs.kde.org/show_bug.cgi?id=465850

Vlad Zahorodnii  changed:

   What|Removed |Added

  Latest Commit|https://invent.kde.org/plas |https://invent.kde.org/plas
   |ma/kwin/commit/ada8e40792ba |ma/kwin/commit/aa700a13d639
   |f952a6893e217dded7785d251e6 |2b023d3a1e66892a0d59edd792d
   |d   |d

--- Comment #9 from Vlad Zahorodnii  ---
Git commit aa700a13d6392b023d3a1e66892a0d59edd792dd by Vlad Zahorodnii, on
behalf of David Edmundson.
Committed on 20/02/2023 at 12:23.
Pushed by vladz into branch 'Plasma/5.27'.

outputchangeset: Round passed scale

wl_fixed is lossy even for values that are representable as perfect doubles,
like 1.15

This causes various visual glitches and off sizes.

Given we're using units of 120ths for the fractional scale protocol it makes
sense
to fix the passed values for anything else over the wayland protocol.


(cherry picked from commit 3082133117c4360d4ac9bc7500f4d2338f86e8d0)

M  +6-1src/wayland/outputmanagement_v2_interface.cpp

https://invent.kde.org/plasma/kwin/commit/aa700a13d6392b023d3a1e66892a0d59edd792dd

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-20 Thread Bug Janitor Service
https://bugs.kde.org/show_bug.cgi?id=465850

--- Comment #8 from Bug Janitor Service  ---
A possibly relevant merge request was started @
https://invent.kde.org/plasma/libkscreen/-/merge_requests/102

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-20 Thread David Edmundson
https://bugs.kde.org/show_bug.cgi?id=465850

David Edmundson  changed:

   What|Removed |Added

  Latest Commit||https://invent.kde.org/plas
   ||ma/kwin/commit/ada8e40792ba
   ||f952a6893e217dded7785d251e6
   ||d
 Resolution|--- |FIXED
 Status|ASSIGNED|RESOLVED

--- Comment #7 from David Edmundson  ---
Git commit ada8e40792baf952a6893e217dded7785d251e6d by David Edmundson.
Committed on 20/02/2023 at 10:02.
Pushed by davidedmundson into branch 'master'.

outputchangeset: Round passed scale

Converting to wl_fixed is lossy. Especially for non-round values like 1.15.

This causes various visual glitches and off sizes.

Given we're using units of 120ths for the fractional scale protocol it makes
sense
to fix the passed values for anything else over the wayland protocol.

Testing done:
ran a 1920 screen at 1.15 scale, got a logical size of 1670 which matches what
it should be

M  +6-1src/wayland/outputmanagement_v2_interface.cpp

https://invent.kde.org/plasma/kwin/commit/ada8e40792baf952a6893e217dded7785d251e6d

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-19 Thread Bug Janitor Service
https://bugs.kde.org/show_bug.cgi?id=465850

Bug Janitor Service  changed:

   What|Removed |Added

 Status|CONFIRMED   |ASSIGNED

--- Comment #6 from Bug Janitor Service  ---
A possibly relevant merge request was started @
https://invent.kde.org/plasma/kwin/-/merge_requests/3630

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-19 Thread bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=465850

--- Comment #5 from gudvinr+...@gmail.com ---
(In reply to gudvinr+kde from comment #4)
> I guess if it had 1.14844, there will be no issues with gaps no matter what
> effective size is.

Okay, I read docs for wp_fractional_scale_v1 and it uses numerator with
denominator of 120. That's where 138 comes from because 138/120 is 1.15.

There is no way to send 1.14844 through this protocol. It is probably a good
thing because floating point numbers aren't great for representing exact values
anyway.

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-19 Thread bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=465850

--- Comment #4 from gudvinr+...@gmail.com ---
(In reply to David Edmundson from comment #3)
> It's stored via wl_fixed.
> 
> wl_fixed_to_double( wl_fixed_from_double(1.15) gives 1.14844
> 
> I thought we had a path to snap this back to a more likely number, but maybe
> it never landed.

MPV says it gets 1.15 for my second monitor:
[1119065.482] wp_fractional_scale_v1@28.preferred_scale(180)
[vo/gpu/wayland] Obtained preferred scale, 1.50, from the compositor.
[1119065.489] wp_fractional_scale_v1@28.preferred_scale(138)
[vo/gpu/wayland] Obtained preferred scale, 1.15, from the compositor.

I guess if it had 1.14844, there will be no issues with gaps no matter what
effective size is.

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-19 Thread David Edmundson
https://bugs.kde.org/show_bug.cgi?id=465850

David Edmundson  changed:

   What|Removed |Added

 CC||k...@davidedmundson.co.uk

--- Comment #3 from David Edmundson  ---
It's stored via wl_fixed.

wl_fixed_to_double( wl_fixed_from_double(1.15) gives 1.14844

I thought we had a path to snap this back to a more likely number, but maybe it
never landed.

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-17 Thread bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=465850

--- Comment #2 from gudvinr+...@gmail.com ---
So, info centre says that Scale for this screen is 1.14844 which doesn't really
make a lot of sense.
If value of 1.15 stored as IEEE754 float, you'll get either
1.1497615814208984375 for float32 or
1.149911182158029987476766109466552734375. Neither of which round
to 1.14844.

But at least it is obvious now where those weird sizes come from.

-- 
You are receiving this mail because:
You are watching all bug changes.

[kwin] [Bug 465850] Effective desktop size is wrong for certain scale values

2023-02-17 Thread Nate Graham
https://bugs.kde.org/show_bug.cgi?id=465850

Nate Graham  changed:

   What|Removed |Added

   Assignee|plasma-b...@kde.org |kwin-bugs-n...@kde.org
 Ever confirmed|0   |1
Summary|Virtual desktop size is |Effective desktop size is
   |wrong for certain scale |wrong for certain scale
   |values  |values
   Target Milestone|1.0 |---
Product|plasmashell |kwin
 Status|REPORTED|CONFIRMED
  Component|Desktop Containment |wayland-generic
 CC||n...@kde.org

-- 
You are receiving this mail because:
You are watching all bug changes.