Printing from KDE4 apps cuts off, non-KDE apps print fine

Bug #284730 reported by Bruce Miller
20
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Qt
Fix Released
Medium
qt4-x11 (Ubuntu)
New
Undecided
Unassigned

Bug Description

I am unable to print from KDE4 applications (primarily, but not exclusively, Konqueror and Kate). I have had this problem on several instances of Kubuntu: on different physical machines, on three consecutive distributions of Kubuntu (7.10, 8.04 and 8.10 development) and despite many more bare metal OS re-installs than the stability of Linux would justify.

This bug report follows up my reopening Bug 29622 which deals specifically with headers and footers. They have never printed from Konqueror/KDE4. The problems go far beyond this.

This bug reports testing Konqueror v4.1.2 on KDE v4.1.2 running Kubuntu Intrepid Ibex beta (from a fresh install a few days after the beta was released and fully dist-upgraded at least twice a day). I have had comparable problems printing from kate.

I am printing to an ancient HP LaserJet 4L. I am in Canada; my paper type is set to US Letter. The default margins of the printer driver are set to the printer manufacturer's specified published imageable area, namely 0.5" top and bottom and 0.25" left and right.

I tested with a blog which I read regularly: http://thoughtsontranslation.com/. I did a control by printing the same page from Firefox (Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.0.3) Gecko/2008101315 Ubuntu/8.10 (intrepid) Firefox/3.0.3). In Firefox, I used the US Letter HP LJ predefined paper size. The blog printed over six pages. All text was printed. The graphic near the top of the page did not print in either Firefox or Konqueror. The list of links in the right-hand frame printed below the central frame.

