Last Comment Bug 311028 - Print Preview window is partly overlayed by background and is missing scrollbars
: Print Preview window is partly overlayed by background and is missing scrollbars
Status: VERIFIED FIXED
: fixed-seamonkey1.1a, fixed1.8.1, regression
Product: Core
Classification: Components
Component: Print Preview (show other bugs)
: Trunk
: x86 All
: -- normal with 3 votes (vote)
: mozilla1.8.1
Assigned To: Ian Neal
:
:
Mentors:
: 129033 291497 325010 339956 350592 355911 356231 (view as bug list)
Depends on: 351913
Blocks: 231894 324141 326480
  Show dependency treegraph
 
Reported: 2005-10-04 01:44 PDT by Adam Hauner
Modified: 2011-02-22 16:09 PST (History)
22 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Port printutils patch v0.1a (58.46 KB, patch)
2005-11-16 17:03 PST, Ian Neal
no flags Details | Diff | Splinter Review
Revised port of printutils patch v0.1b (53.09 KB, patch)
2005-12-21 15:34 PST, Ian Neal
neil: review+
Details | Diff | Splinter Review
Collapsed browser patch v0.1c (106.28 KB, patch)
2005-12-28 16:49 PST, Ian Neal
neil: review+
mozilla: superreview+
Details | Diff | Splinter Review
Non duplicated patch v0.1c (53.14 KB, patch)
2005-12-30 16:23 PST, Ian Neal
iann_bugzilla: review+
iann_bugzilla: superreview+
Details | Diff | Splinter Review
Non-allcaps patch with editor/mail changes too v0.1d (56.39 KB, patch)
2005-12-30 16:32 PST, Ian Neal
no flags Details | Diff | Splinter Review
gInPrintPreviewMode patch v0.1e (Checked into trunk and branch 1.8) (57.01 KB, patch)
2005-12-31 10:16 PST, Ian Neal
neil: review+
mozilla: superreview+
mtschrep: approval1.8.0.1-
mtschrep: approval1.8.1+
Details | Diff | Splinter Review

Description Adam Hauner 2005-10-04 01:44:23 PDT
2004110104/trunk/W2K

Repro:
1. open http://www.pcmag.com/article2/0,1759,1937,00.asp
2. open Print Preview window
3. in Page Setup switch Print Backgrounds

Actual:
Part of Print Preview window is overlayed by XUL default background.

Bug was fixed by Vlad for toolkit, different fix is probably needed for SeaMonkey.
Comment 1 Felix Miata 2005-10-04 11:38:58 PDT
Remains broken in OS/2 trunk 2005100407 -> ALL
Comment 2 Nathan Strom 2005-10-04 11:51:01 PDT
I see this as well in 1.5b1 on Windows (Mozilla/5.0 (Windows; U; Windows NT 5.0;
en-US; rv:1.8b4) Gecko/20050908 Firefox/1.4)

Screenshots:
http://img114.imageshack.us/img114/1563/image13va.png (before Print Backgrounds)
http://img114.imageshack.us/img114/3123/image24ti.png (after Print Backgrounds)
Comment 3 Andrew Schultz 2005-10-04 12:19:53 PDT
toolkit bug 267422 and patch attachment 198401 [details] [diff] [review]
Comment 4 Boris Zbarsky [:bz] (still a bit busy) 2005-10-04 16:04:51 PDT
Ian, want to take a stab at this?
Comment 5 Debbie Kraft 2005-10-11 23:54:09 PDT
Confirming with SeaMonkey 1.0a (20050910) on Win 98SE.  This bug *also* occurs
after a scale change is made.  Example: choose another scale percentage from the
drop-down list other than "Shrink to Fit," and bug is seen once new scale
setting has been applied to the preview window.
Comment 6 Robert Kaiser 2005-11-12 08:42:48 PST
Hmm, can someone look into that? It's not visible with default settings, as IIRC backgrounds are off there. Because of this and noone working on it, I'm tempted to mark this one blocking-, so that we'll be able to ship a Beta...
Comment 7 Adam Hauner 2005-11-13 22:56:20 PST
Kairo, try to switch just between Portrait and Landscape mode, bug is also present. Probably any operation in Print Preview, which leads to new re-layout, will cause this bug.
Comment 8 Hermann Schwab 2005-11-15 15:49:51 PST
Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.9a1) Gecko/20051112 SeaMonkey/1.5a 

