Bug 95239 - Wrong ToC in Navigator and PDF when using frames
Summary: Wrong ToC in Navigator and PDF when using frames
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium minor
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Navigator PDF-Export Frame
  Show dependency treegraph
 
Reported: 2015-10-21 23:01 UTC by Joaquim Pedro França Simão
Modified: 2023-02-09 16:34 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
ODT file with headings and wrong ToC in Navigator (15.72 KB, application/vnd.oasis.opendocument.text)
2015-10-21 23:01 UTC, Joaquim Pedro França Simão
Details
PDF created from example ODT, with wrong bookmark structure (21.25 KB, application/pdf)
2015-10-21 23:02 UTC, Joaquim Pedro França Simão
Details
how TOC appears for the ODT test file (6.13 KB, image/png)
2023-02-09 16:34 UTC, sdc.blanco
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Joaquim Pedro França Simão 2015-10-21 23:01:42 UTC
Created attachment 119857 [details]
ODT file with headings and wrong ToC in Navigator

If I set some headings inside a frame, the ordering on Navigator window is wrong, including on PDF export, but a generated Table of Contents (ToC) in Writer is correct.

Expected behaviour:
The ToC entries in the Navigator window and the PDF bookmarks on the exported document are with the correct heading tree structure.

Current behaviour:
LO puts all sub-headings inside the last top-heading.

Steps to reproduce:
- create new writer document;
- insert a Frame
- insert some text inside the newly created frame, assign "Heading 1" style;
- outsite the frame, insert some text and assign "Heading 2" style;
- insert another paragraph, assign "Text Body" style;
- insert another frame and repeat the previous steps.

- export as PDF, make sure that the "Export Bookmarks" option ("General" Tab, section "General") is active;
- the resulting PDF has all the "Heading 2" entries under the last "Heading 1" inserted.

See the attached odt and the exported PDF.
Comment 1 Joaquim Pedro França Simão 2015-10-21 23:02:29 UTC
Created attachment 119858 [details]
PDF created from example ODT, with wrong bookmark structure
Comment 2 Buovjaga 2015-10-24 15:49:24 UTC
Confirmed.

Win 7 Pro 64-bit, Version: 5.0.2.2 (x64)
Build ID: 37b43f919e4de5eeaca9b9755ed688758a8251fe
Locale: fi-FI (fi_FI)

LibreOffice 3.5.0rc3 
Build ID: 7e68ba2-a744ebf-1f241b7-c506db1-7d53735
Comment 3 QA Administrators 2016-11-08 11:20:23 UTC Comment hidden (obsolete)
Comment 4 Mike 2018-08-03 04:51:33 UTC
Confirmed

Version: 6.1.0.2 (x64)
Build-ID: b3972dcf1284967612d5ee04fea9d15bcf0cc106
CPU-Threads: 4; BS: Windows 10.0; UI-Render: Standard; 
Gebietsschema: de-DE (de_DE); Calc: group threaded
Comment 5 QA Administrators 2021-01-30 04:17:41 UTC Comment hidden (obsolete)
Comment 6 Joaquim Pedro França Simão 2021-02-03 23:47:18 UTC
Still exists in latest Version: 7.1.0.3 (x64) / LibreOffice Community
Build ID: f6099ecf3d29644b5008cc8f48f42f4a40986e4c
CPU threads: 12; OS: Windows 10.0 Build 19042; UI render: Skia/Vulkan; VCL: win
Locale: pt-BR (pt_BR); UI: pt-BR
Calc: CL


And reproduced in BrOffice 3.3.0 OOO330m19 (Build:6) tag libreoffice-3.3.0.4
Comment 7 QA Administrators 2023-02-04 03:20:04 UTC Comment hidden (obsolete)
Comment 8 sdc.blanco 2023-02-09 16:34:00 UTC
Created attachment 185268 [details]
how TOC appears for the ODT test file

I believe the Navigator part of the issue was fixed with bug 143569.

I did not test the PDF part.  Bug 143569 also mentions a PDF problem. If that issue still remains, then maybe this bug summary can be adjusted to highlight the PDF issue.

Also....

(In reply to Joaquim Pedro França Simão from comment #0)
> but a generated Table of Contents (ToC) in Writer is correct.
I have attached a screenshot of what happens when I make a TOC using the file in When I opened attachment 119857 [details] in LO 7.2.7.2 and 7.6.0.0.alpha0+.

It does not look right to me.  The Outline Level 1 headings (in the Frames) appear after the Outline Level 2 headings.