Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

Chromium and PDFs

If none of the specific sub-forums seem right for your thread, ask here.
Post Reply
Message
Author
milomak
Posts: 2168
Joined: 2009-06-09 22:20
Been thanked: 2 times

Chromium and PDFs

#1 Post by milomak »

I see it wants to download them instaeda of opening them. How can I change the behaviour for PDF files to be opened by the default PDF app?
Desktop: A320M-A PRO MAX, AMD Ryzen 5 3600, GALAX GeForce RTX™ 2060 Super EX (1-Click OC) - Sid, Win10, Arch Linux, Gentoo, Solus
Laptop: hp 250 G8 i3 11th Gen - Sid
Kodi: AMD Athlon 5150 APU w/Radeon HD 8400 - Sid

User avatar
mzilikazi
Forum Account
Forum Account
Posts: 3282
Joined: 2004-09-16 02:14
Location: Colorado Springs, CO

Re: Chromium and PDFs

#2 Post by mzilikazi »

It's a hack but you can use libpdf.so from the latest google chrome build.

Code: Select all

wget http://dl.google.com/linux/direct/google-chrome-unstable_current_i386.deb
OR

Code: Select all

wget http://dl.google.com/linux/direct/google-chrome-unstable_current_amd64.deb
You could unpack the .deb or IMHO mc is easier.

Code: Select all

su
mc
Navigate to

Code: Select all

/usr/lib/chromium-browser/
<TAB> to the other pane and navigate to:

Code: Select all

google-chrome-unstable_current_amd64.deb
Press <enter>
You are now virtually inside the .deb
Navigate to:

Code: Select all

CONTENTS/opt/google/chrome/libpdf.so
Press F5
You should now have

Code: Select all

/usr/lib/chromium-browser/libpdf.so
Open chromium-browser
about:plugins
Enable Chrome PDF viewer
Google docs will now open your PDF's
Debian Sid Laptops:
AMD Athlon(tm) 64 X2 Dual-Core Processor TK-55 / 1.5G
Intel(R) Pentium(R) Dual CPU T2390 @ 1.86GHz / 3G

User avatar
craigevil
Posts: 5391
Joined: 2006-09-17 03:17
Location: heaven
Has thanked: 28 times
Been thanked: 39 times

Re: Chromium and PDFs

#3 Post by craigevil »

Docs PDF/PowerPoint Viewer (by Google) - Google Chrome extension gallery : https://chrome.google.com/extensions/de ... medengocbn

Chrome has a pdf plugin

Code: Select all

Chrome PDF Viewer
Portable Document Format
Name:	Chrome PDF Viewer
Description:	Portable Document Format
Version:	
Priority:	0
Location:	/opt/google/chrome/libpdf.so 
Raspberry PI 400 Distro: Raspberry Pi OS Base: Debian Sid Kernel: 5.15.69-v8+ aarch64 DE: MATE Ram 4GB
Debian - "If you can't apt install something, it isn't useful or doesn't exist"
My Giant Sources.list

User avatar
gradinaruvasile
Posts: 935
Joined: 2010-01-31 22:03
Location: Cluj, Romania
Contact:

Re: Chromium and PDFs

#4 Post by gradinaruvasile »

The Chrome pdf plugin rip-off is better. The chrome pdf plugin is faster (albeit basic) and it has copy-paste. The online viewer usually renders pages slowly (first blurred then it gets sharper) and it doesnt even have a copy-paste function.
I just installed the Chrome dev version and thats it (it installs the repository automatically with it). I dont think that Chrome has more stuff in it (compared to chromium) besides the flash, pdf plugins and maybe the h264 codec (not sure). I dont think that it has other privacy problems than Chromium itself. But i still like the Chromium logo better... :)

Codfather
Posts: 1
Joined: 2010-08-19 21:49

Re: Chromium and PDFs

#5 Post by Codfather »

Yes, I also find it odd that it's not included in the Chromium version by default as it was by my understanding developed by the chromium guys, and should therefore be open source. They did this to work around all the problems with trying to launch either evince or adobes PDF reader. It might be an Adobe license issue, but I don't know.
I take a slightly different approach, and just have chromium and goggle chrome dev installed on my workstation, and just copy the libpdf.so from /opt/google/chrome to /use/lib/chromium-browser. I also copy over the other .so files which work and the new google apps in the resources dir.
It's good to see that a few of the main distros are looking to include stable versions of chromium in their repos, as I prefer the fully open source version to having to use the Google version, choice is good ;-). Here's hoping that this will always be possible and the two versions don't start to drift to far apart.

User avatar
gradinaruvasile
Posts: 935
Joined: 2010-01-31 22:03
Location: Cluj, Romania
Contact:

Re: Chromium and PDFs

#6 Post by gradinaruvasile »

I just tested the latest Chromium build and the pdf viewer doesnt work right - it shows the pdf, but no interaction is possible (no text selector cursor, no options in the lower right corner. Maybe they just messed up something temporarily. Chrome dev version works well.

User avatar
gradinaruvasile
Posts: 935
Joined: 2010-01-31 22:03
Location: Cluj, Romania
Contact:

Re: Chromium and PDFs

#7 Post by gradinaruvasile »

Now the pdf plugin works again on Chromium. Guess it was a temporary problem...

yudith
Posts: 1
Joined: 2012-05-30 11:28

Re: Chromium and PDFs

#8 Post by yudith »

Thanks for the post. I also don't understand why they can't include it into chromium.
Would be really nice.

So thanks again, I love this plugin. :)

Post Reply