testing https://bugzilla.mozilla.org/page.cgi?id=fields.html#status
P=Portrait, L=Landscape, H=Horizontal,  V=Vertical Scrollbar

Starting in P-Mode: P: HV -> L: HV -> P:    -> L:  V -> P:    > L:  V ->....
Starting in L-Mode:          L: HV -> P: H  -> L:  V -> P:    > L:  V ->....

Vertical scrollbar: cursorkeys also working
Bug starts with 1st change from L to P, vertical scrollbar gets replaced with XUL background of twice the scrollbar width.
After this switching from P to L re-adds the scrollbar, replacing part of the images, not the background, so now to the right there is one scrollbar width scrollbar, and two widths background.

Horizontal scrollbar: cursorkeys not working
H Scrollbar is hidden on 2nd change:
Open Preview in any mode, H seen, change mode, H seen, change mode, H gone


Also seen on the testpage, but that's another bug: 1st table doesn't fit on page 1, rest lost, 2nd page starts with markup following the 1st table, i.e.  <h2> Severity, and the 2nd table. I'm seeing this in screen resolution 800x600, don't have a printer.
Comment 9 Wayne Mery (:wsmwk, NI for questions) 2005-11-16 14:17:47 PST
does comment 8 implicate bug 130048? (is 130048 even still valid? I don't know enough to judge)

dup bug 291497 to this one?  
Or dup both to ... (take your pick, there are others re: scrollbars)?

nice work Herman - this largely confirms testing I was about to write up :) - curious behavior
Comment 10 Ian Neal 2005-11-16 17:03:38 PST
Created attachment 203322 [details] [diff] [review]
Port printutils patch v0.1a

This patch:
* Port toolkit's print preview system including patch on bug 267422
* Fix mailnews so it can use new print preview system
* Fixes issues with unnecessary redraws eg clicking on Portrait twice
* Fixes issues with page numbers not being reset when scaling / changing orientation
* Fixes issues with page total not being recalculated when scaling / changing orientation
* Backport above issues to toolkit's printpreview system

