Bug 161785 - Autofill overlay drawn above the cursor after scrolling the window in Calc
Summary: Autofill overlay drawn above the cursor after scrolling the window in Calc
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
24.8.0.0 beta1+
Hardware: All All
: medium normal
Assignee: Rafael Lima
URL:
Whiteboard: target:25.2.0 target:24.8.0.2
Keywords:
Depends on:
Blocks:
 
Reported: 2024-06-25 21:12 UTC by Rafael Lima
Modified: 2024-07-19 21:13 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
Selection before scrolling (OK) (6.99 KB, image/png)
2024-06-25 21:12 UTC, Rafael Lima
Details
Selection after scrolling (bug) (9.36 KB, image/png)
2024-06-25 21:13 UTC, Rafael Lima
Details
Screenshot with shape in focus (41.50 KB, image/png)
2024-07-19 14:00 UTC, Heiko Tietze
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Rafael Lima 2024-06-25 21:12:25 UTC
Created attachment 194956 [details]
Selection before scrolling (OK)

In LO 24.8 the selection overlay now has an internal white line for better contrast (see fix for bug 161204). However, after selecting a range of cells and scrolling the window, the order in which the cursor and selection overlays is inverted, making the selection overlay appear on top of the cursor.

Steps to reproduce
1) Open a blank and set the document zoom to a high value (to make it easier to see the bug, use 200% or more)
2) Select range B4:C8
3) Notice that the selection is behind the cursor, which is expected
4) Without unselecting the range, scroll the window
5) Now the selection is in front of the cursor (not expected)

Expected behavior
The selection should remain behind the cursor

See attached screenshots for more info.

System info

Version: 24.8.0.0.beta1+ (X86_64) / LibreOffice Community
Build ID: d681c57ba51b635ba7c85b21e062732110e8293f
CPU threads: 16; OS: Linux 6.8; UI render: default; VCL: kf5 (cairo+xcb)
Locale: pt-BR (pt_BR.UTF-8); UI: en-US
Calc: CL threaded
Comment 1 Rafael Lima 2024-06-25 21:13:21 UTC
Created attachment 194957 [details]
Selection after scrolling (bug)

Notice here that the selection overlay is in front of the cursor. It should be behind.
Comment 2 Rafael Lima 2024-06-25 22:10:00 UTC
Thanks for confirming. Patch is under way.
Comment 3 gladys 2024-07-02 20:26:33 UTC
Hi Rafael,

somehow i can not reproduce the bug in version:

Version: 24.8.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 74185b8edf7f046a3372319da86a1d8ca0024c87
CPU threads: 4; OS: Windows 10.0 Build 19045; UI render: Skia/Raster; VCL: win
Locale: en-GB (en_GB); UI: en-GB
Calc: CL threaded

or

Version: 7.6.4.1 (X86_64) / LibreOffice Community
Build ID: e19e193f88cd6c0525a17fb7a176ed8e6a3e2aa1
CPU threads: 4; OS: Windows 10.0 Build 19045; UI render: Skia/Raster; VCL: win
Locale: en-GB (en_GB); UI: en-GB
Calc: CL threaded
Comment 4 ady 2024-07-02 22:38:53 UTC
(In reply to gladys from comment #3)

> somehow i can not reproduce the bug in version:
> 
> Version: 24.8.0.0.alpha0+ (X86_64) / LibreOffice Community
> Build ID: 74185b8edf7f046a3372319da86a1d8ca0024c87
> or
> 
> Version: 7.6.4.1 (X86_64) / LibreOffice Community
> Build ID: e19e193f88cd6c0525a17fb7a176ed8e6a3e2aa1

@Gladys,

In order to reproduce the described behavior, you need to use a build that is later than Jun 12, 2024. Neither of the versions you tested with are relevant for this report.
Comment 5 Rafael Lima 2024-07-10 17:31:22 UTC
Fix in Gerrit
https://gerrit.libreoffice.org/c/core/+/170299
Comment 6 Commit Notification 2024-07-12 12:47:55 UTC
Rafael Lima committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/2f113fe5b2aeb2b9ca7866d88c31c0cc09889e2a

tdf#161785 Fix order overlays are repainted

It will be available in 25.2.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 7 Commit Notification 2024-07-14 21:56:48 UTC
Rafael Lima committed a patch related to this issue.
It has been pushed to "libreoffice-24-8":

https://git.libreoffice.org/core/commit/7958f5b111954632ca2792a0c3d18d79de5397c6

tdf#161785 Fix order overlays are repainted

It will be available in 24.8.0.2.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 8 Heiko Tietze 2024-07-19 14:00:25 UTC
Created attachment 195397 [details]
Screenshot with shape in focus

Now the cell focus rectangle is drawn over objects such as a shape. New ticket or reopen?
Comment 9 Rafael Lima 2024-07-19 21:13:08 UTC
(In reply to Heiko Tietze from comment #8)
> Now the cell focus rectangle is drawn over objects such as a shape. New
> ticket or reopen?

No need for new ticket... I'll take a look into it.