Incorrect color output of the buttons on the webpages (google search web page) when printed from Mozilla firefox 12 and above

Bug #1022516 reported by goutam kodu on 2012-07-09
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
GS-GPL
Fix Released
High
ghostscript (Ubuntu)
High
Unassigned
Precise
High
Till Kamppeter

Bug Description

This bug is happening on

Ubuntu : 12.04 LTS
ghostscript version : 9.05
Mozilla firefox: 12 and above.

How to reproduce:
1. Open Mozilla firefox web browser
2. Type in the url : www.google.com
3. Go to File->Print and select "Print to File" option and output format as "pdf" and click on the print button.
4. Pass the generated pdf file to Ghostscript 9.05 using cupsfilter command:

   cupsfilter -m application/vnd.cups-raster -p /usr/share/cups/model/laserjet.ppd -o "PageSize=Letter fitplot" ~/mozilla.pdf > ~/mozilla.ras

5. Open the mozilla.ras file using Rasterviewer application
     rasterviewer ~/mozilla.ras

You will find that the color of the botton "Google Search" and "I'm feeling luck" are yellow in color which is different from what we view in the browser.

[IMPACT]

Everyone with an HP inkjet printer (and perhaps also some other color printers) can get wrongly colored graphical elements when printing from programs which use Cairo for their print output

The fix is a small patch on Ghostscript, with which the Ghostscript developers have fixed the bug upstream (see linked upstream bug).

[TESTCASE]

Let Ghostscript render the attached sample PDF file (generated via "Print to file" by Firefox, from the www.google.com page) into the CUPS Raster format with color space 17 (the color space used for HP's color inkjets by HPLIP) using the following command line:

gs -sDEVICE=cups -dcupsColorSpace=17 -sOutputFile=out17.raster firefox-google-com-lp1022516.pdf

The display the output file with rasterview from http://www.easysw.com/~mike/rasterview/index.html:

rasterview out17.raster

The buttons on the page appear in yellow whereas in the original PDF file they are gray.

After installing the proposed package and repeating the Ghostscript command line call, the buttons in out17.raster appear correctly in gray.

You can also use the steps shown in the original bug description to reproduce the bug and to verify that the proposed package fixes it.

[Regression Potential]

The patch is very small and simple and it is issued by the upstream developers who run it through automated regression tests with several 10k of files, so the probability of regressions is very low.

Till Kamppeter (till-kamppeter) wrote :

I cannot reproduce this bug. Using PPD files for color printers I get always correctly colored output. Using laserjet.ppd I get grayscale output, no yellow at all (it is for a monochrome printer).

Note that /usr/share/cups/model/laserjet.ppd does not exist in Ubuntu 12.04. I have to generate it via

/usr/lib/cups/daemon/cups-driverd cat drv:///sample.drv/laserjet.ppd > laserjet.ppd

This can mean that your laserjet.ppd is not the same as mine, so please attach your laserjet.ppd.

I have no utility named "rasterviewer", instead, I have used "rasterview" from http://www.easysw.com/~mike/rasterview/index.html. Please post a link from where you got "rasterviewer".

Changed in ghostscript (Ubuntu):
status: New → Incomplete
goutam kodu (goutam-hplip) wrote :

Hi Till,

Thanks for your response.

In my above post there was a typo mistake with the rasterviewer. I meant it to say rasterview. Sorry for that :(.

In the laserjet.pdd the default colourspace is Grey with which it is giving correct output whereas if the defaultcolorspace is RGB the issue is reproducible.

I am able to reproduce this issue using an Officejet PPD file.

Run command

$ cupsfilter -m application/vnd.cups-raster -p /usr/share/cups/model/hp-officejet_4610_series.ppd -o "PageSize=Letter fitplot" ~/mozilla.pdf > ~/mozilla.ras

$ rasterview ~/mozilla.ras

I am attaching you the hp-officejet_4610_series.pdd file.

Till Kamppeter (till-kamppeter) wrote :

Now I can reproduce the bug. It occurs with color space 17 and not with color space 1. I will forward it upstream to Ghostscript.

Changed in ghostscript (Ubuntu):
status: Incomplete → Confirmed
importance: Undecided → High
milestone: none → ubuntu-12.04.1
Changed in gs-gpl:
importance: Unknown → High
status: Unknown → Confirmed
Changed in ghostscript (Ubuntu):
status: Confirmed → Fix Committed
Changed in ghostscript (Ubuntu Precise):
status: New → Triaged
importance: Undecided → High
milestone: none → ubuntu-12.04.1
Changed in ghostscript (Ubuntu):
milestone: ubuntu-12.04.1 → none
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ghostscript - 9.05~dfsg-6ubuntu2

---------------
ghostscript (9.05~dfsg-6ubuntu2) quantal; urgency=low

  * debian/patches/020120711-4f6b985-write-transparent-type2-pattern-color-to-clist.patch:
    When using a clist, ensure that all the color space data for the
    pattern gets written to the clist, *and* that the clist correctly
    records all the relevant transparency data (LP: #1022516, upstream bug
    #693176).
 -- Till Kamppeter <email address hidden> Wed, 11 Jul 2012 17:08:13 +0200

Changed in ghostscript (Ubuntu):
status: Fix Committed → Fix Released
Changed in ghostscript (Ubuntu Precise):
status: Triaged → Fix Committed
Till Kamppeter (till-kamppeter) wrote :

Fixed package for Precise uploaded to precise-proposed package repository. As soon as this package gets approved it will be available for testing and another comment with installation and testing instructions will be posted here. Please test the package then and give feedback here, as this is required to make the package an official update for Ubuntu.

For the SRU team: debdiff attached.

Till Kamppeter (till-kamppeter) wrote :

Sample file for reproducing this bug. See bug description.

description: updated
Changed in gs-gpl:
status: Confirmed → Fix Released
Changed in ghostscript (Ubuntu Precise):
assignee: nobody → Till Kamppeter (till-kamppeter)

Hello goutam, or anyone else affected,

Accepted ghostscript into precise-proposed. The package will build now and be available at http://launchpad.net/ubuntu/+source/ghostscript/9.05~dfsg-0ubuntu4.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please change the bug tag from verification-needed to verification-done. If it does not, change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

tags: added: verification-needed
Jean-Baptiste Lallement (jibel) wrote :

Where does the file /usr/share/cups/model/laserjet.ppd comes from ? It is required by the test case.

SRU verification for Precise:
I have reproduced the problem with ghostscript 9.05~dfsg-0ubuntu4 in precise and have verified that the version of ghostscript 9.05~dfsg-0ubuntu4.1 in -proposed fixes the issue.

I tried with both the ppd in attachment and directly with gs colorspace 17 and results are as expected.

Marking as verification-done

tags: added: verification-done
removed: verification-needed

The verification of this Stable Release Update has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regresssions.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ghostscript - 9.05~dfsg-0ubuntu4.1

---------------
ghostscript (9.05~dfsg-0ubuntu4.1) precise-proposed; urgency=low

  * debian/patches/020120711-4f6b985-write-transparent-type2-pattern-color-to-clist.patch:
    When using a clist, ensure that all the color space data for the
    pattern gets written to the clist, *and* that the clist correctly
    records all the relevant transparency data (LP: #1022516, upstream bug
    #693176).
 -- Till Kamppeter <email address hidden> Wed, 11 Jul 2012 17:08:13 +0200

Changed in ghostscript (Ubuntu Precise):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.