The Konqueror output was 10 pages as follows:
no headers or footers on any page
page 1: bullet list from the row of four "tabs" at the top of the page. The fourth bullet is bare;
page 2: faint outline of a search box close to the top of the page
page 3: search button from search box; heading and subheading; beginning of main text
pages 3 through 6: main text; approximately 2.75 lines of text missing in each page break (i.e. two lines missing completely, the bottom of third line visible but cut off at the top of each page)
pages 6 through 8: right frame with many links; also with approximately 2.75 lines missing in each page break
page 9: faint outline of a search box about 2.375" from top of page (cf. page 2 above)
page 10: search button; "credits" line (Blog at WordPress.com | Theme: ...

I repeat that no headers or footers printed.

This has been a consistent experience with any attempt to print from a KDE4 application under Kubuntu.

My setup is:
bruce@Xenophon:~$ uname -a
Linux Xenophon 2.6.27-7-generic #1 SMP Tue Oct 14 18:38:59 UTC 2008 x86_64 GNU/Linux
bruce@Xenophon:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu intrepid (development branch)
Release: 8.10
Codename: intrepid
bruce@Xenophon:~$

Revision history for this message
Ian Weisser (ian-weisser) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. You reported this bug a while ago and there hasn't been any activity in it recently. We were wondering is this still an issue for you? Can you try with latest Ubuntu release? Thanks in advance.

Revision history for this message
Bruce Miller (brm0423) wrote :

This bug remains unresolved. The symptoms have now changed slightly. When I print a document from kate, the footers print. The header does not print. The first 1.75 lines of each page are also truncated when printed either to paper or to a PDF virtual printer. With the missing header, 2.75 lines at the top of each page are lost. I believe that my font setting for kate is default: DejaVu Sans mono 9pt.

To the best of my ability and memory, all my KDE settings reflect my circumstances in Canada: using both official languages frequently and using only American paper types and Imperial measurements to measure the paper.

I am currently running the experimental ppa builds of KDE4.2. There was a longish power failure in my neighbourhood this morning and I have therefore had to restart the machine. I am thus running the most up-to-date version possible of Kubuntu Intrepid.

I have had these problems with all versions of Kubuntu KDE 4.x from late betas of 4.0 through the current betas of 4.2. Over the last year, I have done at least two (probably more) bare metal reinstalls of Kubuntu as part of my hobbyist rotation of distributions.

bruce@Xenophon:~$ uname -a
Linux Xenophon 2.6.27-9-generic #1 SMP Thu Nov 20 22:15:32 UTC 2008 x86_64 GNU/Linux
bruce@Xenophon:~$ dpkg -l | grep nightly
ii amarok-nightly-qt 20081024.6+svn875337-0neon1 Qt 4 core GUI functionality runtime library
ii kde-nightly 1.9 Project Neon (KDE Nightly)
ii kde-nightly-kdebase 20081227+svn902001-0neon1 runtime components from the official KDE release
ii kde-nightly-kdegraphics 20081227+svn902002-0neon1 KDE graphic applications (nightly build)
ii kde-nightly-kdelibs 20081227+svn902001-0neon1 core libraries for all KDE 4 applications
ii kde-nightly-kdemultimedia 20081227+svn902002-0neon1 KDE multimedia applications (nightly build)
ii kde-nightly-kdenetwork 20081227+svn902003-0neon1 KDE network applications (nightly build)
ii kde-nightly-kdepimlibs 20081227+svn902002-0neon1 core libraries for KDE PIM 4 applications
ii kde-nightly-kdesupport 20081227+svn902000-0neon1 KDESupport stuff
bruce@Xenophon:~$

Revision history for this message
Ian Weisser (ian-weisser) wrote :

Do you use CUPS or a different printing system?
What is the result of printing a test page using the command line (lpr or another print app unrelated to KDE)?

Thanks in advance.

Revision history for this message
Bruce Miller (brm0423) wrote :
Download full text (3.5 KiB)

Thanks for reply. I should have mentioned yesterday that applications unrelated to KDE print perfectly routinely, e.g. Firefox. Thus, while I use kate for much drafting, I have to use gedit for printing.

The print system is the standard CUPS as installed by Kubuntu 8.10 on 2008-10-29.

bruce@Xenophon:~$ dpkg -l | grep cups
ii bluez-cups 4.12-0ubuntu5 Bluetooth printer driver for CUPS
ii cups 1.3.9-2ubuntu4 Common UNIX Printing System(tm) - server
ii cups-bsd 1.3.9-2ubuntu4 Common UNIX Printing System(tm) - BSD commands
ii cups-client 1.3.9-2ubuntu4 Common UNIX Printing System(tm) - client programs (SysV)
ii cups-common 1.3.9-2ubuntu4 Common UNIX Printing System(tm) - common files
ii cups-driver-gutenprint 5.2.0~rc1-0ubuntu1 printer drivers for CUPS
ii cups-pdf 2.4.8-1ubuntu1 PDF printer for CUPS
ii cupsddk 1.2.3-3 CUPS Driver Development Kit
ii cupsddk-drivers 1.2.3-3 CUPS Driver Development Kit - Driver files
ii cupsys 1.3.9-2ubuntu4 Common UNIX Printing System (transitional package)
ii cupsys-bsd 1.3.9-2ubuntu4 Common UNIX Printing System (transitional package)
ii cupsys-client 1.3.9-2ubuntu4 Common UNIX Printing System (transitional package)
ii cupsys-common 1.3.9-2ubuntu4 Common UNIX Printing System (transitional package)
ii cupsys-driver-gutenprint 5.2.0~rc1-0ubuntu1 Transitional package
ii hal-cups-utils 0.6.17+git20080728-0ubuntu2 CUPS integration with HAL
ii libcups2 1.3.9-2ubuntu4 Common UNIX Printing System(tm) - libs
ii libcupsimage2 1.3.9-2ubuntu4 Common UNIX Printing System(tm) - image libs
ii libcupsys2 1.3.9-2ubuntu4 Common UNIX Printing System (transitional package)
ii libgnomecups1.0-1 0.2.3-2build1 GNOME library for...

Read more...

Revision history for this message
Jonathan Thomas (echidnaman) wrote :

In KDE4, applications use the Qt printing system.

Revision history for this message
Bruce Miller (brm0423) wrote :

To my surprise and disappointment, it appears that I had not yet filed a corresponding bug report on the KDE Bugzilla. The following is, at least, substantially similar to my report: https://bugs.kde.org/show_bug.cgi?id=164899.

Changed in qt:
status: Unknown → Confirmed
Revision history for this message
Bruce Miller (brm0423) wrote :

This follows up my commentary of 2008-12-29. There has obviously been work on the overall issue of KDE printing but the basic problem of truncated text remains unresolved. New problems appear to have been introduced.

I am currently running Kubuntu Jaunty Jackalope beta, fully updated twice a day. KDE is thus at version 4:4.2.2-0ubuntu3 and Qt at 4.5.0-0ubuntu4.

When one prints a document from kate on my ancient HP LaserJet 4L without changing the en-CA defaults, the header is printed but a couple of lines of text and the footer are cut off the bottom. The printed area is 10.5" long by 7.6" wide. This disregards the default margins of T=0.5", L=0.25", R=0.25", B=0.5". Parenthetically, it also demonstrates that HP's ~25-year old published maximum imageable area of 10" height is not rigidly enforced.

As soon as one alters the margins under Print Properties in the application print dialogue --- at least by increasing the margins --- the document is formatted in accordance with the changed margins, and the header and footer are now both printed. However, one line of text at the bottom of each page continues to be truncated.

I tried altering the printer defaults under |System Settings |Advanced |System |Printer Configuration |Local Printer |HP LaserJet 4L| Job Options. I was careful to "apply" (i.e. to save) the changes and returned to kate. The "defaults" which kate brought up were the distribution defaults, not the ones I had just adjusted in System Settings. What was even more interesting is that when I returned to System Settings, the recently changed settings appeared on the "page", but the "Apply" button was once again highlighted and the customary "unsaved changes" warning appeared if I tried to navigate away from the page. It would appear that opening the Printer Properties box in kate somehow triggers a "changed settings" flag in the configuration file.

Revision history for this message
Mark Rose (markrose) wrote :

This bug is still present in KDE 4.2.3.

It applies with both a brand new Canon MF4270 and an ancient HP Laserjet 1000 series printers.

Revision history for this message
SteveG (steve-fpig) wrote :

I can confirm this bug still exists in kubuntu 9.04 kde version 4:4.2.3-0, qt4 version 4.5.0. When printing from kate the top margin or paper size is set incorrectly and the page header is cut off.

This applies to both HP inkjet printers and Xerox laser printers (and probably any other printer).

Revision history for this message
Jim Phelps (jimtrish) wrote :

I just encountered this bug in Fedora 10, KDE 4.1.2 when attempting to use KWrite to print a multi-page
text file to an EPSON C-62 ink-jet printer using CUPS.

n my case, using KWrite and printer defaults, the last line of text, along with the footer are not
printed on each page. That is, when printing a test text file consisting of 69 lines, the header and
52 lines are printed on page 1 (using default monospace/Regular/10pt font). Page two begins
with the header and line 54 (line 53 is missing). No footer is printed on any page.

If I do Ctrl/P->'Printer Properties', and set top and bottom margins,
the printing can be corrected, but these settings are not retained between printings.

If I go to Administration->printing->printer->properties I can set margins
that are preserved, but the bottom margin is ignored. I set it to 100 points
and the last line (52) is still printed at the very bottom of the page and line 53
and footers are missing.

The CUPS printer Test page (Administration->printing->printer->properties->Print Test)
appears to print correctly.

Revision history for this message
Thomas Ohms (tohms) wrote :

I also can confirm this bug. Only that I have a bit different configuration, but issue's same:
I have a PDF Printer running and modified its corresponding ppd file for default margins in ImageableArea.
If printing from let's say kate directly margins are ignored. But if I go into properties dialog before printing I can see my margins set. I than don't change anything and just click "OK". Now margins are set correctly.
Seems KDE apps ignoring margins by default or printer dialog starts with a default margin of 0?!

Changed in qt:
importance: Unknown → Medium
Changed in qt:
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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