Bug 438250

Summary: Transparent support for "PDF portfolios"
Product: [Applications] okular Reporter: Thomas Fischer <fischer>
Component: PDF backendAssignee: Okular developers <okular-devel>
Status: REPORTED ---    
Severity: wishlist CC: aacid, greg, nate
Priority: NOR Keywords: usability
Version: 21.04.1   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Thomas Fischer 2021-06-08 13:09:42 UTC
I have encountered PDF files that, when being opened in Okular, only show a large logo from Adobe and the text "For the best experience, open this PDF portfolio in Acrobat X or Adobe Reader X, or later." and below that a button-like image labeled "Get Adobe Reader Now!". The button is a link to Adobe's webpage.
Okluar also notifies in a blue box above that this PDF file contains embedded files. The embedded files are one or several PDF files that can be viewed or saved in the list in window "Embedded Files".

So, the technical support for "PDF portfolios" is there as a portfolio seems to be a regular PDF file only containing a scary image of "don't use third-party PDF viewers" plus a few attached regular PDF files. However, it is made to trick users into believing that Okular does not support such portfolios as the attachment notification is easy to miss in such a situation.

A better way to handle such a situation for Okular would be:
- if it is just one embedded PDF file, then immediately discard the "outer" PDF with the scary warning and show the embedded one only. Notify about this redirection via a non-intrusive notification like the one for the embedded files.
- if several PDF files are embedded, show a concatenated version of the in the main viewer so that it looks like one PDF file. Still, never show the scary image, but show the "This document has embedded files" notification to allow retrieving the embedded PDF files individually.

Example PDF file are easy to find by just searching the Internet for the scary text message.
One example is: https://www.irs.gov/pub/irs-prior/f7200--2021.pdf
(which is probably legal to use and archive as being a US government document).
Comment 1 Nate Graham 2021-06-08 19:46:48 UTC
Jeez, how horrible.
Comment 2 Albert Astals Cid 2021-06-08 21:24:39 UTC
For what is worth the actual term for this is "Collections" as described in "8.2.4 Collections" of the PDF 1.7 spec document.

Of course, first poppler would need to support this.

Doesn't seem super hard to implement, but would need someone with time to work on it, which personally I don't.

I'd be willing to help whoever tries implementing this.