Bug 160786 - Weird formatting in Calc 24.2
Summary: Weird formatting in Calc 24.2
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
24.2.0.0 alpha1+
Hardware: x86-64 (AMD64) All
: medium trivial
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bibisected, bisected, regression
Depends on:
Blocks:
 
Reported: 2024-04-22 23:20 UTC by Ron Widell
Modified: 2024-05-09 16:23 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
Excel file to demonstrate format error (12.79 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2024-04-22 23:23 UTC, Ron Widell
Details
screenshot of expected formatting (26.85 KB, image/png)
2024-04-22 23:24 UTC, Ron Widell
Details
screenshot of formatting under 24.2.1.2 (38.06 KB, image/png)
2024-04-22 23:25 UTC, Ron Widell
Details
Misalignment ODS test (10.57 KB, application/vnd.oasis.opendocument.spreadsheet)
2024-04-23 04:07 UTC, ady
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ron Widell 2024-04-22 23:20:16 UTC
Description:
In cells expecting currency in USD, the dollar sign is near the left edge of the cell in 7.5.4.1, but in 24.2.1.2 it gets shifted further left so it's on the left border of the cell.

While this isn't a functional bug, it makes me wonder what other artifacts there may be.

Steps to Reproduce:
1.open the file and look.
2.
3.

Actual Results:
Dollar sign is aligned on left border of cell

Expected Results:
Dollar sign lies completely inside the cell.


Reproducible: Always


User Profile Reset: Yes

Additional Info:
3 files:
format_test.xlxs
screenshot_7.5.4.1.png
screenshot_24.2.1.2.png
Comment 1 Ron Widell 2024-04-22 23:23:12 UTC
Created attachment 193810 [details]
Excel file to demonstrate format error
Comment 2 Ron Widell 2024-04-22 23:24:21 UTC
Created attachment 193811 [details]
screenshot of expected formatting
Comment 3 Ron Widell 2024-04-22 23:25:06 UTC
Created attachment 193812 [details]
screenshot of formatting under 24.2.1.2
Comment 4 m_a_riosv 2024-04-23 01:59:00 UTC
It doesn't happen with monospaced fonts. Neither Skia options have affect. And Safe Mode doesn't help.
Reproducible with:
Version: 24.2.2.2 (X86_64) / LibreOffice Community
Build ID: d56cc158d8a96260b836f100ef4b4ef25d6f1a01
CPU threads: 16; OS: Windows 10.0 Build 22631; UI render: Skia/Raster; VCL: win
Locale: es-ES (es_ES); UI: en-US
Calc: CL threaded.
since
Version: 24.2.0.0.alpha1 (X86_64) / LibreOffice Community
Build ID: 06946980c858649160c634007e5fac9a5aa81f38
CPU threads: 16; OS: Windows 10.0 Build 22631; UI render: default; VCL: win
Locale: es-ES (es_ES); UI: en-US
Calc: threaded


But not reproducible with master
Version: 24.8.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 05a1217921b7be283c6750a35b90e4feda6e993e
CPU threads: 16; OS: Windows 10.0 Build 22631; UI render: Skia/Vulkan; VCL: win
Locale: es-ES (es_ES); UI: en-US
Calc: CL threaded.

Regression from
Version: 7.6.6.3 (X86_64) / LibreOffice Community
Build ID: d97b2716a9a4a2ce1391dee1765565ea469b0ae7
CPU threads: 16; OS: Windows 10.0 Build 22631; UI render: Skia/Raster; VCL: win
Locale: es-ES (es_ES); UI: es-ES
Calc: CL threaded
Comment 5 ady 2024-04-23 04:07:42 UTC
Created attachment 193814 [details]
Misalignment ODS test

Although I am not completely sure, I think I can replicate the problem with LO 24.8 alpha built today 2024-04-23.

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

I am attaching a simple ods file.

STR:
1. Open the attachment
2. Modify the zoom factor; zooming-out shows the problem easier, but also zooming-in (e.g. [CTRL]+(mouse wheel)).

The misplacement (or misalignment) of the "$" sign is seen under some zoom factors, especially when zooming-out to very small zoom values.

3. (Optional) The cells' alignment is set to "default", so the visual effect is seen on the left side of the cells. If the column/cells are changed to align to the left, then the visual effect is seen on the right side (on the numbers) when modifying the zoom factor.

Note that the visual effect is not seen with mono-spaced fonts, or at least not so clearly.

Up to LO 7.6.5.2, the visual misplacement according to zoom factors is relatively small. OTOH, since LO 24.2, the misplacement/misalignment is much evident (up to a diagonal completely out of the cell borders when using some very small zoom factors).

It should be noted that this behavior might be an unwanted consequence of a valid modification; it might be unavoidable. I tend to use mono-spaced fonts when (numeric) alignment is desired.
Comment 6 raal 2024-04-23 15:40:22 UTC
This seems to have begun at the below commit in bibisect repository/OS linux-64-24.2.
Adding Cc: to Khaled Hosny ; Could you possibly take a look at this one?
Thanks
 4ce9836c2406d6fc50482782ef4675b5e5078edb is the first bad commit
commit 4ce9836c2406d6fc50482782ef4675b5e5078edb
Author: Jenkins Build User <tdf@pollux.tdf>
Date:   Sun Jul 23 06:26:11 2023 +0200

    source 4b743de97fc133623e46827869c4ea3eb845ad47

154292: tdf#156234: Don’t round glyph coordinates when doing subpixel positioning | https://gerrit.libreoffice.org/c/core/+/154292