View Single Post
Old 04-27-2020, 11:24 AM   #19
Shohreh
Addict
Shohreh ought to be getting tired of karma fortunes by now.Shohreh ought to be getting tired of karma fortunes by now.Shohreh ought to be getting tired of karma fortunes by now.Shohreh ought to be getting tired of karma fortunes by now.Shohreh ought to be getting tired of karma fortunes by now.Shohreh ought to be getting tired of karma fortunes by now.Shohreh ought to be getting tired of karma fortunes by now.Shohreh ought to be getting tired of karma fortunes by now.Shohreh ought to be getting tired of karma fortunes by now.Shohreh ought to be getting tired of karma fortunes by now.Shohreh ought to be getting tired of karma fortunes by now.
 
Posts: 217
Karma: 304158
Join Date: Jan 2016
Location: France
Device: none
I had an idea: Considering PDF should display plain text just fine on an e-reader, and only some parts/pages won't because of more complex layout… an easier alternative to trying to use Caliber to convert a PDF into EPUB through poppler, is to use LibreOffice to edit just the pages/parts that don't work, and rebuild a PDF.

1. Save each page as a single PDF:

Code:
qpdf --progress --split-pages infile.pdf %d.pdf
2. In LibreOffice Draw, open and edit each problematic page to replace all nasty parts (remove/rewrite insets and multi-column text, replace tables with just screenshots that fit your e-reader, eg. 768x1024 pixels). While you're at it, use a regex to remove the headers/footers and page numbers

3. Merge all the pages back into a single PDF:

Code:
qpdf --empty --pages *.pdf -- out.pdf
Shohreh is online now   Reply With Quote