Are there plans for okular to have a reflow text function?

On a screen, text in .pdf files often looks small and has long lines, both making for hard reading. When this is a problem my solution is to convert the document to .epub and then open it in Calibre. Is there any intention of having a Reflow function in okular?

Thank you.

I can’t say whether this is under any consideration by devs, but I will say that it’d be a big ask.

PDF format is really geared towards precise visual layout. Text content that exists in the source file (when it actually is text, and not an image of some text or a bunch of vector graphics that used to be text) does not necessarily exist in nice contiguous paragraphs. Sometimes each line is its own distinct object within the file; sometimes the order sections of text appear on the rendered page bears no relation to their ordering in the source. Point being, Okular would need to make a heck of a lot of educated guesses about how it should render the text it finds in a document. In this day and age, its most reliable approach might be to internally render the page, snapshot it, and run OCR to recover the text and decide how to organise it into a dynamic document that could be reflowed.

And that’s before you get into all the additional content elements you might find in any given PDF: images, page furniture such as headers, numbering and so on … form controls(!)

It’d be a lot of ground to try to cover, is my point. Out of interest, what do you use for the .epub conversions you do? I’m kinda interested to see how it handles a few examples.

2 Likes

I’m sure it’s not trivial, but others do it so it was worth asking. I use Calibre to do the conversion to .epub

1 Like