Bug 54985 - khtml printing accomodates long unwrapped text by severely scaling page
Summary: khtml printing accomodates long unwrapped text by severely scaling page
Status: RESOLVED LATER
Alias: None
Product: konqueror
Classification: Applications
Component: khtml printing (show other bugs)
Version: 3.5
Platform: Unlisted Binaries Linux
: NOR major
Target Milestone: ---
Assignee: Konqueror Developers
URL:
Keywords:
: 45935 121763 139968 (view as bug list)
Depends on:
Blocks:
 
Reported: 2003-02-21 20:05 UTC by Joseph Reagle
Modified: 2008-04-21 10:13 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
This is the example file (14.60 KB, text/html)
2003-11-09 22:55 UTC, Joseph Reagle
Details
I won't print (1.09 KB, text/html)
2007-01-13 11:47 UTC, illogic-al
Details
I will print (740 bytes, text/html)
2007-01-13 11:52 UTC, illogic-al
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Joseph Reagle 2003-02-21 20:05:32 UTC
Version:            (using KDE KDE 3.1)
Installed from:    Debian testing/unstable Packages
OS:          Linux

In Konqueror, if you have a page with a very long preformatted <pre> element, the whole page/document is scaled to accomodate that one line. It's a good effort but can render the printout useless. It'd be nice if it tried, but if the page get's scaled greater than 80%, the the line is simply cut off at the margin.
Comment 1 Michael Goffioul 2003-02-24 09:40:12 UTC
This is how konqueror/khtml works internally. KDEPrint is not responsible
of what is printed and how it gets printed.

Michael.
Comment 2 Stephan Kulow 2003-11-08 19:33:53 UTC
any test case?
Comment 3 Joseph Reagle 2003-11-09 22:55:07 UTC
Created attachment 3117 [details]
This is the example file

Print preview this html file, and you'll see what I mean.
Comment 4 Joseph Reagle 2004-03-13 18:22:55 UTC
Still present in KDE 3.2.1 Debian/Unstable.
Comment 5 Maksim Orlovich 2004-06-10 23:15:56 UTC
*** Bug 45935 has been marked as a duplicate of this bug. ***
Comment 6 Michael Schuerig 2004-08-12 23:46:35 UTC
This "feature" has given me quite a number of printed pages that are completely unreadable. It may be sensible to scale images, it's not sensible at all to scale text. Instead, the stylesheet(s) should be honored, in particular the "@media print"-specific definitions.

Regarding overlong <pre>-lines, they should either be cut off, or wrapped. In the latter case preferrably with a visual indication that this happened.

Michael
Comment 7 Joseph Reagle 2004-09-07 16:10:18 UTC
Still present in 3.3.0 ... Is this report just being ignored?
Comment 8 lexual 2005-04-18 04:24:03 UTC
confirming for 3.4.0
Comment 9 Pavel Simerda 2005-05-26 18:43:24 UTC
hmm, that's bad
Comment 10 Allan Sandfeld 2005-07-13 23:37:05 UTC
The question is how wide in pixels the page should be considered. 

Currently we fit webpages to a sheet by scaling the width.
Comment 11 Pavel Simerda 2006-02-09 23:42:30 UTC
Is there any progress?
Comment 12 Allan Sandfeld 2006-10-24 23:21:29 UTC
*** Bug 121763 has been marked as a duplicate of this bug. ***
Comment 13 solsTiCe 2006-10-25 22:22:55 UTC
still in kde 3.5.4 
seems to be on the list of the bug to be never fixed 
Comment 14 Kurt Pfeifle 2007-01-07 19:24:09 UTC
Bug still present in KDE 3.5.5

(made also $subject more precise)
Comment 15 Kurt Pfeifle 2007-01-13 02:00:42 UTC
*** Bug 139968 has been marked as a duplicate of this bug. ***
Comment 16 illogic-al 2007-01-13 11:38:54 UTC
Something abstracted from heise.de which demonstrates the problem nicely. 
Two files are going to be uploaded below: one with a long url, and the other without. 
Viewing the two html files in konq produces a page which displays nothing, and one which displays everything. Testcase shows all.
Comment 17 illogic-al 2007-01-13 11:47:26 UTC
Created attachment 19271 [details]
I won't print

Won't print even though text shows up fine in konqueror
Comment 19 illogic-al 2007-01-13 11:52:42 UTC
Created attachment 19272 [details]
I will print

Segment of unwrapped text remove which "prints" 
(used print to pdf function to test these)
Comment 20 jtscsousa 2007-08-17 12:15:34 UTC
Bug still present in KDE 3.5.7 (Debian Package 4:3.5.7.dfsg.1-4 (lenny/sid)).

I was printing django documentation using konqueror (http://www.djangoproject.com/documentation/0.96/newforms/) and the result was 3 illegible pages.

I then printed the same webpage with firefox and it produced 15 pages with truncated text... It's a bit disappointing. There should be some sort of escape from this all or nothing default behaviour(s). Perhaps a warning or configuration option where you choose if you want to shrink the text, truncate long lines or force the long lines to wrap.
Comment 21 Viktor Horvath 2007-11-11 13:34:20 UTC
A possibility to choose the font size, in combination with the existing preview, would not only eliminate this bug, but also a huge pile of others, and it would remove the need for any "intelligence" to find out whether to shrink the page automatically or not.

Using Konqueror/KDE 3.5.8 on Debian unstable.

<rant>
It's a bit sad... I have exactly on of the Heise webpages as mentioned in #16 and can't print it in Konqueror nicely, nor can I print it in Iceweasel nicely - there you can set the font size, but the end of the lines are not printed. In summary: Printing with the two major GNU/Linux browsers is not very robust in the end of 2007... :-/
</rant>
Comment 22 Michael Leupold 2008-04-06 06:26:32 UTC
Both testcases work fine on trunk r793971.
Comment 23 Michael Leupold 2008-04-09 11:34:05 UTC
This problem persists in 3.5.9 but is fixed in trunk r793791.
Comment 24 Michael Leupold 2008-04-09 12:36:14 UTC
reopening as still present in 3.5.9.
Comment 25 Michael Leupold 2008-04-21 10:13:54 UTC
Qualifies for backporting to the 3.x branch.