Bug 163883 - Lost Paragraph Styles when copying Impress Outline into Writer Outline since version 24.8.2.1
Summary: Lost Paragraph Styles when copying Impress Outline into Writer Outline since ...
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
24.8.2.1 release
Hardware: All All
: medium normal
Assignee: Miklos Vajna
URL:
Whiteboard: target:25.2.0 target:24.8.4
Keywords: bisected, regression
Depends on:
Blocks:
 
Reported: 2024-11-13 15:10 UTC by Michael G
Modified: 2024-11-19 12:51 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
The odt file as formatted when made with an older version, with each writer style aligned with the Impress level (34.91 KB, application/vnd.oasis.opendocument.text)
2024-11-13 15:12 UTC, Michael G
Details
anomalyimage (1.98 KB, image/jpeg)
2024-11-13 16:40 UTC, Henry G.
Details
Minimal reproducer (13.79 KB, application/vnd.oasis.opendocument.presentation)
2024-11-15 16:05 UTC, Miklos Vajna
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Michael G 2024-11-13 15:10:54 UTC
Description:
Until the last update (now version 24.8.2.1), I could copy Impress 'Outline' into Writer and the styles of each line of the outline would be also copied. Now everything is pasted into Writer with the same 'default' style, instead of keeping, for each line, the specific style name that was in Impress. → When I ‘clear direct formatting’ (and if I do not, then I have the Slides formatting, not very nice in a text document), everything becomes formatted to ‘default text’ rather than specific lines.

I therefore can no longer quickly create an text outline of my slide contents for my students. 

Version: 24.8.2.1 (X86_64) / LibreOffice Community
CPU threads: 14; OS: Windows 11 X86_64 (10.0 build 26100); UI render: Skia/Raster; VCL: win
Locale: fr-CH (fr_CH); UI: fr-FR
Calc: CL threaded

Steps to Reproduce:
1.Go to ‘outline’ view of Impress
2.Select all text and Copy
3.Open a Writer document (specific model which had specific styles having the same name as the styles in Impress)
4.Paste the text in Writer
5.Press ‘Clear Direct Formatting’
→ Before last update I then had a clean outline for my students, as each line imported from Impress would be formatted according to its level (title, Level 1, level 2 etc.) based on the pre-defined style in Writer (the ‘paste’ function would import the style name from Impress, and I had corresponding styles in Writer). (example file in the 'ask' section, entry with same title as this one).

Actual Results:
Now everything is formatted according to the same 'default' writer style

Expected Results:
Each paragraph would be formatted according to the Writer paragraph style corresponding to the name it had in Impress. 


Reproducible: Always


User Profile Reset: No

Additional Info:
Apparently "This is a regression after a fix to tdf#161652. It was intended to avoid copying the unused styles; but obviously, it also drops the used ones."

A Writer file example of what was happening BEFORE update in: 
https://ask.libreoffice.org/t/lost-paragraph-styles-when-copying-impress-outline-into-writer-outline-since-version-24-8-2-1/113820
Comment 1 Michael G 2024-11-13 15:12:51 UTC
Created attachment 197595 [details]
The odt file as formatted when made with an older version, with each writer style aligned with the Impress level
Comment 2 Henry G. 2024-11-13 16:40:08 UTC
Created attachment 197599 [details]
anomalyimage

Hello, I believe I was able to reproduce what you describe. The formatting is completely cleared when I press "clear direct format". In your attached example, nothing would go to default in Writer.

Version: 24.8.2.1 (X86_64) / LibreOffice Community
Build ID: 0f794b6e29741098670a3b95d60478a65d05ef13
CPU threads: 8; OS: Windows 10 X86_64 (10.0 build 19045); UI render: Skia/Vulkan; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: threaded
Comment 3 Regina Henschel 2024-11-13 19:25:38 UTC
Yes, all styles are direct formatting in Writer. In version 7.6, there had been paragraph styles.
Comment 4 zcrhonek 2024-11-15 07:56:08 UTC
See Mike Kaganski's answer: This is a regression after a fix to tdf#161652.

Adding CC to  Miklos Vajna
Comment 5 Miklos Vajna 2024-11-15 08:08:59 UTC
Aha, copying the info here from the ask site: this was bisected to 70d1bd6ee0eba9d6661cd6280566f77a87f2d068 (tdf#161652 editeng, RTF copy: only write used paragraph styles, 2024-06-20), thanks for the CC.
Comment 6 Miklos Vajna 2024-11-15 16:05:21 UTC
Created attachment 197634 [details]
Minimal reproducer

Open this, switch to outline view, select all, copy, create a new Writer document, paste, the first para should have a custom para style, but it doesn't have that.

I'll take a look.
Comment 7 Commit Notification 2024-11-19 09:07:17 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "master":

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

tdf#163883 editeng RTF export: fix broken offsets into the para style table

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 8 Commit Notification 2024-11-19 10:37:30 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "libreoffice-24-8":

https://git.libreoffice.org/core/commit/5417dbf339b3e66db38786d922c2294ae40f824e

tdf#163883 editeng RTF export: fix broken offsets into the para style table

It will be available in 24.8.4.

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.