Libreoffice will no longer print landscape page

Bug #1040037 reported by Barry Drake
120
This bug affects 21 people
Affects Status Importance Assigned to Milestone
CUPS
Fix Released
Critical
LibreOffice
Fix Released
High
cups-filters (Ubuntu)
Fix Released
High
Till Kamppeter
Quantal
Fix Released
High
Till Kamppeter
libreoffice (Ubuntu)
Invalid
Medium
Unassigned
Quantal
Invalid
Undecided
Unassigned

Bug Description

Since update yesterday, landscape pages print as portrait printing to a Brother DCP 135C. Print preview shows a landscape layout, but output from printer always comes out as a portrait page. The problem did not occur two days ago, and does not occur when printing from other applications (eg pdf viewer).

WORKAROUND: Export the file as a pdf and print that using the pdf viewer.

[IMPACT]

Landscape-formatted documents from LibreOffice get printed rotated and cut off on all printers using Ghostscript's built-in drivers ("pxlmono", "ljet4", "hl1250", ...), perhaps also with other drivers.

[TESTCASE]

Print the attached file test.pdf via

lp test.pdf

on a printer using one of Ghostscript's built-in drivers (not CUPS Raster). Result is the content being rotated by 90 degrees and the rightmost portion of the content cut off. The same job comes out correctly when the proposed package is installed.

[Regression Potential]

Patch is simple, there should be no regressions.

ProblemType: Bug
DistroRelease: Ubuntu 12.10
Package: libreoffice (not installed)
ProcVersionSignature: Ubuntu 3.5.0-11.11-generic 3.5.2
Uname: Linux 3.5.0-11-generic i686
ApportVersion: 2.4-0ubuntu8
Architecture: i386
Date: Wed Aug 22 13:08:56 2012
InstallationMedia: Ubuntu 12.10 "Quantal Quetzal" - Alpha i386 (20120730.1)
ProcEnviron:
 LANGUAGE=en_GB:en
 TERM=xterm
 PATH=(custom, no user)
 LANG=en_GB.UTF-8
 SHELL=/bin/bash
SourcePackage: libreoffice
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

From Calc printer prints Landscape page orientation as Portrait
Steps to reproduce:
0. Close all instances of Libre office
1. Start Calc
2. Type something in first cell
3. do Format->Page orientation Landscape
4. Print this document
Result: document printed in wrong orientation

Note that page preview and printer dialog preview display correct results and export to PDF exports correctly

Produced on LibO 3.5.0 beta 1 on Fedora 64 bit

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

Created attachment 55412
contents of my /etc/cups

On LibO 3.3.4 on Fedora 64 bit prints correctly

Revision history for this message
In , Cmsigler-online (cmsigler-online) wrote :

Hi all,

(In reply to comment #0)
> From Calc printer prints Landscape page orientation as Portrait

It is possible that this is the same issue as Bug 38962 (which affects me).

Please see Bug 38962 Comment 3 for IMHO the key note: The bug is triggered by Printer Language Type set to PDF instead of one of the PS options. The problem seems to exist in 3.4.X and 3.5.X, which provide Printer Language Type=PDF, while it doesn't in 3.3.X, where PDF is not an option. Also, it seems to be primarily related to Brother printers (both mine are that brand), although it is also reported to affect a Samsung printer.

HTH.

Clemmitt

Revision history for this message
In , Pmladek-y (pmladek-y) wrote :

I am unable to reproduce this with the steps in the comment 0, LO-3.5.0-beta2 on SLED11-SP1-x86_64, HP LaserJet P2015dn. I tried both "Printer Language Types": PDF and Poscript Level 2.

So, it is probably related to some types of printers or other settings.

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

Thanks for interesting in my problem.
Copy-paste workaround that solves my problem perfectly:
Goto File -> Printer Settings -> Properties -> Device and
change "Printer Language Type" from PDF to one of the Postscript options.

Revision history for this message
In , Lanasth (lanasth) wrote :

(In reply to comment #3)
> I am unable to reproduce this with the steps in the comment 0, LO-3.5.0-beta2
> on SLED11-SP1-x86_64, HP LaserJet P2015dn. I tried both "Printer Language
> Types": PDF and Poscript Level 2.
>
> So, it is probably related to some types of printers or other settings.

I've got LO-3.5.0-beta2 on 3 Win764-bit machines, and have the same issues with ANY laser printer that's not also a copier (including any old HP workhorse laser). Choose any other kind of printer (InkJet, pseudo-PDF, a business-class copy machine, etc.), and the problem is non-existent. I can't find any such "Printer Language" option in Win and the problem is definitely LO (not OpenOffice). See Bug 44275.

Revision history for this message
In , Netwiz (netwiz) wrote :

I can confirm this using the hpijs CUPS driver.

I can also confirm the workaround - however it has to be done each time LO is opened.

Revision history for this message
In , Netwiz (netwiz) wrote :

My setup:

2 x EL6.2 desktops
LO 3.5.0
Printer: Fuji Xerox DocuCentre C2270
Driver: hpijs

Both print the content in portrait.

Setting File -> Printer Settings -> Properties -> Device and
change "Printer Language Type" from PDF to one of the Postscript options fixes the printout until LO is opened again. Once re-opened, the type returns to PDF and the printing error returns.

Revision history for this message
In , Netwiz (netwiz) wrote :

Good call adding this to the most annoying bugs bug.

I would also like to point out that this issue does not solely happen within Calc. I have a Writer document that does exactly the same.

Revision history for this message
In , Caolanm (caolanm) wrote :

It's quite likely that this "truncation of landscape page under Linux" is a cups problem with pdf and landscape rotation, e.g. see https://bugzilla.redhat.com/show_bug.cgi?id=740496 and https://bugs.launchpad.net/ubuntu/+source/cups/+bug/47649

So, the relevant information is:
a) what Linux distribution this is happening on
b) and what versions of cups and ghostscript-cups are installed, e.g. output of rpm -q cups ghostscript-cups on fedora

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

