3 ms·
More. Go here and download the PDF spec.: https://www.adobe.com/devnet/pdf/pdf_reference.html https://www.adobe.com/devnet/pdf/pdf_reference.html Look at Chap
by mkl 6y ago
More. Go here and download the PDF spec.: https://www.adobe.com/devnet/pdf/pdf_reference.html https://www.adobe.com/devnet/pdf/pdf_reference.html
Look at Chapter 3, Syntax. The code is all text based. We are not talking about the visible characters in a PDF viewer, but the code of the PDF file itself.
- deleted 6y ago[deleted]
- roflc0ptic 6y agoOh, true. I misread, and also didn't know that. Thanks for the info!
- hnick 6y agoGoing by your original premise though, just so you know the reference does indeed have examples of text as strings e.g. BT /F13 12 Tf 288 720 Td (ABC) Tj ET This can be extended to include spaces so you can essentially mark up entire lines of text at one time. What it can't do is cohesive paragraphs and flow/wrap, you need to use the relative positions to work out what text is in one block (and usually I'd defer to something like pdftotext for simple cases). Laying out individual characters is common though. It's probably due to kerning concerns.