Ask HN: Why has PDF not been replaced with HTML5?
Perhaps the answer is very obvious, but why is it that PDF has not been replaced by the HTML5 format for most on-device documents outside of programming?
Take for instance, company annual reports and pitch slides - you could make the usage of charts and data objects a whole lot more insightful by just giving the option to interact with the charts and choose your data selectively. The same goes for research papers - a small visual gif or video component would go a long way to show things compared to a series of sequential images, as would interactive charts - even the simple ones that you get from Excel.
17 comments
[ 3.3 ms ] story [ 49.1 ms ] thread"Based on the PostScript language, each PDF file encapsulates a complete description of a fixed-layout flat document, including the text, fonts, vector graphics, raster images and other information needed to display it." Source: https://en.wikipedia.org/wiki/PDF
HTML5 was not designed for typesetting and lacks such features. (For example, HTML does not specify page sizes.)
That is precisely my question! With increasing prevalence of documents being processed online, why hasn't it been the case that the HTML5 option appears as prevalent as the PDF option in say research articles? I guess a complete phase-out of PDF is not currently possible, but the provision of HTML5 alongside PDF should definitely be possible? I found some online options to convert Word documents to HTML5 too so it's clearly not technically impossible, is it?
It's also "fixed" - ie, probably as close to a WYSIWYG format as has ever been created (so far)
HTML5 is ice ... but it's not a 1-for-1 replacement/equivalent
Many research articles appear in printed journals. If a research publication uses online distribution rather than a printed journal, then perhaps HTML would make more sense.
Traditionally research papers have been distributed as printed magazines and volumes, so PDF has been a common interchange format.
>> I guess a complete phase-out of PDF is not currently possible, but the provision of HTML5 alongside PDF should definitely be possible?
Yes. It in most cases it should be possible, it depends on the use case, target audience, and perhaps the traditions surrounding what is being published.
>> I found some online options to convert Word documents to HTML5 too so it's clearly not technically impossible, is it?
Probably not. It depends on how the documents are originally written and the "expressiveness" of the documents needs. Many research articles are written using TeX or LaTeX (https://en.wikipedia.org/wiki/LaTeX) which, like PDF, was designed for typesetting.
Microsoft Word and most similar modern word processing software will export to both HTML and PDF. Most LaTeX-based systems also support HTML and PDF output. Other word processing and document preparation software may have a range of output and exporting options depending on what it was designed for.
It is more a question of what the target medium (web publishing, printing, ebook formats, etc.) is and what publishing format best fits the document's needs.
So I guess it's a matter of preference and medium too, although I felt that were an "HTML5 style" PDF possible, it would have been extremely useful in the fields I've published in. It's certainly better than filling up the page or the slide with a bunch of PNGs.
>a small visual gif or video component would go a long way to show things compared to a series of sequential images
Tell me how a small GIF or video is going to work when you print a paper or collect it into a book or journal, please :)
--------
[0] https://news.ycombinator.com/item?id=33787463
It may even be desirable overall
But physical copies of papers, books, etc have a major place in peoples' lives (and will for beyond the foreseeable future) :)
...and gov't forms aren't going to have embedded videos or GIFs ;)
It seems everyone around me (in the developed world) is using a tablet or an iPad or a laptop to read a document, with very little work printed out. I would argue that quite a few government forms for newly created agencies and even tax havens have migrated from plain PDF to forms with embedded JS, for buttons, etc. And with each passing year, books seem to have lesser impact in my life as well as that of my peers - most reading is done on a very portable tablet or desktop. Most reading that is done with a paperback is casual and light. And of course, reading seems to be a dying habit these days.
So sad to hear you and your peers aren't spending reading time with physical copies more! I read more on a screen than physical books/papers/magazines, but appreciate physical copies more with every passing day ...the ability to hand something to someone and tell them "you should read this" is amazing! As is the ability to give/sell what I no longer want ... and to buy what isn't available electronically
Electronic resources are all well and good ... but they lack permanence
For lots of stuff, that's fine
But for something you want/expect to last more than a few hours, week, or years, it's not
I'd much rather augment a physical book with electronic resources (be it a website, QR-linked video, AR, or something not yet invented) than to rely exclusively on ethereal data whose formats are superceded on a frequent basis
My next question is that why isn't it possible to agree to a standard presentation of prose and equations for HTML5 which mirrors a clean PDF-style presentation as much as possible (as is done with LateX), but I guess the answer to that is within that xkcd comic about standards.
PDF works great on the web; we don’t need to force HTML to replicate its abilities. It already has hyperlinks, and we can seemlessly navigate bewteen PDF and HTML pages in the browser.
[1] https://github.com/coolwanglu/pdf2htmlEX