Bug 156209 - Font size increases when copying from cell in edit mode and pasting into another in non-edit mode
Summary: Font size increases when copying from cell in edit mode and pasting into anot...
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.6.0.0 alpha1+
Hardware: All All
: high major
Assignee: Not Assigned
URL:
Whiteboard: target:24.2.0 target:7.6.1
Keywords: bibisected, bisected, regression
: 156932 157048 (view as bug list)
Depends on:
Blocks: Paste Calc-Cells
  Show dependency treegraph
 
Reported: 2023-07-09 14:00 UTC by Buovjaga
Modified: 2023-09-02 17:07 UTC (History)
6 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Buovjaga 2023-07-09 14:00:37 UTC
1. Open attachment 133881 [details] from bug 108376
2. Enter edit mode in cell A1, select all and copy
3. Without entering edit mode, paste into B1

The font size has increased from 10 pt to 17.6 pt.

Bibisected with win64-7.6 to 0558926c2f9201a12b4c46efc36b8a4080af4d46
use more officecfg for SvtMiscOptions

I noticed you might need to run in Safe Mode to see this.
Comment 1 Stéphane Guillou (stragu) 2023-07-09 20:42:46 UTC
Repro in:

Version: 24.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 77fca616e0bd79e0b405fd0b3543cf8e94e15df3
CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: threaded

No repro in:

Version: 7.5.4.2 (X86_64) / LibreOffice Community
Build ID: 36ccfdc35048b057fd9854c757a8b67ec53977b6
CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: threaded
Comment 2 m_a_riosv 2023-07-09 23:07:56 UTC
Not for me with
Version: 7.5.5.1 (X86_64) / LibreOffice Community
Build ID: 2c5e46c1980ec5241359fd65d751dc518205e7af
CPU threads: 16; OS: Windows 10.0 Build 22621; UI render: default; VCL: win
Locale: es-ES (es_ES); UI: es-ES Calc: threaded,
neither
Version: 24.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 77fca616e0bd79e0b405fd0b3543cf8e94e15df3
CPU threads: 16; OS: Windows 10.0 Build 22621; UI render: Skia/Raster; VCL: win
Locale: es-ES (es_ES); UI: en-US Calc: CL threaded
the bold and the size are copied.
Comment 3 ady 2023-07-09 23:37:14 UTC
Repro in safe mode _only_ (no repro in normal mode):

