Re: PDF alternative (was Announcing Project Mortar)
[email protected] Mon, 3 Oct 2016 09:48:40 -0700 (PDT)
| Newsgroups | gmane.comp.mozilla.devel.seamonkey |
|---|---|
| Message-ID | <[email protected]> |
Hi Mark, I also worry about a "XKCD 927", and I spent a lot of time evaluating each of the existing formats because of that. Overall, none of them address the security, accessibility, or the ease of which the documents can be created/distributed. And while I did discuss this with the W3C a while ago, they were too focused on creating their own "new standards" (e.g. PWP), all of which have their uses, but didn't actually address the problems in PDF. I did also had an interesting discussion with someone at Adobe (under NDA), and they are looking at something very similar to this (but also more complicated). The justification about this file format is at the following URL: https://github.com/craigfrancis/wdoc And in response to your suggestions (which I appreciate), I've described why they unfortunately don't work below. Craig XPS, aka "Open XML Paper Specification", is a complete XML document format (kind of like OpenDocument and OpenXML), which does get packaged into a ZIP, but requires a ~300 page specification, and uses an XML schema that's unique to it. If you download one of these files from the web, the browser (e.g. Firefox) is not going to be able to display it's contents. And anyone who wants to create an XPS file will either need to learn the specification, or get a program to convert a source document into this format. It also, like PDF, does not support things like media queries, so you have no chance of styling the document to better display on a small screen. Mobi, Epub, and PWP are focused on books, and are seen by consumers as a file format for publications (not so much reports), where they get saved and opened in their eReaders. These file formats also require extra information such as a manifest file, and certain elements like a table of contents (not good for a single page document). Overall these formats focus on pages of text, rather than anything designed (it can be done, but it's difficult), where they do this to provide features like changing the font, text size, background colour, etc. HTML/CSS itself, yes, this is what I want - but you cannot simply email a HTML file to someone (even if you inline the CSS/JS/Images). My proposal is simply to use HTML/CSS, but take away the pain of inlining the resources (by simply including them in a ZIP), and applying some restrictions on the document for security reasons (e.g. it must not be allowed to make a request out to the internet, as these are supposed to be atomic/unchanging documents). MHTML, is also kind of what I'm after - but it's not really implemented in Firefox, the documents are very difficult to create (basically an email format, that inlines the resources), it does not apply any restrictions to the content (so it can make connections to the internet, maybe to download new content, which is a very bad thing), it does not compress the content, and you cannot password protect the documents. WebArchive, like MHTML, but uses a binary plist file format... so even harder to create. MAFF, aka "Mozilla Archive Format", like MHTML but better, in that it uses ZIP (so it's easier to create files in this format). But I believe it's only supported in the "Mozilla Archive Format" extension, and I believe it does not apply any restrictions on the file when opening it (must admit, it was over a year ago when I looked at this file format). On Monday, 3 October 2016 16:49:36 UTC+1, Mark Rousell wrote: > On 03/10/2016 09:43, [email protected] wrote: > > On Sunday, 2 October 2016 23:27:51 UTC+1, Nicholas Nethercote wrote: > >>> Although viewing PDFs in the browser is useful, PDFs are not a fundamental part of the web. > > > > Bit of a tangent... PDF's are important for the web, but they are very problematic (e.g. try reading an A4 formatted PDF on a small screen). > > > > If any developers implementing PDF in Firefox are on this list, I would like to discuss how we can move away from PDF's, possibly creating a simple alternative which allows for a HTML/CSS based document to replicate many of PDF's strengths: > > Wouldn't this be a case of re-inventing the wheel? Multiple formats that > address this use case quite well (albeit from different perspectives) > already exist: XPS, Mobi, Epub, potentially HTML/CSS itself, as well as > the two web archive formats below. > > > https://bugzilla.mozilla.org/show_bug.cgi?id=1237990 > > This is 'Webpage ZIP as alternative to PDF' but two entrenched formats > already exist to do an equivalent: MHTML (RFC2557) and MAFF > <http://maf.mozdev.org/maff-specification.html>. > > I accept that there is no existing format that is precisely the > equivalent of PDF but using HTML/CSS and Zips but, as above, there seem > to be so many existing formats (and, crucially, they are well-supported > formats) that cover what one might want to do with a theoretical new > format in this context that creating a new format and persuading people > to use it seems likely to be a wasted effort. It's risking XKCD 927 > <http://www.xkcd.com/927/>. > > > -- > Mark Rousell