Created attachment 161369 [details] Example file from Writer Attached document contains drawing shapes with Square and Quadratic gradient fill set. They have for the Center setting X=0%, Y=0% set, but their actual center is not positioned according to that, unlike for the Ellipsoid gradients case. Steps to reproduce: 1. Open attached document Actual results: The Quadratic and Square gradient types have incorrect center points. Expected results: The Quadratic and Square gradient types have correct center points. LibreOffice details: Version: 7.1.0.0.alpha0+ (x64) Build ID: 41d8b41767032681a9897b7551f011d450e3725e CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: Skia/Raster; VCL: win Locale: hu-HU (hu_HU); UI: en-US Calc: CL Also in: Verzió: 6.0.0.3 Build az.: 64a0f66915f38c6217de274f0aa8e15618924765 CPU szálak: 4; OS: Windows 6.3; Felületmegjelenítés: alapértelmezett; Területi beállítások: hu-HU (hu_HU); Calc: CL Version: 5.1.0.3 Build ID: 5e3e00a007d9b3b6efb6797a8b8e57b51ab1f737 CPU Threads: 4; OS Version: Windows 6.2; UI Render: default; Locale: en-US (hu_HU) But not in: (for the Square case) Version: 5.0.0.5 Build ID: 1b1a90865e348b492231e1c451437d7a15bb262b Locale: hu-HU (hu_HU)
Created attachment 161370 [details] Screenshot of the problem in Writer
Created attachment 161371 [details] The example file in Writer 5.0 and 5.1
Created attachment 161382 [details] not a bug video It's not a bug, it's a different angle. See my video. Version: 6.4.3.2 Build ID: libreoffice-6.4.3.2-snap1 CPU threads: 4; OS: Linux 5.4; UI render: default; VCL: gtk3; Locale: ro-RO (ro_RO.UTF-8); UI-Language: en-US Calc: threaded
That would then mean it's a different bug and not that there is no bug, wouldn't it?
Agree. The angle should not change.
Created attachment 163213 [details] All gradient types in OOo3.2.1 The file "All gradient types in OOo3.2.1" contains the gradient types "square", "rectangular", "radial" and "ellipsoid" with X-Offset 25% and Y-Offset 20% on shapes with width=4cm and height=10cm. In LibreOffice 7, I see that "square" has a wrong x-position of the gradient center (slides 2 and 3). All other gradients are correct. The error exists in AOO4 too, so nothing new in LibreOffice. The file contains for each case the shapes and a bitmap. And it contains slides, which explain how the gradient size is determined and how the gradients are build. OOo1.1.5 had slightly different methods in its sxi. I have not checked, whether border is correct. Border is always 0 in the examples.
BTW, "quadric" in UI = "square" in file "square" in UI = "rectangular" in file The comparison between 5.0 and 5.1 shows, that 5.0 ignores the angle. So 5.0 is wrong.
Created attachment 163448 [details] Draft unit test document
Tünde Tóth committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/52f8e0b6f09be0e8e8a068edef2017d45d5a1892 tdf#133477 basegfx: fix center of rotated gradients It will be available in 7.1.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.
Verified in Version: 7.1.0.0.alpha0+ Build ID: 6ad2f463784a24c566477cdd60ae729651bb8564 CPU threads: 4; OS: Linux 5.4; UI render: default; VCL: gtk3 Locale: ro-RO (ro_RO.UTF-8); UI: en-US Calc: threaded