Version: 24.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: e4e5fb4b2935e395c7e4b3a794d544a6f44709ce
CPU threads: 4; OS: Windows 10.0 Build 19045; UI render: default; VCL: win
Locale: es-AR (es_AR); UI: es-ES
Calc: threaded
Comment 4 m_a_riosv 2023-07-09 23:38:28 UTC
I tested in both safe/normal mode, and not repro for me.
Comment 5 ady 2023-07-09 23:47:59 UTC
Is it possible that the problem presents itself in 7.6+ when the UI render is default (vs Skia/Raster)? It would seem strange, but that's one difference in the above results.
Comment 6 Buovjaga 2023-07-10 07:21:29 UTC
(In reply to ady from comment #5)
> Is it possible that the problem presents itself in 7.6+ when the UI render
> is default (vs Skia/Raster)? It would seem strange, but that's one
> difference in the above results.

No, I also see it with

Version: 24.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 81726f5af5fda25f0d92ffc8458d7f24eb16f408
CPU threads: 2; OS: Windows 10.0 Build 22621; UI render: Skia/Raster; VCL: win
Locale: en-US (en_FI); UI: en-US
Calc: threaded
Comment 7 Buovjaga 2023-07-10 08:14:41 UTC
I also noticed that if you test and repro, close the file, open again and do another test, you will not repro. So you have to close LibreOffice completely to be able to repro again.
Comment 8 ady 2023-07-10 09:57:28 UTC
(In reply to Buovjaga from comment #7)
> I also noticed that if you test and repro, close the file, open again and do
> another test, you will not repro. So you have to close LibreOffice
> completely to be able to repro again.

Hmm... Some kind of cache thingy?

Now I completely closed LO and open it to follow STR from comment 0: still no repro in normal mode. I have not re-tested in safe mode (which was already repro for me as I reported in comment 3).
Comment 9 Stéphane Guillou (stragu) 2023-08-08 21:45:23 UTC
I can also repro from a new file:

1. Open Calc
2. Write something in A1
3. Copy from cell or formula bar
4. Paste B1 without entering edit mode

Original is 10 points, pasted as 17.6 pt on a cell that has the default 10 pt.

Also reproduced with gen VCL.

I also see it starting with 0558926c2f9201a12b4c46efc36b8a4080af4d46 (commit 9c584e98f5658f58dc0348a1745c6f8512161155 in linux-64-7.6 bibisect repo)

Noel, can you please have a look?
Comment 10 Xisco Faulí 2023-08-09 08:38:57 UTC
Increasing importance
Comment 11 LeroyG 2023-08-09 19:48:32 UTC
No repro in:

Version: 7.5.3.2 (x86) / LibreOffice Community
Build ID: 9f56dff12ba03b9acd7730a5a481eea045e468f3
CPU threads: 4; OS: Windows 6.1 Service Pack 1 Build 7601; UI render: Skia/Raster; VCL: win
Locale: es-MX (es_MX); UI: es-ES
Calc: threaded

Repro in:

Version: 7.6.0.1 (x86) / LibreOffice Community
Build ID: 776eaf34564cbf3f034a0ba1fd1d5c32ff9ccf1c
CPU threads: 4; OS: Windows 6.1 Service Pack 1 Build 7601; UI render: Skia/Raster; VCL: win
Locale: es-MX (es_MX); UI: es-ES
Calc: threaded

1. Open a new spreadsheet.
2. Check the value in the font size field: 10 pt.
3. Write something in A1 (don't accept) and check the font size field: 17.6 pt.
4. Press Enter, and check the font size field: 10 pt.
5. Write something in A1 (don't accept) and check the font size field: 17.6 pt.
Comment 12 LeroyG 2023-08-09 19:55:15 UTC
(In reply to LeroyG from comment #11)
> Repro in:
> 
> Version: 7.6.0.1 (x86) / LibreOffice Community
> 
> 3. Write something in A1

Could be in whatever cell.

3. Write something in A1 (don't accept) and check the font size field: 17.6 pt.
4. Press Enter, and check the font size field: 10 pt.

5. Write something in C1 (don't accept) and check the font size field: 17.6 pt.
6. Press Enter, and check the font size field: 10 pt.

7. Write something in J9 (don't accept) and check the font size field: 17.6 pt.
8. Press Enter, and check the font size field: 10 pt.

After you accept (for all cells), in Edit mode or in the formula bar you will see 17.6 pt.
Comment 13 LeroyG 2023-08-09 19:57:12 UTC
No need to copy, so the title could be:
Different font size in edit mode and in non-edit mode
Comment 14 LeroyG 2023-08-09 20:10:09 UTC
(In reply to Buovjaga from comment #7)
> I also noticed that if you […] close the file, […] and do
> another test, you will not repro. So you have to close LibreOffice
> completely to be able to repro again.

Only reproducible on the first document, be it new or opened.
Comment 15 Commit Notification 2023-08-11 07:59:35 UTC
Noel Grandin committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/5484657d2b1677b7e385ab6ef87ad64dcb9934e4

tdf#156209 Font size increases when copying from cell in edit mode

It will be available in 24.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 16 Commit Notification 2023-08-14 12:50:15 UTC
Noel Grandin committed a patch related to this issue.
It has been pushed to "libreoffice-7-6":

https://git.libreoffice.org/core/commit/6cd9e7acb9b3347878e1ca4d74734d53012375de

tdf#156209 Font size increases when copying from cell in edit mode

It will be available in 7.6.1.

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 17 Luc 2023-08-27 08:19:40 UTC
I confirm the fix works OK.

Also, there is no need to do a copy / paste operation to trigger this issue, see bug 156932 for more details (especially on how bad it is for cells with multiple lines of text).
Comment 18 Buovjaga 2023-08-27 10:33:31 UTC
*** Bug 156932 has been marked as a duplicate of this bug. ***
Comment 19 BogdanB 2023-09-02 12:16:27 UTC
*** Bug 157048 has been marked as a duplicate of this bug. ***
Comment 20 cress1 2023-09-02 17:07:01 UTC
The patch works well.