Bug 170311 - CALC - Text over multiple lines in merged cell is not copied to other merged cell
Summary: CALC - Text over multiple lines in merged cell is not copied to other merged ...
Status: UNCONFIRMED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
25.8.4.2 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2026-01-12 15:50 UTC by BDF
Modified: 2026-01-16 20:50 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
CALC - bug 170311 - new line in merged cell - test file (9.36 KB, application/vnd.oasis.opendocument.spreadsheet)
2026-01-12 15:50 UTC, BDF
Details
CALC - bug 170311 - new line in merged cell - video (1.05 MB, video/webm)
2026-01-12 15:51 UTC, BDF
Details

Note You need to log in before you can comment on or make changes to this bug.
Description BDF 2026-01-12 15:50:10 UTC
Description:
(a) When you copy text from one merged cell and paste it into another, only the first line is kept.
If you paste the text into the edit line above the cells, the second line is (b) pasted, but in the same line as text of the first line or (c) is kept in multiple lines.

Steps to Reproduce:
1. Merge two cells (source)
2. Merge two other cells (target)
3. Create text in source cell (eg. test<NEWLINE with Ctrl + Enter>test)
4. Copy the only text (F2 + Select all text + Ctrl+C)
5. Paste the text either (a) in the target cell with Ctrl + V or (b) the edit line above the cells with Ctrl + V
(6.) Paste the text (c) in the edit line above the cells with Ctrl + Shift + V

Actual Results:
(a - paste text in target cell with Ctrl + V) Only the first line is kept
(b - paste in edit field above cells with Ctrl + V) Both lines are kept, but in one line
(c - paste in edit field above cells with Ctrl + Shift + V) Both lines are kept in two lines

My guess is that if cell A1 and A2 are merged, LibreOffice just puts information into A2 which is just not displayed and therefore the text 'vanishes'.

Expected Results:
Expected result is that both lines are inserted in the target cell as they were in the source cell (with the text in two lines) no matter how (Ctrl+V/Ctrl+Shift+V) I insert the text.

I wouldn't expect a different bahaviour between Ctrl + V and Ctrl + Shift + V (why is it inserting the new line with the second one, but not the first one if I only copied _text_ anyway?).


Reproducible: Always


User Profile Reset: No

Additional Info:
If you do (a) with regular (= not merged) cells the text end up in two cells below each other ("test1<NEWLINE>test2" would result in "test1" in A1 and "test2" in A2).
If you do (b) with regular (= not merged) cells the text is pasted like in the example above: Both lines end up in one line.
If you do (c) with regular (= not merged) cells the text is pasted like in the example above: The text ends up in two lines

--------------------------------------------------

I can see why you would copy text in multiple lines into a sheet. When you think about editing values/entries in a different program, splitting the text into cells by newline makes more sense than having the entire text in one cell with multiple lines. Though pasting multiple lines into one cell could also be the target in some workflows. I can't think of any reason why I would want to have multiple lines pasted into one row, but there might be an application for this as well.
However, I think this should be narrowed down to one or two different types (Ctrl+V / Ctrl+Shift+V) as this is quite confusing why it should work that way. To understand what is going on I spend like an 1-1.5 hours testing. No sane user would spend that much time on a feature like this. They would default to "this does not work!"

--------------------------------------------------
--------------------------------------------------

Same bahaviour on Linux as well as Windows.

1) Linux
Version: 25.8.4.2 (X86_64) / LibreOffice Community
Build ID: 290daaa01b999472f0c7a3890eb6a550fd74c6df
CPU threads: 12; OS: Linux 6.14; UI render: default; VCL: gtk3
Locale: de-AT (de_AT.UTF-8); UI: de-DE
Flatpak
Calc: threaded

2) Windows
Version: 24.2.6.3_AA (X86_64) / LibreOffice Community
Build ID: 23735e228767740599e3f00b9371b05bcbf243d2
CPU threads: 4; OS: Windows 10.0 Build 19045; UI render: default; VCL: win
Locale: de-AT (de_AT); UI: de-DE
Calc: threaded
Comment 1 BDF 2026-01-12 15:50:51 UTC
Created attachment 205022 [details]
CALC - bug 170311 - new line in merged cell - test file
Comment 2 BDF 2026-01-12 15:51:20 UTC
Created attachment 205023 [details]
CALC - bug 170311 - new line in merged cell - video

A video about for the description showing (a), (b) and (c)
Comment 3 m_a_riosv 2026-01-13 04:03:48 UTC

*** This bug has been marked as a duplicate of bug 158751 ***
Comment 4 BDF 2026-01-13 08:08:22 UTC
(In reply to m_a_riosv from comment #3)
> 
> *** This bug has been marked as a duplicate of bug 158751 ***

They are not the same bug.

One is a visual bug where only half of the text is displayed (but the text exists in the cell).
This bug is about that the text is not even placed into the cell in the first place.

Also bug 158751 is no repo for me so it can't be the same bug.
Comment 5 raal 2026-01-16 19:13:58 UTC
(In reply to BDF from comment #0)
> Description:
> Actual Results:
> (a - paste text in target cell with Ctrl + V) Only the first line is kept

Unmerge the cell and you can see the second line is pasted.
Comment 6 BDF 2026-01-16 20:50:21 UTC
(In reply to raal from comment #5)
> (In reply to BDF from comment #0)
> > Description:
> > Actual Results:
> > (a - paste text in target cell with Ctrl + V) Only the first line is kept
> 
> Unmerge the cell and you can see the second line is pasted.

I already noticed that after I posted test file.
Yet this is not the expected bahaviour (at least for me)