SUMMARY Not every pdf file/epub shows a table of contents in okular. For example I saved a google doc that had a table of contents to pdf then opened in okular. There was no table of contents in the file. Opening the pdf with calibre ebook viewer shows part of the table of contents. Saving the same document to epub. The entire table of contents is shown in calibre ebook reader (understandably). However the table of contents still was not shown in okular. In conclusion, there seem to be hiccups for some pdf and epub files in okular when it comes to the table of contents. STEPS TO REPRODUCE 1. Generate pdf or epub that contains a table of contents from google docs. 2. Open with okular 3. Look to see if table of contents section is shown OBSERVED RESULT No section containing table of contents. EXPECTED RESULT Table of contents rendered allowing for easy navigation of long files. SOFTWARE/OS VERSIONS Operating System: openSUSE Tumbleweed 20200919 KDE Plasma Version: 5.19.5 KDE Frameworks Version: 5.74.0 Qt Version: 5.15.1 Kernel Version: 5.8.7-1-default OS Type: 64-bit Processors: 4 × Intel® Core™ i7-7500U CPU @ 2.70GHz Memory: 15.4 GiB of RAM Graphics Processor: Mesa DRI Intel® HD Graphics 620
Okular doesn't generate table of contents, will only show one if the document has one by itself.
(In reply to Albert Astals Cid from comment #1) > Okular doesn't generate table of contents, will only show one if the > document has one by itself. Generate was the wrong word here. The documents I am referring to do already have table of contents by themselves that okular is not showing.
(In reply to Albert Astals Cid from comment #1) > Okular doesn't generate table of contents, will only show one if the > document has one by itself. Changed the title to more accurately reflect the problem
Please attach such a document
Created attachment 131904 [details] Document in epub format This is the online notes in the form of a condensed book for my cryptography class. This is one in epub format. Next I will upload the same document in pdf format.
Created attachment 131905 [details] Document in pdf format
(In reply to Albert Astals Cid from comment #4) > Please attach such a document I have attached the documents in question.
ToC for cannot be shown in FoxIt Reader and PDF-XChage as well. Can you explicitly name the application that can show the ToC? ePub contains a separate ToC in nav.xhtml which seems confusing parsing.
(In reply to Yuri Chornoivan from comment #8) > ToC for cannot be shown in FoxIt Reader and PDF-XChage as well. Can you > explicitly name the application that can show the ToC? > > ePub contains a separate ToC in nav.xhtml which seems confusing parsing. I used calibre ebook-viewer to open the pdf file as well as I mentioned in my summary. Also as mentioned before, it shows a part of the ToC
That PDF file does not have any table of contents.
(In reply to Albert Astals Cid from comment #10) > That PDF file does not have any table of contents. Alright thanks for looking. Seems I must have been mistaken.
The epub file defenitely contains a table of contents. reopening the bug. (In reply to Yuri Chornoivan from comment #8) > ToC for cannot be shown in FoxIt Reader and PDF-XChage as well. Can you > explicitly name the application that can show the ToC? > > ePub contains a separate ToC in nav.xhtml which seems confusing parsing. the problem with the parsing seems to be that the toc is inside the manifest and not as an attribute of the spine like the ebook-tools code expects it to be. Unfortunately ebook-tools seems to be dead, with the last commit more than 6 years ago https://sourceforge.net/p/ebook-tools/code/log/ Also discussed in the last team meeting was potential dropping epub support since our support is kind of lacking, not totally decided, but a probability