Fedora 15 Lovelock 64 bit
[s@t2 lib]$ rpm -q cups ghostscript-cups
cups-1.4.8-5.fc15.x86_64
ghostscript-cups-9.04-3.fc15.x86_64

Revision history for this message
In , Caolanm (caolanm) wrote :

*** Bug 38962 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Netwiz (netwiz) wrote :

# cat /etc/redhat-release
Scientific Linux release 6.2 (Carbon)

System #1:
# rpm -q cups ghostscript-cups
cups-1.4.2-44.el6.x86_64
package ghostscript-cups is not installed

System #2:
# rpm -q cups cups-ghostscript
cups-1.4.2-44.el6.i686
package cups-ghostscript is not installed

Both systems using LO 3.5.0

Revision history for this message
In , Caolanm (caolanm) wrote :

*** Bug 43656 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Caolanm (caolanm) wrote :

*** Bug 42777 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Caolanm (caolanm) wrote :

*** Bug 39289 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Caolanm (caolanm) wrote :

"using the hpijs CUPS driver", for those using hpijs, can you try hpcups instead, i.e. follow https://bugzilla.redhat.com/show_bug.cgi?id=768811#c10 (fedora-specific howto)

Revision history for this message
In , Lanasth (lanasth) wrote :

(In reply to comment #16)

This bug is not restricted to Linux, nor to one type of driver. See Bug 44275.

Revision history for this message
In , Darek (dmichalskisj) wrote :

I use Libreoffice 3.5 on PCLinuxOS (KDE) and confirm the same problem: Writer doesn't print landscape oriented pages. I have to change the Printer Language Type" from PDF to one of the Postscript options. But every time I close and open LO I have to repeat it. Very annoying!

cups-1.4.6-1pclos2011
ghostscript-cups is not found

Revision history for this message
In , Caolanm (caolanm) wrote :

re: "This bug is not restricted to Linux, nor to one type of driver" which is why your bug is not marked as a duplicate of this one. This one is for the collection of bugs suspected to be due to to something cups-side with landscape pdf pages so unix-specific.

Ubuntu/Debian Linux derivatives are suspiciously absent from the list of affected Linux systems so far.

Revision history for this message
In , Bluecanyoncreations (bluecanyoncreations) wrote :

I'm confirming both the problem & the temporary fix on PCLinuxOS 2011 (KDE) & LO 3.4.3

rpm -q cups ghostscript-cups
cups-1.4.6-1pclos2011
package ghostscript-cups is not installed

Revision history for this message
In , Keel-lambert (keel-lambert) wrote :

For new files LO always selects "Printer Language Type" as PDF.
The problem is also evident when I try to print two portait pages on a single
page both in writer and in calc.

On any existing file once the "Printer Language Type" has been changed it is
remembered.

For me the new PDF "Printer Language Type" is the problem.

my setup,
Libreoffice 3.5, openSUSE12.1
Samsung SCX-4200, CLX-2160N printers

<2012Mar12><10:28><~/Updates/Tumbleweed_12.1> rpm -q cups ghostscript-cups
cups-1.5.0-2.1.3.x86_64
package ghostscript-cups is not installed
<2012Mar12><10:54><~/Updates/Tumbleweed_12.1>

Revision history for this message
In , Netwiz (netwiz) wrote :

Bumping the priority on this - as this is a basic functionality that should be fixed ASAP. Landscape printing is probably one of the cornerstones of an office package.

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

*** Bug 35132 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Netwiz (netwiz) wrote :

Hi all,

Just short of a month since the last comment with no new details. Is there any news on this bug?

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

reproducible in 3.5.2 on Fedora (tested from Writer)

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

@ Steve
Sorry, but "Version" is most old reproducible version, for determine when bug appears. Not current version. If in current version bug not reproducible, it just closed to status WorksForMe.

Revision history for this message
In , Netwiz (netwiz) wrote :

Ah, if thats the case then, I'll set it back to 3.5.0. I thought it was what was used to keep track of bugs against a certain version like some other projects.

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

*** Bug 41968 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Cno (cno) wrote :

(In reply to comment #19)

> Ubuntu/Debian Linux derivatives are suspiciously absent from the list of
> affected Linux systems so far.

Ineed: Just tested with 3.5.2 and master (2012-10-04) on Ubuntu 32 Bits;
Works fine here.

Revision history for this message
In , Cno (cno) wrote :

*** Bug 45340 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Mauricebatey (mauricebatey) wrote :

"Change "Printer Language Type" from PDF to one of the Postscript options fixes
the printout until LO is opened again. Once re-opened, the type returns to PDF
and the printing error returns."

Some have found that a change to 'Postscript Level 2' will stick...

(I did it via 'spadmin' (/opt/libreoffice3.4/program/spadmin here).)

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

@ mab
Very much thanks for this workaround. It works.

Revision history for this message
In , Mauricebatey (mauricebatey) wrote :

(In reply to comment #32)

  Glad to hear that!

Which version of LO will avoid the problem?

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

This workaround works for 3.5.2 on Fedora 64 bit

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

*** Bug 42907 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Malv-star (malv-star) wrote :

I can confirm that this bug is present as far back as LibreOffice 3.4.5 running on openSUSE 11.4 32-bit. Once again an RPM-based distro. As per comment 26, I'm setting the bug to the oldest version on which this issue is reproducible. Hoping to get a fix for this prior to the release of openSUSE 12.2 in July.

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

*** Bug 43506 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

*** Bug 47151 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

*** Bug 48394 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

*** Bug 47804 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

*** Bug 48172 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

*** Bug 52308 has been marked as a duplicate of this bug. ***

Revision history for this message
penalvch (penalvch) wrote :

Barry Drake, thank you for reporting this and helping make Ubuntu better. Could you please execute the following at a terminal, and post the results to this report:
apt-cache policy libreoffice-writer

Changed in libreoffice (Ubuntu):
status: New → Incomplete
tags: added: regression-potential
Changed in libreoffice (Ubuntu):
importance: Undecided → Medium
Revision history for this message
Barry Drake (b-drake) wrote :

libreoffice-writer:
  Installed: 1:3.5.4-0ubuntu1.1
  Candidate: 1:3.5.4-0ubuntu1.1
  Version table:
 *** 1:3.5.4-0ubuntu1.1 0
        500 http://gb.archive.ubuntu.com/ubuntu/ precise-updates/main i386 Packages
        500 http://security.ubuntu.com/ubuntu/ precise-security/main i386 Packages
        100 /var/lib/dpkg/status
     1:3.5.2-2ubuntu1 0
        500 http://gb.archive.ubuntu.com/ubuntu/ precise/main i386 Packages

Revision history for this message
penalvch (penalvch) wrote :

Barry Drake, thank you for providing this information.

When you noted you upgraded a day ago, did you upgrade from a prior release? If so, which?

Revision history for this message
Barry Drake (b-drake) wrote :

This was not a release-upgrade. It was a clean install of 12.10 alpha 3 including re-formatting, with all updates carried out almost daily since.

Revision history for this message
penalvch (penalvch) wrote :

Barry Drake, just to clarify, you provided results of libreoffice-writer from Precise in https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/1040037/comments/2 but your noting your problem is in Quantal. Could you please restate when the problem did not occur and when it did?

tags: added: regression-update
removed: regression-potential
Changed in libreoffice (Ubuntu):
status: Incomplete → New
status: New → Incomplete
Revision history for this message
Barry Drake (b-drake) wrote :

Problem was not present on Monday 20th August but appeared on the Tuesday after the available upgrades were installed last thing Monday night. The landscape page had printed out OK early Monday evening and with no alterations would only print in portrait format on the Tuesday evening. I do not get the problem in Precise - only in Quantal which I have as a dual boot with Precise. Currently I'm booting into Precise to print the landscape pages and this works just fine with the same file.

Revision history for this message
Björn Michaelsen (bjoern-michaelsen) wrote :

d-drake: Please dont mix in the precise versions (that seem to be working fine, if Iead you correctly), but state the versions you have on quantal before and after the update that broke it.

Revision history for this message
Barry Drake (b-drake) wrote :

Current version is: Version 3.6.0.2 (Build ID: 360m1(Build:102)) I have no record of what the version was prior to the broken version: I assume it is the same as I only took an update. I've attached the apt logfile. There was no apparent change to libreoffice on August 20th, but there was a cups update and various other updates .... I don't know where else to look.

penalvch (penalvch)
Changed in libreoffice (Ubuntu):
status: Incomplete → New
Revision history for this message
Barry Drake (b-drake) wrote :

Further information: Problem still exists after today's updates. If I print-to-file and then print out the resulting pdf, this does print in landscape format.

Revision history for this message
In , Ja-k (ja-k) wrote :

I can confirm too - bug still valid in LO 3.5.x in Mageia 2 and LO 3.6.1 builded myself on Mageia 2.
"PDF" language for the printer has another victim: printing envelope DL (Mageia bug No. 4521: https://bugs.mageia.org/show_bug.cgi?id=4521)

Solution:
I wrote small patch which switch as default langauge for printer Postscript level 2. Tested on LO 3.6.1 - works very well.

Revision history for this message
In , Ja-k (ja-k) wrote :

Created attachment 66131
Switch to printer langauge Postscript level 2 as default

Revision history for this message
In , Upscope (upscope) wrote :

I can report this bug also is occuring on openSUSE12.2 GM, released two days ago. Using libreoffice 3.5.4. Work around does work, but real pain to have to change each time.

Thanks

Revision history for this message
In , Luisgmarengo (luisgmarengo) wrote :

Bug is present in OpenSuSE 12.2, LO 3.5.4.7-1.1.2.x86_64. The default should be changed to PostScript 2.

Revision history for this message
In , Jakob Unterwurzacher (jakobunt) wrote :

Regarding "Ubuntu/Debian Linux derivatives are suspiciously absent from the list of affected Linux systems so far.": This is on Ubuntu 12.04, LO 3.5.4.

Printing does not work AT ALL here with a networked PostScript printer (some big Xerox machine) and the language set to PDF. It works unreliably with PS. Often just nothing happens when you print. The job is not even queued.
Printing from every other application works perfectly. Printing with OO 3.2.0 used to work perfectly (on Ubuntu 10.04).

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in cups (Ubuntu):
status: New → Confirmed
Changed in libreoffice (Ubuntu):
status: New → Confirmed
Revision history for this message
In , Freiheits (freiheits) wrote :

I have this bug stretches from OpenSUSE 11.3 with LibreOffice 3.4 in OpenSUSE 12.2 with LibreOffice 3.5 is present, too.

Revision history for this message
mabab (mabab) wrote :

I updated to ubuntu 12.10 and now I am affected by this bug.

I followed the advice: "Open any LibreOffice app and go to File=>Printer Settings=>Properties=>Device tab. Is the "Printer Language type" set to PDF? If so, it's probably https://bugs.freedesktop.org/show_bug.cgi?id=44664. The workaround is to change the printer language to Postscript (level from driver). See this thread: Libreoffice doesn't print landscape files properly" from this link: http://forums.opensuse.org/english/get-technical-help-here/applications/473302-problems-printing-landscape-libreoffice-suse-12-1-a.html

Now everything is OK.

Revision history for this message
penalvch (penalvch) wrote :

Barry Drake, could you please answer the following questions:
+ What is the printer(s) manufacturer and model name?
+ Does the performing the actions noted in https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/1040037/comments/12 provide a WORKAROUND?

Changed in libreoffice (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Barry Drake (b-drake) wrote : Re: [Bug 1040037] Re: Libreoffice will no longer print landscape page

On 20/10/12 20:00, Christopher M. Penalver wrote:
> Barry Drake, could you please answer the following questions:
> + What is the printer(s) manufacturer and model name?
> + Does the performing the actions noted in https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/1040037/comments/12 provide a WORKAROUND?
>

Printer is Brother DCP 135C. I have reported the problem to the Brother
driver maintainer. The driver is provided as open-source.

I will have to investigate the workaround in the next day or two and
will report further.

--
Barry Drake is a member of the the Ubuntu Advertising team.
http://ubuntuadverts.org/

Revision history for this message
Barry Drake (b-drake) wrote :

I have now tried the workaround and the result is exactly the same. My only workaround currently is to export the file as a pdf and print that using the pdf viewer.

Revision history for this message
penalvch (penalvch) wrote :

Barry Drake, thank you for providing your results. Regarding your Bug Description:
>"Since update yesterday..."

What precisely did you update? Did you update from Precise? Updated your cups and/or libreoffice package?

description: updated
Revision history for this message
Barry Drake (b-drake) wrote :

The update referred to was the Ubuntu update for the day using update manager. It included updates for both cups and the libreoffice package.

penalvch (penalvch)
Changed in libreoffice (Ubuntu):
status: Incomplete → New
Revision history for this message
Jan Taborsky (jantaborsky) wrote :

Affects me too, since release upgrade from precise.

However, setting printer language to postscript (level from driver) DOES provide a workaround.

libreoffice-writer:
  Installed: 1:3.6.2~rc2-0ubuntu3
  Candidate: 1:3.6.2~rc2-0ubuntu3
  Version table:
 *** 1:3.6.2~rc2-0ubuntu3 0
        500 http://cz.archive.ubuntu.com/ubuntu/ quantal/main amd64 Packages
        100 /var/lib/dpkg/status

The printer is an old HP Laserjet 5L.

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in libreoffice (Ubuntu):
status: New → Confirmed
Revision history for this message
penalvch (penalvch) wrote :

Jan Taborsky, if you have a bug in Ubuntu, could you please file a new report by executing the following in a terminal:
ubuntu-bug cups

For more on this, please see the Ubuntu Bug Control and Ubuntu Bug Squad article:
https://wiki.ubuntu.com/Bugs/BestPractices#X.2BAC8-Reporting.Focus_on_One_Issue

and Ubuntu Community article:
https://help.ubuntu.com/community/ReportingBugs

When opening up the new report, please feel free to subscribe me to it. Thank you for your understanding.

Revision history for this message
penalvch (penalvch) wrote :

Barry Drake, regarding your comments https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/1040037/comments/14 :
>"I have reported the problem to the Brother driver maintainer. The driver is provided as open-source."

Did you file this in a bug tracker? If so, what is the URL?

As well, do you have this same problem printing to other printers?

description: updated
Changed in libreoffice (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Barry Drake (b-drake) wrote :

There is no bug tracker for Brother drivers. I posted the problem at: http://www.brother.co.uk/g3.cfm/s_page/110100

I will need to borrow a printer to check out whether I have the problem with other printers. Will report further in a day or two.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Can everyone with this broblem do the following:

Follow the instructions of the sections "CUPS error_log" and "Capturing print job data" on https://wiki.ubuntu.com/DebuggingPrintingProblems for the failing case (output file format must be PDF). Also attach the original LibreOffice file and the PDF file generated when you use "Export to PDF".

It would also be great if you do the same on Ubuntu 12.04 (where it does not fail).

Another interesting test would be to take the captured print output of 12.04 and print it with

lpr file.pdf

on 12.10 and vice versa. Does this work?

Changed in cups (Ubuntu):
status: Confirmed → Incomplete
affects: cups (Ubuntu) → cups-filters (Ubuntu)
Changed in cups-filters (Ubuntu):
importance: Undecided → Medium
Revision history for this message
Barry Drake (b-drake) wrote :

Have carried out the capture as above. The resulting pdf file from the cups spool is properly formatted as landscape and prints correctly from the pdf viewer. This is attached as test.pdf

Revision history for this message
Barry Drake (b-drake) wrote :

Here is the libreoffice original.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Bug 1070510 is probably the same problem.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

On my printers the file comes out correctly. Can you attach the PPD file of the printer(s) where the problem occurs (from /etc/cups/ppd/). Thanks.

Revision history for this message
Barry Drake (b-drake) wrote :

As requuested.

Revision history for this message
Barry Drake (b-drake) wrote :

At the moment, I don't have any other USB printers. I'm going to see if I can manage to put 12.10 onto an older PC which has an LPT printer port as I have a couple of paralell port printers I can try.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Barry, thanks. You do not need to worry about the connection type, the problem is independent of how the printer is connected (would also occur with network printers).

It looks like a bug in Ghostscript, which has to convert the PDF input file into PCL (the language of the printer). It seems that for some PDF files Ghostscript does not manage to rotate the content by 90 degrees so that it fits onto the sheet.

Please follow the instructions of the sections "CUPS error_log" on https://wiki.ubuntu.com/DebuggingPrintingProblems.

affects: cups-filters (Ubuntu) → ghostscript (Ubuntu)
Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

After some testing with your files on Precise and Quantal I have found out that the problem is in the new pdftopdf filter of the cups-filters package.

Thank you for your files.

affects: ghostscript (Ubuntu) → cups-filters (Ubuntu)
Changed in cups-filters (Ubuntu):
status: Incomplete → Confirmed
importance: Medium → High
milestone: none → quantal-updates
assignee: nobody → Till Kamppeter (till-kamppeter)
Changed in libreoffice (Ubuntu):
status: Incomplete → Invalid
Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Reported bug to cups-filters upstream as

https://bugs.linuxfoundation.org/show_bug.cgi?id=1080

Revision history for this message
Barry Drake (b-drake) wrote :

Here is the error log requested.

Revision history for this message
Barry Drake (b-drake) wrote :

Sorry - forgot to attach it ... here it is:

Revision history for this message
Jan Taborsky (jantaborsky) wrote :

Well I guess after reporting the bug upstream you don't need my files anymore.

Anyways, if you want me to do some more testing I'm ready to do it.

Revision history for this message
In , Lior Kaplan (kaplan) wrote :

Created attachment 69672
Switch to printer langauge Postscript level 2 as default (regenerated)

I regenerated Jaroslav's patch and sent it for review at https://gerrit.libreoffice.org/1003

Revision history for this message
In , Michael Meeks (michael-meeks) wrote :

In general, switching back to PS is a retrograde step and I'm pretty certain we don't want to do that - but I'll seek advice from our cups maintainers :-)
Michael Stahl did a nice write-up here:

http://lists.freedesktop.org/archives/libreoffice/2012-November/040835.html

Changed in cups:
importance: Unknown → Critical
status: Unknown → Confirmed
Revision history for this message
Barry Drake (b-drake) wrote :

Just to say the latest cups updates have fixed the problem (at least in 13.04 testing).

Revision history for this message
Marius B. Kotsbak (mariusko) wrote :

I still experience this in Quantal with all updates installed.

Changed in cups-filters (Ubuntu):
status: Confirmed → Triaged
Changed in libreoffice (Ubuntu Quantal):
status: New → Invalid
Changed in cups-filters (Ubuntu Quantal):
status: New → Triaged
milestone: none → quantal-updates
Changed in cups-filters (Ubuntu):
milestone: quantal-updates → ubuntu-13.04-feature-freeze
Changed in cups-filters (Ubuntu Quantal):
assignee: nobody → Till Kamppeter (till-kamppeter)
importance: Undecided → High
Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Problem fixed upstream, fix will be included in the next cups-filters package.

Revision history for this message
Jan Taborsky (jantaborsky) wrote :

This is great news, thank you.

Changed in cups:
status: Confirmed → Fix Released
Revision history for this message
Marius B. Kotsbak (mariusko) wrote :

This is so important that the fix should be backported to Quantal.

Changed in cups-filters (Ubuntu):
status: Triaged → Fix Committed
Revision history for this message
In , Libreoffice-bugs (libreoffice-bugs) wrote :

Caolan McNamara committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=59b98580bfd70205a9ebdb0ba67e74225d875b43

Resolves: fdo#44664 Provide a way to set the default print job format.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds
Affected users are encouraged to test the fix and report feedback.

Changed in cups-filters (Ubuntu Quantal):
status: Triaged → In Progress
Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Uploaded fixed package for Quantal to -proposed, fixing bug 1084534, bug 1076786, and bug 1040037. As soon as the package will get approved, please install it according to the instructions posted here then and test it. Your test results are required to make the package an official update for Quantal.

To the SRU team: debdiff attached.

description: updated
Revision history for this message
In , Sasha-libreoffice (sasha-libreoffice) wrote :

Very much thanks for fixing this bug

Revision history for this message
In , Libreoffice-bugs (libreoffice-bugs) wrote :

Caolan McNamara committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=08597f2897e5ac752147c8f2c4a91bb557ed4580

Related: fdo#44664 spadmin support for forcing "postscript of driver level"

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds
Affected users are encouraged to test the fix and report feedback.

Revision history for this message
In , Caolanm (caolanm) wrote :

So...

cups recommends PDF as the standard print job format and I don't want to revert back to postscript as the standard print job format because there are fairly compelling features that using PDF enables.

That said, given the big pile of duplicate bugs here, there are clearly either a lot of buggy cups+pdf stacks out there or there's something about our PDF output that trips something up and using postscript is the only known workaround.

To that end...

a) In any version of LibreOffice in the print dialog or in "printer options" you can temporarily override the default print job format for that document for the current session. That won't "stick" permanently (it's not supposed to).
b) In spadmin it *should* have been possible to override the print job format permanently an individual printers as a workaround. That didn't work and is now fixed on master as 08597f2897e5ac752147c8f2c4a91bb557ed4580
b) In LibreOffice 4 under tools->options->print there is now an additional checkbox to disable using PDF as the default print job format for all printers as 59b98580bfd70205a9ebdb0ba67e74225d875b43

Working under the assumption that the problem is not in our PDF output, but instead is due to probably multiple different bugs in probably multiple pieces of the cups stack, this is the best I think we can do on our side.

See http://fedoraproject.org/wiki/How_to_debug_printing_problems#Finding_where_the_problem_lies for a useful guide to finding what component in the cups stack that might be causing your individual problems in order to track down the root causes.

If anyone has any evidence that there really is a fault in our PDF generation then please open a new bug for that.

Revision history for this message
In , Till Kamppeter (till-kamppeter) wrote :

The pdftopdf filter of cups-filters 1.0.25 (issued yesterday) has auto-rotation functionality added to fix this problem. See

https://bugs.linuxfoundation.org/show_bug.cgi?id=1080

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package cups-filters - 1.0.25-1

---------------
cups-filters (1.0.25-1) experimental; urgency=low

  * New upstream release
     - urftopdf: Newly added filter to convert the URF format which (at
       least some) iOS apps send when printing via AirPrint (Upstream bug
       #1076).
     - pdftopdf: pdfautorotate functionality has been patched directly
       into pdftopdf (LP: #1040037, Upstream bug #1080).
     - pdftopdf: "mirror" produced only empty pages (XObjects not there).
     - pdftopdf: Fixed segfault on "page-ranges=1-2147483647" (from cups).
     - pdftopdf: Fixed collate filler insertion.
     - texttopdf: Fixed deficient string escaping (Upstream bug #1071).
     - serial backend: Added check for sys/ioctl.h to configure.ac (Upstream bug
       #1069).
  * debian/patches/texttopdf-fix-deficient-string-escaping.patch: Removed
    fix backported from upstream.
  * debian/rules: Added "DEB_DH_FIXPERMS_ARGS := -Xusr/lib/cups/backend" to not
    correct the permissions of CUPS backends (LP: #1076786).

 -- Till Kamppeter <email address hidden> Wed, 28 Nov 2012 20:14:07 +0100

Changed in cups-filters (Ubuntu):
status: Fix Committed → Fix Released
Changed in df-libreoffice:
importance: Unknown → High
status: Unknown → Fix Released
Revision history for this message
Barry Drake (b-drake) wrote :

The fix in CUPS filters has now appeared in Raring, but not so far in Quantal.

Revision history for this message
Adam Conrad (adconrad) wrote : Please test proposed package

Hello Barry, or anyone else affected,

Accepted cups-filters into quantal-proposed. The package will build now and be available at http://launchpad.net/ubuntu/+source/cups-filters/1.0.24-2ubuntu0.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!

Changed in cups-filters (Ubuntu Quantal):
status: In Progress → Fix Committed
tags: added: verification-needed
Revision history for this message
jhoechtl (johann-hoechtl) wrote :

I installed stock cups-filters (1.0.24-2ubuntu0.1) quantal-proposed and landscape-printing now works in libreoffice without the Postscript-level workaround as well as in other applications using the cups pdf printing stack. Great!

Revision history for this message
Barry Drake (b-drake) wrote :

This works OK for me. Don't think I have access to add or change bug tags. Please mark verification done.

tags: added: regression-updateverification-done
removed: regression-update verification-needed
tags: added: regression-update verification-done
removed: regression-updateverification-done
Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Also the reporter of duplicate bug 1086905 confirms that the proposed package solves his problem.

Revision history for this message
In , Michael Meeks (michael-meeks) wrote :

Thanks Till - so we don't need to start parsing the PPDs and black-listing known-broken printer drivers based on:

> If any of those attributes says the driver can handle
> "application/vnd.cups-pdf" or "application/vnd.cups-postscript" by
> running a program to do it (i.e. any filter other than "-"),

cf. mail on dev-list ;-) if so that's a relief. Thanks for fixing it.

Revision history for this message
Tim Wiel (timwiel) wrote :

this problem also seems to affect Firefox 17.0.1 on Precise 12.04.1LTS with cups-filters 1.0.18-0ubuntu0.1

printing to landscape mode doesn't work - the page physically prints in portrait with the printout cut off the right of the landscape page text

Revision history for this message
Tim Wiel (timwiel) wrote :

regarding my last comment about this bug on Precise - it can be fixed (at least on a Brother HL 2250DN printer with cupswrapperhl2250dn 2.0.4-2 drivers) by the following "FIX" :

Applications -> Printing ..... Right click on printer and go properties

In properties click on Job Options and then under common options change Orientation to "Portrait (No Rotation)" - it seems to force the landscape to orient the correct way on the page

I hope that helps someone that this bug is driving insane in Precise....

Revision history for this message
Colin Watson (cjwatson) wrote : Update Released

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.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package cups-filters - 1.0.24-2ubuntu0.1

---------------
cups-filters (1.0.24-2ubuntu0.1) quantal-proposed; urgency=low

  * debian/patches/pdftopdf-landscape-fix.patch: Auto-rotate functionality
    added to pdftopdf to print landscape-formatted PDFs (for example from
    LibreOffice) correctly (LP: #1040037, Upstream bug #1080).
  * debian/patches/pdftopdf-multiple-copies-collate-fix.patch: The pdftopdf
    filter started the second copy of a duplex job with an odd number of
    pages on the back side of the last page of the first copy. Thanks to
    David Williams from Ricoh for reporting this and to Tobias Hoffmann for
    fixing this (LP: #1084534).
  * debian/rules: Added "DEB_DH_FIXPERMS_ARGS := -Xusr/lib/cups/backend" to not
    correct the permissions of CUPS backends (LP: #1076786).
 -- Till Kamppeter <email address hidden> Thu, 29 Nov 2012 16:59:59 +0100

Changed in cups-filters (Ubuntu Quantal):
status: Fix Committed → Fix Released
Revision history for this message
Tim Wiel (timwiel) wrote :

Is there any reason why this hasn't been backported to precise - it also effects that distrubition and it is still an active LTS

Revision history for this message
penalvch (penalvch) wrote :

Tim Wiel, this is a significant bug in Ubuntu. If you need a fix for the bug in previous versions of Ubuntu, please do steps 1 and 2 of the SRU Procedure [1] to bring the need to a developer's attention.

[1]: https://wiki.ubuntu.com/StableReleaseUpdates#Procedure

Revision history for this message
In , Toddandmargo-n (toddandmargo-n) wrote :

$ cat /etc/redhat-release
Scientific Linux release 6.4 (Carbon)

$ uname -r
2.6.32-358.11.1.el6.x86_64

$ rpm -qa cups
cups-1.4.2-50.el6_4.4.x86_64

$ rpm -qa libreoffice\*
libreoffice4.0-writer-4.0.4.2-2.x86_64

Problem still exists and is not resolved. In every other program, landscape and portrait are respected. Word Pro, thought Wine and CUPS, prints center positioned, landscape envelopes properly.

I appreciate you reopening this.

Many thanks,
-T

Revision history for this message
In , Jmadero-dev (jmadero-dev) wrote :

Moving to 3.6 MAB as 3.5 is EOL

Changed in df-libreoffice:
status: Fix Released → Confirmed
Revision history for this message
In , Caolanm (caolanm) wrote :

a) In any version of LibreOffice in the print dialog or in "printer options" you can temporarily override the default print job format for that document for the current session. That won't "stick" permanently (it's not supposed to).
b) In spadmin it *should* have been possible to override the print job format permanently an individual printers as a workaround. That didn't work and is now fixed on master as 08597f2897e5ac752147c8f2c4a91bb557ed4580
b) In LibreOffice 4 under tools->options->print there is now an additional checkbox to disable using PDF as the default print job format for all printers as 59b98580bfd70205a9ebdb0ba67e74225d875b43

Working under the assumption that the problem is not in our PDF output, but instead is due to probably multiple different bugs in probably multiple pieces of the cups stack, this is the best I think we can do on our side.

See http://fedoraproject.org/wiki/How_to_debug_printing_problems#Finding_where_the_problem_lies for a useful guide to finding what component in the cups stack that might be causing your individual problems in order to track down the root causes.

If anyone has any evidence that there really is a fault in our PDF generation then please open a new bug for that.

Revision history for this message
In , chris (ign-christian) wrote :

*** Bug 58884 has been marked as a duplicate of this bug. ***

Changed in df-libreoffice:
status: Confirmed → Fix Released
Revision history for this message
In , Till Kamppeter (till-kamppeter) wrote :

One additional remark to my comment #55: The pdftopdf filter does the auto-rotation by setting the rotation fields of the pages in the PDF file. This rotation field is ignored by "pdftops -origpagesizes" (as pdftops is called by cups-filters). I have fixed this in Poppler. See bug #72312 and also BZR rev. 7131 in cups-filters upstream.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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