Live data from Hacker News

Firefox introduces PDF viewer

blog.mozilla.org

71–80 of 200 posts

Re: Firefox introduces PDF viewer

#71
post #21
post #13

Earlier quoted context omitted.

Please take your time machine and go release PDF.js in early 2010. With good performance on the hardware and Javascript VMs of early 2010. Then I'll grant you the criticism of Chrome's PDF viewer. Otherwise, trolling... fact is, Chrome is the browser that liberated the world from Acrobat Reader. PDF.js is awesome and it may be the way to go, but as of today Chrome's viewer is still much better -- please try http://ww…

On the mac, Firefox Nightly loads the PDF in a second while Google Chrome Dev loads in about three seconds. I can enter text in the pdf in Chrome while Firefox gives an annoying little "The pdf might not be rendered perfectly" error bar at the top. Let's try Safari: Loads in under a second maybe even faster, super quick scrolling, ability to enter text and the option to download the pdf on the bottom. This is the way…

PDF performance is great on the Mac because Apple's 2d drawing system is actually based on the PDF spec. You can even "print" to a pdf from just about any Mac application that supports printing.

http://en.wikipedia.org/wiki/Quartz_2D

Re: Firefox introduces PDF viewer

#73
post #64
post #31

Earlier quoted context omitted.

I thought one of the safety features of some pdf readers was the ability to disable javascript. How does that work here if this is entirely implemented in javascript? Disregard if I'm not understanding this correctly.

Different layers of abstraction. JavaScript embedded in a PDF probably turns up as a string after being parsed. It doesn't necessarily get eval'ed. It's turtles all the way down, until you say no.

Let's hope there is the option to say no otherwise this couldn't be considered a general purpose viewer by some.

Re: Firefox introduces PDF viewer

#75
post #29

It's nice to have such an option, but it feels significantly less snappy than Kparts plugin in KDE which wraps Okular into Firefox.

True, as with plain Adobe Reader. I spend a large part of my day reading .PDFs, both in and out of my browser, and Firefox became a much less effective "power tool" when they took the liberty of disabling the Reader plugin. I couldn't care less how long it takes to load a .PDF -- snappy rendering and navigation is everything, and you don't get that from JavaScript. It took a surprising (to me) amount of hacking to re…

I don't know what you did, but i can easily change that by changing the default action for PDF files in preferences -> Applications.

I've been using PDF.js myself for i think a year now (Used to install it directly from their Github page), and it's a great reader if you aren't an heavy PDF user. I barely have to open a PDF, and when i do it's usually just text and images, not any fancy stuff. And i guess most computer users are just like me. If you open PDFs all day, and are a power user, i guess that nothing can replace a good standalone reader.

It's still kinda slow, but it has done some incredible progresses in the year i've been using it. And i'm sure it will just get better and better.

Re: Firefox introduces PDF viewer

#76
post #35
post #21

Earlier quoted context omitted.

On the mac, Firefox Nightly loads the PDF in a second while Google Chrome Dev loads in about three seconds. I can enter text in the pdf in Chrome while Firefox gives an annoying little "The pdf might not be rendered perfectly" error bar at the top. Let's try Safari: Loads in under a second maybe even faster, super quick scrolling, ability to enter text and the option to download the pdf on the bottom. This is the way…

To be sure, Safari is invoking a system level PDF reader to handle inline PDFs. That's what gets you that silky performance and nice rendering. When you pop the PDF out, it then gets passed to the full Preview.app.

>> To be sure, Safari is invoking a system level PDF reader to handle inline PDFs. That's what gets you that silky performance and nice rendering.

Which, IMO, is the way it should be, and not just for PDFs. I'm impressed by the fact that Mozilla implemented a capable PDF reader in JavaScript, but I won't be using it. Firefox and Chrome are both trying too hard to duplicate everything my OS already provides: their own video codecs, audio codecs, image codecs, the Flash plugin (Chrome), now a PDF viewer, and so on. I'd rather just have my browser render HTML/CSS, run JavaScript, and that's about it. It doesn't have to implement anything else itself, all modern OS's should have everything required to display all the embedded content.

Re: Firefox introduces PDF viewer

#77
post #21

Earlier quoted context omitted.

On the mac, Firefox Nightly loads the PDF in a second while Google Chrome Dev loads in about three seconds. I can enter text in the pdf in Chrome while Firefox gives an annoying little "The pdf might not be rendered perfectly" error bar at the top. Let's try Safari: Loads in under a second maybe even faster, super quick scrolling, ability to enter text and the option to download the pdf on the bottom. This is the way…

PDF performance is great on the Mac because Apple's 2d drawing system is actually based on the PDF spec. You can even "print" to a pdf from just about any Mac application that supports printing. http://en.wikipedia.org/wiki/Quartz_2D

just a note, but you can do that in linux and afaik windows as well

Re: Firefox introduces PDF viewer

#78
post #13
post #9

It's worth pointing out this is done in pure Javascript , and works by compiling PDF functions to equivalent Javascript functions which are then visible to Firefox's JIT. Despite being only around a year old, it still manages to render the majority of PDFs thrown at it (it's been my primary paper reader for the past 6 months or so). As for missing features like some complex gradients, I can't say I've missed them, ex…

Please take your time machine and go release PDF.js in early 2010. With good performance on the hardware and Javascript VMs of early 2010. Then I'll grant you the criticism of Chrome's PDF viewer. Otherwise, trolling... fact is, Chrome is the browser that liberated the world from Acrobat Reader. PDF.js is awesome and it may be the way to go, but as of today Chrome's viewer is still much better -- please try http://ww…

> Please take your time machine and go [to] early 2010... Chrome's PDF viewer... fact is, Chrome is the browser that liberated the world from Acrobat Reader.

Fact check:

August 31, 2006: "Current versions of Safari are able to access PDF documents in a number of different ways. It can display the documents inline (in the Web browser window) without the use of a plug-in, it can use the Adobe Preview plug-in to display documents inline with added controls, or it can pass PDF viewing duties off to another application like Adobe Reader or Apple's own Preview.app."

http://reviews.cnet.com/8301-13727_7-10327228-263.html

"Google Chrome ... was released as a beta version for Microsoft Windows on September 2, 2008, and as a stable public release on December 11, 2008."

http://en.wikipedia.org/wiki/Google_Chrome

Re: Firefox introduces PDF viewer

#80
I've been using this for a while in Firefox beta, and it's generally really good.

I have two small problems with it, which perhaps won't be too hard to fix:

1. PDFs of old academic papers that are just strung-together CCITT (fax) compressed monochrome scans. Preview.app, Adobe Reader and Chrome resample those to give a readable quasi-anti-aliased effect. PDF.js makes the text jaggy and spindly and hard to read.

2. No back/forward navigation.

Post reply on HN