Re:Borb – A Python library to read, write, and edit PDF files
by maxerickson on Saturday September 18, 2021 @10:44AM
(#28576649)
Postscript files are often rendered into PDF, but PDF doesn't use postscript.
[ Parent
| on HN ]
Re:Borb – A Python library to read, write, and edit PDF files
by Syzygies on Saturday September 18, 2021 @04:17PM
(#28578948)
See dunham's answer. Anyone who has seen a PDF file in text form would swear they're looking at Postscript. There's a common intersection that's identical.
Very roughly speaking (this is a semantic debate where everyone is wrong from someone else's perspective), a PDF file is a restricted subset of Postscript, with added indexes so one can render pages in the middle without having to process the code from the beginning.
The hardship in generating PDFs from scratch is getting those indexes right. It's far easier to convert a Postscript file using standard tools.
Re:Borb – A Python library to read, write, and edit PDF files
by maxerickson on Sunday September 19, 2021 @03:09PM
(#28587004)
That's fair. I was waffling about using stronger language, "pdf isn't postscript", but didn't get there. It would have been more correct.