Bug 690633 - Ghostscript shows Hidden Layers in PDF
Summary: Ghostscript shows Hidden Layers in PDF
Status: NOTIFIED FIXED
Alias: None
Product: Ghostscript
Classification: Unclassified
Component: Images (show other bugs)
Version: 8.64
Hardware: PC Windows XP
: P1 enhancement
Assignee: Alex Cherepanov
URL:
Keywords: bountiable
: 689289 (view as bug list)
Depends on:
Blocks:
 
Reported: 2009-07-16 07:20 UTC by Eli Segev
Modified: 2011-09-18 21:46 UTC (History)
1 user (show)

See Also:
Customer: 1110
Word Size: ---


Attachments
CS3_PTC all layers 2.pdf (174.57 KB, application/pdf)
2009-07-16 07:49 UTC, Eli Segev
Details
patch (6.74 KB, patch)
2009-11-16 21:42 UTC, Alex Cherepanov
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eli Segev 2009-07-16 07:20:31 UTC
When displaying a PDF file with Ghostscript 8.64, a hidden layer is showing.
Comment 1 Eli Segev 2009-07-16 07:21:18 UTC
Alex,

How do I send an example?
Comment 2 Ken Sharp 2009-07-16 07:45:37 UTC
Eli, go to the bug page and press 'Create a New Attachement'.
Comment 3 Eli Segev 2009-07-16 07:49:13 UTC
Created attachment 5213 [details]
CS3_PTC all layers 2.pdf

If you open this file with Adobe Reader, you will not see a red X.  This red X
is visible when displaying the file with Ghostscript.
Comment 4 Alex Cherepanov 2009-07-16 08:37:52 UTC
Ghostscript doesn't support optional content yet. Old versions of Acrobat
Reader(e.g AR5) also show the cross.

The problem with optional content is that Ghostscript cannot just skip
optional objects. It has to update the graphic state but not display anything.
Comment 5 Ray Johnston 2009-07-16 10:05:37 UTC
Support for optional content is an enhancement.
Comment 6 Marcos H. Woehrmann 2009-09-28 07:15:29 UTC
One of our customers has asked for this feature as well.  I've added their customer number to this bug and 
increased the priority.
Comment 7 Ray Johnston 2009-09-28 09:43:58 UTC
Actually this customer is P1.
Comment 8 Alex Cherepanov 2009-11-16 21:22:19 UTC
*** Bug 689289 has been marked as a duplicate of this bug. ***
Comment 9 Alex Cherepanov 2009-11-16 21:42:53 UTC
Created attachment 5679 [details]
patch

Handle optional content following the default viewing optional content
configuration dictionary, Skip invisible XObjects and render invisible
parts of content streams to nulldevice.

Since pdfwrite device is not yet ready for optional content,
all information about optional content is removed. Visible objects are merged
in, invisible objects and associated structures are discarded.

This patch hides invisible object in all sample files in this and duplicate bug

reports. Testing also shows progression in BFAX35P5.pdf.
Comment 10 Alex Cherepanov 2009-11-17 20:48:00 UTC
The patch has been committed as a rev. 10341.
Regression testing shows progressions in BFAX35P5.pdf and Bug689290.pdf .
Comment 11 Marcos H. Woehrmann 2011-09-18 21:46:25 UTC
Changing customer bugs that have been resolved more than a year ago to closed.