Bug 85662 - Patch for not using '\' to split strings across multiple lines breaks printing and PS viewers
Summary: Patch for not using '\' to split strings across multiple lines breaks printin...
Status: RESOLVED FIXED
Alias: None
Product: cairo
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: Other Linux (All)
: medium normal
Assignee: Chris Wilson
QA Contact: cairo-bugs mailing list
URL:
Whiteboard:
Keywords:
: 89357 89406 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-10-30 20:36 UTC by Alex Korobkin
Modified: 2015-03-03 20:00 UTC (History)
3 users (show)

See Also:
i915 platform:
i915 features:


Attachments
patch (1010 bytes, patch)
2014-10-30 21:47 UTC, Adrian Johnson
Details | Splinter Review
cafe2.pdf (56.35 KB, application/pdf)
2014-10-31 15:00 UTC, Alex Korobkin
Details
cafe2.ps (66.33 KB, text/plain)
2014-10-31 15:02 UTC, Alex Korobkin
Details

Description Alex Korobkin 2014-10-30 20:36:40 UTC
This patch [1] breaks PostScript printing with pdftocairo to Ricoh printers: only the last line of the sequence is printed. 

For example, if you have this in your .ps file, 
(aaa)
(bbb)
(cc)
only "cc" will appear on the page. 

PostScript viewers also fail to parse it: neither GhostScript nor Evince are able display these lines. 

Please revert or fix the patch? 

1. http://cgit.freedesktop.org/cairo/commit/?id=ab2a7b61d59258b71e1c3256edf2f42ea6cc1eb2
Comment 1 Bryce Harrington 2014-10-30 21:31:09 UTC
I've reverted the problematic patch in trunk.

I'm hopeful that a better fix can be found for the original issue, and am CCing Adrian.

This (or a better fix) is a candidate for 1.14.2
Comment 2 Adrian Johnson 2014-10-30 21:47:58 UTC
Created attachment 108707 [details] [review]
patch

Please attach a pdf for reproducing the problem and your ps output. It works fine for me with ghostscript 9.06.

Please try the attached patch.
Comment 3 Adrian Johnson 2014-10-30 21:52:16 UTC
(In reply to Bryce Harrington from comment #1)
> I've reverted the problematic patch in trunk.
> 
> I'm hopeful that a better fix can be found for the original issue, and am
> CCing Adrian.
> 
> This (or a better fix) is a candidate for 1.14.2

I'm sure we can find a better fix since reverting it breaks printing on my printer. I'll work on analyzing this problem but don't expect an immediate response. I've been sleeping for the last 8 hours.
Comment 4 Adrian Johnson 2014-10-31 08:58:15 UTC
I've pushed a fix for this.
Comment 5 Alex Korobkin 2014-10-31 15:00:35 UTC
Created attachment 108728 [details]
cafe2.pdf
Comment 6 Alex Korobkin 2014-10-31 15:02:34 UTC
Created attachment 108729 [details]
cafe2.ps

Here is a resulting file with broken lines. 

I tested the suggested patch. Looks like it makes one long line (aaabbbcccc) instead of 
(aaa)
(bbb)
(cccc)

This works with my Evince, GS, and my printers, though I'm not sure what is the limit of length for such a line.
Comment 7 Adrian Johnson 2015-03-03 19:58:58 UTC
*** Bug 89406 has been marked as a duplicate of this bug. ***
Comment 8 Adrian Johnson 2015-03-03 20:00:35 UTC
*** Bug 89357 has been marked as a duplicate of this bug. ***


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.