Bug 144981 - Insert Hyperlink dialog with artifacts in icons on the left bar (using gen/kf5/kf6)
Summary: Insert Hyperlink dialog with artifacts in icons on the left bar (using gen/kf...
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.2.1.2 release
Hardware: All Linux (All)
: medium normal
Assignee: Michael Weghorn
URL:
Whiteboard: target:25.2.0
Keywords:
Depends on:
Blocks: KDE, KF5 Hyperlink-Dialog Vertical-Tab-dialogs
  Show dependency treegraph
 
Reported: 2021-10-07 13:33 UTC by Rafael Lima
Modified: 2024-07-08 13:53 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
Screenshot showing the problem (28.86 KB, image/png)
2021-10-07 13:33 UTC, Rafael Lima
Details
Screenshot with gen VCL plugin (17.38 KB, image/png)
2024-05-31 06:11 UTC, Michael Weghorn
Details
Insert Hyperling dialog (notice the extra space to the right) (34.56 KB, image/png)
2024-07-08 12:50 UTC, Rafael Lima
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Rafael Lima 2021-10-07 13:33:07 UTC
Created attachment 175570 [details]
Screenshot showing the problem

The "Insert - Hyperlink" dialog has artifacts in the border surrounding the icons in the left bar (see attached image).

It seems like there's a border misaligned.

System info:
Version: 7.2.1.2 / LibreOffice Community
Build ID: 20(Build:2)
CPU threads: 16; OS: Linux 5.11; UI render: default; VCL: kf5 (cairo+xcb)
Locale: pt-BR (pt_BR.UTF-8); UI: en-US
Ubuntu package version: 1:7.2.1-0ubuntu0.21.04.1~lo1
Calc: threaded

Also in LO 7.3 alpha:
Version: 7.3.0.0.alpha0+ / LibreOffice Community
Build ID: c92a29fd6ef341a1657f90759d20e4f052b45843
CPU threads: 16; OS: Linux 5.11; UI render: default; VCL: kf5 (cairo+xcb)
Locale: pt-BR (pt_BR.UTF-8); UI: en-US
TinderBox: Linux-rpm_deb-x86_64@86-TDF, Branch:master, Time: 2021-09-26_16:13:32
Calc: threaded
Comment 1 Rafael Lima 2021-10-07 13:35:50 UTC
Maybe a kf5 issue?

The problem does not happen under the "gen" VCL plugin.

Version: 7.2.1.2 / LibreOffice Community
Build ID: 20(Build:2)
CPU threads: 16; OS: Linux 5.11; UI render: default; VCL: x11
Locale: pt-BR (pt_BR.UTF-8); UI: en-US
Ubuntu package version: 1:7.2.1-0ubuntu0.21.04.1~lo1
Calc: threaded
Comment 2 Dieter 2021-10-07 19:18:54 UTC
Also not a problem in Windows. Tested with

Version: 7.2.1.2 (x64) / LibreOffice Community
Build ID: 87b77fad49947c1441b67c559c339af8f3517e22
CPU threads: 4; OS: Windows 10.0 Build 19043; UI render: Skia/Raster; VCL: win
Locale: de-DE (de_DE); UI: en-GB
Calc: CL
Comment 3 Deep17 2021-11-05 15:16:55 UTC
I can't reproduce this in 

Version: 7.2.2.2 (x64) / LibreOffice Community
Build ID: 02b2acce88a210515b4a5bb2e46cbfb63fe97d56
CPU threads: 4; OS: Windows 10.0 Build 19042; UI render: Skia/Vulkan; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: threaded

and

Version: 7.3.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: 542a38de1a071f54f61806683dafea84e43edce9
CPU threads: 4; OS: Windows 10.0 Build 19042; UI render: Skia/Vulkan; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: threaded
Comment 4 Rafael Lima 2021-12-07 00:27:00 UTC
Possibly a Kf5-only issue.

The bug is still present in LO 7.3 beta 1.

Version: 7.3.0.0.beta1 / LibreOffice Community
Build ID: 436f14c25ec1847646b953cf13d0db4f7ca3be57
CPU threads: 16; OS: Linux 5.13; UI render: default; VCL: kf5 (cairo+xcb)
Locale: pt-BR (pt_BR.UTF-8); UI: en-US
Calc: threaded
Comment 5 Michael Weghorn 2021-12-07 07:28:46 UTC
I can reproduce with

Version: 7.4.0.0.alpha0+ / LibreOffice Community
Build ID: 2e5d18127f3be6741677bb567f9db37e2f4a9908
CPU threads: 12; OS: Linux 5.15; UI render: default; VCL: kf5 (cairo+xcb)
Locale: en-GB (en_GB.UTF-8); UI: en-US
Calc: threaded
Comment 6 Jan-Marek Glogowski 2022-04-07 05:15:27 UTC
This looks like a bug in the headless VCL plugin code. Removing the 

        cairo_matrix_t aMatrix;
        cairo_matrix_init_translate(&aMatrix, 0.5, 0.5);
        cairo_set_matrix(cr, &aMatrix);

block from SvpGraphicsBackend::drawPolyPolygon fixes this artifact, but results in other drawing glitches, because the sub-pixel positioning then is a bit off (half a pixel). Or I'm missing something else or maybe it's a Cairo bug.

It doesn't show up in gtk3, which also uses Cairo / this code, because gtk3 - via weld - uses a native widget instead of LO's widget (some GtkNotebook). The QPainter Qt5 code is also correct.
Comment 7 QA Administrators 2024-04-07 03:14:30 UTC Comment hidden (obsolete)
Comment 8 Haris 2024-04-12 01:24:37 UTC
I cannot reproduce the bug in 

Stable Build
Version: 24.2.2.2 (AARCH64) / LibreOffice Community
Build ID: d56cc158d8a96260b836f100ef4b4ef25d6f1a01
CPU threads: 10; OS: macOS 14.1.2; UI render: Skia/Metal; VCL: osx
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded

Master/Daily Build
Version: 24.8.0.0.alpha0+ (AARCH64) / LibreOffice Community
Build ID: c4023d3ec604abfff38be2053e2989c7ec2ba8c1
CPU threads: 10; OS: macOS 14.1.2; UI render: Skia/Metal; VCL: osx
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded

Please let me know if its still present on Linux in the newer versions.
Comment 9 BogdanB 2024-04-12 11:22:27 UTC
(In reply to Haris from comment #8)
> I cannot reproduce the bug in 
> 
> Stable Build
> Version: 24.2.2.2 (AARCH64) / LibreOffice Community
> Build ID: d56cc158d8a96260b836f100ef4b4ef25d6f1a01
> CPU threads: 10; OS: macOS 14.1.2; UI render: Skia/Metal; VCL: osx
> Locale: en-US (en_US.UTF-8); UI: en-US
> Calc: threaded
> 
> Master/Daily Build
> Version: 24.8.0.0.alpha0+ (AARCH64) / LibreOffice Community
> Build ID: c4023d3ec604abfff38be2053e2989c7ec2ba8c1
> CPU threads: 10; OS: macOS 14.1.2; UI render: Skia/Metal; VCL: osx
> Locale: en-US (en_US.UTF-8); UI: en-US
> Calc: threaded
> 
> Please let me know if its still present on Linux in the newer versions.

Should be tested on kf5.
Comment 10 Buovjaga 2024-04-18 06:10:25 UTC
Repro

Arch Linux 64-bit
Version: 24.8.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 1d5630c5deeec5dca724c29ec8c886bfa71a2099
CPU threads: 8; OS: Linux 6.8; UI render: default; VCL: kf6 (cairo+wayland)
Locale: fi-FI (fi_FI.UTF-8); UI: en-US
Calc: threaded
Built on 16 April 2024
Comment 11 Michael Weghorn 2024-05-31 06:11:25 UTC
Created attachment 194470 [details]
Screenshot with gen VCL plugin

The same issue can be seen with the gen/X11 VCL plugin as well, s. attached screenshot.

Version: 24.8.0.0.alpha1+ (X86_64) / LibreOffice Community
Build ID: a78e908093d5c5e1b1f1401b0863c98b9b523ea9
CPU threads: 32; OS: Linux 6.7; UI render: default; VCL: x11
Locale: en-GB (en_GB.UTF-8); UI: en-US
Calc: CL threaded
Comment 12 Buovjaga 2024-06-11 15:14:38 UTC
Tip from Caolán in the chat:

the "left bar" of the gen vertical tab is probably "SvtIconChoiceCtrl" of vcl/source/control/ivctrl.cxx and quite possibly dropping "WB_3DLOOK" and/or chasing how SvtIconChoiceCtrl does its drawing might be of some use to pretty it up
Comment 13 Commit Notification 2024-07-04 06:48:25 UTC
Michael Weghorn committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/a52b152b4152db97bac70cd31dd707373c574400

tdf#144981 tdf#161853 icon choice ctrl: One selection border is enough

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 14 Heiko Tietze 2024-07-04 07:50:15 UTC
The patch might be an improvement but the UX is far away from compatible with gtk3. Do you want to handle it in extra patches?
Comment 15 Buovjaga 2024-07-04 09:01:33 UTC
(In reply to Heiko Tietze from comment #14)
> The patch might be an improvement but the UX is far away from compatible
> with gtk3. Do you want to handle it in extra patches?

I see bug 161501, which already has an unmerged patch associated with it. Are there others?
Comment 16 Buovjaga 2024-07-04 09:02:43 UTC
(In reply to Buovjaga from comment #15)
> (In reply to Heiko Tietze from comment #14)
> > The patch might be an improvement but the UX is far away from compatible
> > with gtk3. Do you want to handle it in extra patches?
> 
> I see bug 161501, which already has an unmerged patch associated with it.
> Are there others?

Ok, there is also bug 161355, but that covers Windows as well.
Comment 17 Heiko Tietze 2024-07-04 09:05:07 UTC
True, we have two more. Fine for me to keep this one as fixed.
Comment 18 Michael Weghorn 2024-07-04 09:09:57 UTC
(In reply to Heiko Tietze from comment #17)
> True, we have two more. Fine for me to keep this one as fixed.

Yes, let's handle the remaining aspects in the other tickets. My goal so far was just to fix the (at least to me) most annoying/confusing aspects.
Comment 19 Rafael Lima 2024-07-08 12:50:49 UTC
Created attachment 195168 [details]
Insert Hyperling dialog (notice the extra space to the right)

I am getting an additional space to the right (see screenshot).

Is this the intended result?

Tested with today's master.

Version: 25.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 343e9126f4930a7744e94a404004d2124582292d
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 20 Michael Weghorn 2024-07-08 13:22:55 UTC
(In reply to Rafael Lima from comment #19)
> I am getting an additional space to the right (see screenshot).
> 
> Is this the intended result?

Is this related to any of the commits for this bug or tdf#161853? If so, it's unintended.

However, e.g. attachment 194825 [details] from tdf#161659 (a screenshot older than my commits) looks similar and I don't see any real difference in a quick local revert of the commit from comment 13, so it looks unrelated to me at first glance at least.
Comment 21 Rafael Lima 2024-07-08 13:53:54 UTC
(In reply to Michael Weghorn from comment #20)
> Is this related to any of the commits for this bug or tdf#161853? If so,
> it's unintended.

You're right... this is related to some other commit.

Let's leave this as fixed and deal with this new issue in bug 161659.