Other stuff to possibly do:
* Switch NSPrint() calls to PrintUtils.print() calls
* Switch NSPrintSetup() calls to PrintUtils.showPageSetup() calls
Comment 11 Ian Neal 2005-11-16 17:09:01 PST
*** Bug 291497 has been marked as a duplicate of this bug. ***
Comment 12 Stephen Donner [:stephend] 2005-11-16 17:23:47 PST
'worcester12345'--this has nothing to do with Aviary, as they use tookit.  See like, comment 0.
Comment 13 Worcester12345 2005-11-16 17:28:14 PST
(In reply to comment #12)
> 'worcester12345'--this has nothing to do with Aviary, as they use tookit.  See
> like, comment 0.
> 

Sorry. My bad. I bounce back and forth from Firefox to Mozilla Suite often. 
Comment 14 Max Alekseyev 2005-11-16 19:48:16 PST
(In reply to comment #10)
> * Fix mailnews so it can use new print preview system

Is it possible to fix bug 66806 as well?
Comment 15 John T 2005-11-17 03:38:03 PST
This bug was perhaps first reported on 2005-04-22 12:14 PST (#291497). Clicking a full-size window to "restore" size or vice versa fixes the display problem, I think.
Comment 16 John T 2005-12-09 14:59:38 PST
This problem with print preview seems to be fixed in Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.7.12) Gecko/20051208. It displays properly after scale changes.

Comment 17 Stephen Donner [:stephend] 2005-12-10 08:55:13 PST
(In reply to comment #16)
> This problem with print preview seems to be fixed in Mozilla/5.0 (Windows; U;
> Win98; en-US; rv:1.7.12) Gecko/20051208. It displays properly after scale
> changes.

John, this is a regression from 1.8 on that lives in the trunk.  The build you referenced is a branch build, hence why you can't see this bug.
Comment 18 Ian Neal 2005-12-21 15:34:13 PST
Created attachment 206552 [details] [diff] [review]
Revised port of printutils patch v0.1b

Changes since v0.1a:
* Spun off toolkit changes to bug 321153
Comment 19 neil@parkwaycc.co.uk 2005-12-24 14:45:56 PST
Comment on attachment 206552 [details] [diff] [review]
Revised port of printutils patch v0.1b

Well, I guess most of this is moving stuff around so you don't want to fix the nits I mentioned on IRC. I see Print Preview isn't very accessible either, but hiding and showing the toolbar isn't going to help, I'd prefer if you collapse it instead, or better still, collapse the browser, as that looks visually superior to me.
Comment 20 Worcester12345 2005-12-28 07:57:14 PST
(In reply to comment #18)
> Created an attachment (id=206552) [edit]
> Revised port of printutils patch v0.1b
> 
> Changes since v0.1a:
> * Spun off toolkit changes to bug 321153
> 

Should this then be dependent on 321153?
Comment 21 Ian Neal 2005-12-28 16:49:12 PST
Created attachment 207039 [details] [diff] [review]
Collapsed browser patch v0.1c

Changes since v0.1b:
* Fixed typo Prgress -> Progress
* Added missing IID for nsISupports in QueryInterface function
* Collapse browser instead of hiding toolbar
Comment 22 neil@parkwaycc.co.uk 2005-12-29 15:37:33 PST
Comment on attachment 207039 [details] [diff] [review]
Collapsed browser patch v0.1c

r=me if you remove the _debug bits :-P
Comment 23 Ian Neal 2005-12-29 16:02:23 PST
Comment on attachment 207039 [details] [diff] [review]
Collapsed browser patch v0.1c

leaving _debug as is as was put back in after removing in a previous patch - discussed with Neil on IRC
Comment 24 David :Bienvenu 2005-12-29 16:32:52 PST
Comment on attachment 207039 [details] [diff] [review]
Collapsed browser patch v0.1c

why the all upper-case var names? e.g.? Is this a new fad I'm not up on? :-)

+      var PRINTPROMPTSVC = Components.classes["@mozilla.org/embedcomp/printingprompt-service;1"]
+                                     .getService(Components.interfaces.nsIPrintingPromptService);
+      PRINTPROMPTSVC.showPageSetup(window, printSettings, null);

the diffs look like they've got two copies of themselves - I only looked at the first half/copy :-)

Thunderbird seems to use the mailnews version of the affected files (or at least, msgPrintEngine.js but not msgPrintEngine.xul - do you need me to try this patch with thunderbird, or have you tried TB? Does TB need the same changes to its copy of msgPrintEngine.xul)

I'll mark this sr, but please let me know about TB before you checkin.

Thx for doing this!
Comment 25 Ian Neal 2005-12-30 16:23:00 PST
Created attachment 207225 [details] [diff] [review]
Non duplicated patch v0.1c

Correct version without duplicating diff, carrying over r/sr=
Comment 26 Ian Neal 2005-12-30 16:32:53 PST
Created attachment 207227 [details] [diff] [review]
Non-allcaps patch with editor/mail changes too v0.1d

Changes from v0.1c:
* Removed all caps variable names
* Fixed printing.js and editor.js so printing works in composer
* Fixed mail's msgPrintEngine.xul so it works with printing.js

I've created bug 321954 to make printUtils.js easier to hook into (maybe porting some of the changes here to toolkit)
Comment 27 Ian Neal 2005-12-31 10:16:53 PST
Created attachment 207272 [details] [diff] [review]
gInPrintPreviewMode patch v0.1e (Checked into trunk and branch 1.8)

Changes since v0.1d:
* Put gInPrintPreviewMode setting back into browser.js it works in navigator.js
* Removed unused variables gOldCloseHandler and gWebProgress from browser.js
Comment 28 David :Bienvenu 2006-01-04 11:55:36 PST
Comment on attachment 207272 [details] [diff] [review]
gInPrintPreviewMode patch v0.1e (Checked into trunk and branch 1.8)

thx very much for taking this on.
Comment 29 Ian Neal 2006-01-04 15:04:40 PST
Comment on attachment 207272 [details] [diff] [review]
gInPrintPreviewMode patch v0.1e (Checked into trunk and branch 1.8)

Checking in (trunk)
mailnews/base/resources/content/msgPrintEngine.js;
new revision: 1.22; previous revision: 1.21
mailnews/base/resources/content/msgPrintEngine.xul;
new revision: 1.18; previous revision: 1.17
xpfe/browser/resources/content/browser.js;
new revision: 1.35; previous revision: 1.34
xpfe/communicator/resources/content/printing.js;
new revision: 1.9; previous revision: 1.8
xpfe/communicator/resources/content/printPreviewBindings.xml;
new revision: 1.24; previous revision: 1.23
xpfe/communicator/resources/locale/en-US/printPreview.dtd;
new revision: 1.6; previous revision: 1.5
editor/ui/composer/content/editor.js;
new revision: 1.236; previous revision: 1.235
mail/base/content/msgPrintEngine.xul;
new revision: 1.6; previous revision: 1.5
done
Comment 30 Ian Neal 2006-01-04 15:11:06 PST
Comment on attachment 207272 [details] [diff] [review]
gInPrintPreviewMode patch v0.1e (Checked into trunk and branch 1.8)

Requesting approval for landing on 1.8.1 branch, asking for the mail part of the patch (will request SM approval via IRC), would be good to fix this regression.
Comment 31 Ian Neal 2006-01-05 06:55:18 PST
Comment on attachment 207272 [details] [diff] [review]
gInPrintPreviewMode patch v0.1e (Checked into trunk and branch 1.8)

Would also really like to get this into 1.8.0 branch too.
Comment 32 Stephen Donner [:stephend] 2006-01-05 11:45:33 PST
Ian-can you mark this FIXED now that it's landed on the trunk?  I'm all set to verify it (looks good), but I don't want to jump states.
Comment 33 Ian Neal 2006-01-05 13:53:27 PST
-> Fixed as it is on trunk
Comment 34 Stephen Donner [:stephend] 2006-01-05 14:41:04 PST
Verified FIXED on trunk using SeaMonkey 1.5a;Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20060105 Mozilla/1.0

Notes:
* Orientation (Portrait/Landscape) now retains its last state (nice)
* The Portrait and Landscape buttons no longer erroneously accept a click when they're already depressed.
Comment 35 Mike Schroepfer 2006-01-10 13:33:34 PST
Comment on attachment 207272 [details] [diff] [review]
gInPrintPreviewMode patch v0.1e (Checked into trunk and branch 1.8)

a-=schrep 1.8.0 and a+=schrep for 1.8.1 for drivers.   Given the size of the patch would prefer to land for 1.8.1/FF2 timeframe.
Comment 36 Chris Thomas (CTho) [formerly cst@andrew.cmu.edu cst@yecc.com] 2006-01-10 15:29:57 PST
Comment on attachment 207272 [details] [diff] [review]
gInPrintPreviewMode patch v0.1e (Checked into trunk and branch 1.8)

approval-seamonkey1.1=me
Comment 37 Ian Neal 2006-01-10 15:33:25 PST
Comment on attachment 207272 [details] [diff] [review]
gInPrintPreviewMode patch v0.1e (Checked into trunk and branch 1.8)

Checking in (branch 1.8)
mailnews/base/resources/content/msgPrintEngine.js;
new revision: 1.21.4.1; previous revision: 1.21
mailnews/base/resources/content/msgPrintEngine.xul;
new revision: 1.17.8.1; previous revision: 1.17
xpfe/browser/resources/content/browser.js;
new revision: 1.34.12.1; previous revision: 1.34
xpfe/communicator/resources/content/printing.js;
new revision: 1.7.4.2; previous revision: 1.7.4.1
xpfe/communicator/resources/content/printPreviewBindings.xml;
new revision: 1.23.2.1; previous revision: 1.23
xpfe/communicator/resources/locale/en-US/printPreview.dtd;
new revision: 1.5.58.1; previous revision: 1.5
editor/ui/composer/content/editor.js;
new revision: 1.235.2.1; previous revision: 1.235
mail/base/content/msgPrintEngine.xul;
new revision: 1.5.4.1; previous revision: 1.5
done
Comment 38 Robert Kaiser 2006-01-10 18:19:14 PST
What parts of this are in shared code and what parts are SeaMonkey-only?
If I understand correctly, mtschrep complains about the patch size for 1.8.0 branch, though most of the patch is in code that doesn't need driver approval anyways, only SeaMonkey approval.
From the SeaMonkey side, I could live with approval for 1.0 probably, but someone needs to approve the non-SeaMonkey-specific parts on behalf of drivers. Maybe if we could split off that part, mtschrep might feel better (and it would be nice to get him to agree, as he was the one marking the minus)...
Comment 39 Andrew Schultz 2006-01-27 23:09:46 PST
*** Bug 325010 has been marked as a duplicate of this bug. ***
Comment 40 Chris Thomas (CTho) [formerly cst@andrew.cmu.edu cst@yecc.com] 2006-01-28 09:51:38 PST
(In reply to comment #38)
> What parts of this are in shared code and what parts are SeaMonkey-only?
> If I understand correctly, mtschrep complains about the patch size for 1.8.0
> branch, though most of the patch is in code that doesn't need driver approval
> anyways, only SeaMonkey approval.
> From the SeaMonkey side, I could live with approval for 1.0 probably, but
> someone needs to approve the non-SeaMonkey-specific parts on behalf of drivers.
> Maybe if we could split off that part, mtschrep might feel better (and it would
> be nice to get him to agree, as he was the one marking the minus)...
> 

Has anybody followed up on this?
Comment 41 Ian Neal 2006-01-28 14:15:21 PST
(In reply to comment #40)
> (In reply to comment #38)
> > What parts of this are in shared code and what parts are SeaMonkey-only?
> > If I understand correctly, mtschrep complains about the patch size for 1.8.0
> > branch, though most of the patch is in code that doesn't need driver approval
> > anyways, only SeaMonkey approval.
> > From the SeaMonkey side, I could live with approval for 1.0 probably, but
> > someone needs to approve the non-SeaMonkey-specific parts on behalf of drivers.
> > Maybe if we could split off that part, mtschrep might feel better (and it would
> > be nice to get him to agree, as he was the one marking the minus)...
> > 
> 
> Has anybody followed up on this?
> 
Sorry this was discussed on IRC but I never followed up by posting a response here.
It is nearly all shared code as TB uses parts of the toolkit and xpfe printing systems. I did look at trying to create an SM only patch but would have meant forking msgPrintEngine.js for TB which again would have probably been too much code change for 1.8.0.
Comment 42 Andrew Schultz 2006-01-30 06:43:37 PST
*** Bug 324772 has been marked as a duplicate of this bug. ***
Comment 43 Markus Winklbauer 2006-01-30 11:10:13 PST
The print preview is broken again (cut). Try scaling of any page or just scroll down multiple pages (e.g. "LICENCE" file in seamonkey directory). 

Although 
"Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20060124 SeaMonkey/1.5a"
and some builds before seemed to be ok, todays build 
"Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20060130 SeaMonkey/1.5a" has problems again.
Tried also with build from 20060127 which was broken, too.
Comment 44 John T 2006-01-30 11:36:52 PST
Using Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.7.12) Gecko/20060129, I found that the scroll bars seem to be OK at all the settings I tried, but the sizing of text has a problem. Displaying this bugzilla page at 50%, it's 5 pages long, but at 40% it's 9 pages long and the text below this text entry box isn't shrunk to 40%. It's quite a bit larger (100%?), making the total length 9 pages. The text in this box is the larger size too.
Comment 45 Ian Neal 2006-01-30 14:27:33 PST
Markus, please log a new bug and cc me in (or least mention the bug number here).
Include steps on how to reproduce, describe what is different and, if possible, attach to that bug a screenshot so I can compare to what I see here.
Comment 46 Ian Neal 2006-01-30 16:22:41 PST
(In reply to comment #45)
> Markus, please log a new bug and cc me in (or least mention the bug number
> here).
> Include steps on how to reproduce, describe what is different and, if possible,
> attach to that bug a screenshot so I can compare to what I see here.
> 
Okay, I think I have the same thing so logged bug 325276
Comment 47 tech 2006-01-31 01:11:36 PST
(In reply to comment #42)
> *** Bug 324772 has been marked as a duplicate of this bug. ***
> 
Hello, 
even if there's mention of the zoom problem in some comments here, and the two bugs seems linked, the main description "Print Preview window is partly overlayed by background and is missing scrollbars" doesn't match at all the fact that When changing the size in print preview, nothing happens. 
Why not titling "there are problems with print preview" ?
I think you might receive many duplicates... 
Comment 48 Wayne Mery (:wsmwk, NI for questions) 2006-05-10 09:43:28 PDT
*** Bug 129033 has been marked as a duplicate of this bug. ***
Comment 49 Andrew Schultz 2006-10-09 20:07:42 PDT
*** Bug 355911 has been marked as a duplicate of this bug. ***
Comment 50 Wayne Mery (:wsmwk, NI for questions) 2007-02-28 11:13:13 PST
*** Bug 356231 has been marked as a duplicate of this bug. ***
Comment 51 Wayne Mery (:wsmwk, NI for questions) 2007-02-28 11:59:29 PST
*** Bug 339956 has been marked as a duplicate of this bug. ***
Comment 52 Wayne Mery (:wsmwk, NI for questions) 2007-02-28 12:28:53 PST
*** Bug 350592 has been marked as a duplicate of this bug. ***
Comment 53 tech 2007-04-19 00:20:36 PDT
As it seems that any kind of printing preview problem are told to be duplicates of this one, even if the title (Print Preview window is partly overlayed by background and is missing scrollbars) as nothing to do with the actuel problem, I add here other examples of page which are not correctly shown.
I'll add the same infos in the bug #324772 I've already reported...

It's still impossible to change the printing preview size of the page I mentioned 
http://www.mozilla.org/support/firefox/faq 

either with SeaMonkey/1.1.1 or with Firefox/2.0.0.3 (under windows XP SP1)
but with Seamonkey the change between landscape and portrait works, not with Firefox.
I also tried with Seamonkey under Linux Mandriva 2006, and in this case the buttons for size and orientation show briefly when the window open then totally disappear, so I can't test if they work !

I recently tried to print this page at a reduced size, to save some paper :
http://www.w3.org/QA/2005/04/php-session
but it's another time impossible to change printing and preview size, either with Seamonkey or Firefox. Strangely, with this page, the orientation change works with both !

I wanted to insist that event if I had many strange behaviour in the printing preview window, I HAVE ABSOLUTELY NEVER seen "the window partly overlayed by background and is missing scrollbars". So I still think the bugs are not the same, and it's certainly why the one I describe isn't fixed yet.

Note You need to log in before you can comment on or make changes to this bug.