-
Bug
-
Resolution: Cannot Reproduce
-
P3
-
6u17
-
x86
-
windows_7
FULL PRODUCT VERSION :
java version "1.6.0_17"
Java(TM) SE Runtime Environment (build 1.6.0_17-b04)
Java HotSpot(TM) Client VM (build 14.3-b01, mixed mode, sharing)
... and older 1.6.0 versions.
ADDITIONAL OS VERSION INFORMATION :
Windows 7 (32-bit),
Ubuntu Linux 9.10 (64-bit) and older versions.
A DESCRIPTION OF THE PROBLEM :
Returned PageFormat from PrinterJob.pageDialog(PrintRequestAttributeSet) inflates the page size by +1 (dx) and +2 (dy) ... at least for "letter" sized paper. Just click "OK" when the Page Dialog appears - making no changes. Occurs on both Windows and Linux.
On Linux the same error occurs after calling PrinterJob.pageDialog(PageFormat).
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Grab a defaultPage(), invoke pageDialog(), hit the "OK" button, examine the returned PageFormat.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
The Paper size attached to the PageFormat should not change.
ACTUAL -
The page size in the Paper increased (and should not).
ERROR MESSAGES/STACK TRACES THAT OCCUR :
Log file (in HTML) generated by the PrintExplorer test program.
<html>
<style type='text/css'>
.command { background-color: yellow }
</style>
<br>Logfile: C:\Users\preston\print-test-log.html
<br>JRE Vendor = Sun Microsystems Inc.
<br>JRE Version = 1.6.0_17
<br>OS name = Windows 7
<br>OS arch = x86
<br>OS version = 6.1
<br>
<h3>Details</h3>
<b>PrintService</b>
<div>color-supported = supported</div>
<div>printer-name = \\athena\deskjet_5550</div>
<div>queued-job-count = 0</div>
<div>printer-is-accepting-jobs = accepting-jobs</div>
<br>
<div><i>(no UI factory)</i></div>
<br>
<h3>Attributes Before</h3>
<b>JobAttributes</b>
<div>dialog = native</div>
<div>printer = \\athena\deskjet_5550</div>
<div>destination = printer</div>
<div>filename = null</div>
<div>page-min = 1</div>
<div>page-max = 1234</div>
<div>default selection = all</div><div>page-ranges = 1</div>
<div>copies = 1</div>
<div>sides = one-sided</div>
<div>multiple-document-handling = separate-documents-uncollated-copies</div>
<br>
<b>PageAttributes</b>
<div>media = na-letter</div>
<div>orientation requested = portrait</div>
<div>origin = physical</div>
<div>color = color</div>
<div>print quality = normal</div>
<div>printer resolution = 72 72 3</div>
<br>
<h3>PrinterJob Before</h3>
<b>PrinterJob</b>
<div>copies = 1</div>
<div>job-name = Java Printing</div>
<div>user-name = preston</div>
<br>
<b>PrintService</b>
<div>color-supported = supported</div>
<div>printer-name = \\athena\deskjet_5550</div>
<div>queued-job-count = 0</div>
<div>printer-is-accepting-jobs = accepting-jobs</div>
<br>
<div><i>(no UI factory)</i></div>
<br>
<b>PageFormat</b>
<div>orientation: 1</div>
<div>page dx: 612.0 dy: 792.0</div>
<div>imagable x: 72.0 y: 72.0 dx: 468.0 dy: 648.0</div>
<br>
<b>PrintRequestAttributeSet</b>
<div>chromaticity = color</div>
<div>job-name = test printer job</div>
<div>requesting-user-name = A Test User</div>
<div>copies = 1</div>
<br>
<div>STATUS: Ready</div>
<br>
<h3 class='command'>COMMAND: Printer Selected</h3>
<br>
<h3>Details</h3>
(no printer)
<br>
<h3 class='command'>COMMAND: Printer Selected</h3>
<br>
<h3>Details</h3>
<b>PrintService</b>
<div>color-supported = supported</div>
<div>printer-name = HP Photosmart 8400 Series</div>
<div>queued-job-count = 0</div>
<div>printer-is-accepting-jobs = accepting-jobs</div>
<br>
<div><i>(no UI factory)</i></div>
<br>
<h3>Attributes Before</h3>
<b>JobAttributes</b>
<div>dialog = native</div>
<div>printer = HP Photosmart 8400 Series</div>
<div>destination = printer</div>
<div>filename = null</div>
<div>page-min = 1</div>
<div>page-max = 1234</div>
<div>default selection = all</div><div>page-ranges = 1</div>
<div>copies = 1</div>
<div>sides = one-sided</div>
<div>multiple-document-handling = separate-documents-uncollated-copies</div>
<br>
<b>PageAttributes</b>
<div>media = na-letter</div>
<div>orientation requested = portrait</div>
<div>origin = physical</div>
<div>color = color</div>
<div>print quality = normal</div>
<div>printer resolution = 72 72 3</div>
<br>
<h3>PrinterJob Before</h3>
<b>PrinterJob</b>
<div>copies = 1</div>
<div>job-name = Java Printing</div>
<div>user-name = preston</div>
<br>
<b>PrintService</b>
<div>color-supported = supported</div>
<div>printer-name = HP Photosmart 8400 Series</div>
<div>queued-job-count = 0</div>
<div>printer-is-accepting-jobs = accepting-jobs</div>
<br>
<div><i>(no UI factory)</i></div>
<br>
<b>PageFormat</b>
<div>orientation: 1</div>
<div>page dx: 612.0 dy: 792.0</div>
<div>imagable x: 72.0 y: 72.0 dx: 468.0 dy: 648.0</div>
<br>
<b>PrintRequestAttributeSet</b>
<div>chromaticity = color</div>
<div>job-name = test printer job</div>
<div>requesting-user-name = A Test User</div>
<div>copies = 1</div>
<br>
<h3 class='command'>COMMAND: printerJob.pageDialog(printRequestAttributeSet)</h3>
<br>
<h3>PrinterJob After</h3>
<b>PrinterJob</b>
<div>copies = 1</div>
<div>job-name = Java Printing</div>
<div>user-name = preston</div>
<br>
<b>PrintService</b>
<div>color-supported = supported</div>
<div>printer-name = HP Photosmart 8400 Series</div>
<div>queued-job-count = 0</div>
<div>printer-is-accepting-jobs = accepting-jobs</div>
<br>
<div><i>(no UI factory)</i></div>
<br>
<b>PageFormat</b>
<div>orientation: 1</div>
<div>page dx: 613.0 dy: 794.0</div>
<div>imagable x: 72.0 y: 72.0 dx: 468.0 dy: 648.0</div>
<br>
<b>PrintRequestAttributeSet</b>
<div>media-printable-area = (25.4,25.4)->(165.1,228.6)mm</div>
<div>orientation-requested = portrait</div>
<div>chromaticity = color</div>
<div>job-name = test printer job</div>
<div>requesting-user-name = A Test User</div>
<div>media = na-letter</div>
<div>copies = 1</div>
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
Source code is on Kenai.
http://kenai.com/projects/print-explorer
I have had a number of problems with printing, and the above program has the sole purpose of exercising the Print APIs.
---------- END SOURCE ----------
java version "1.6.0_17"
Java(TM) SE Runtime Environment (build 1.6.0_17-b04)
Java HotSpot(TM) Client VM (build 14.3-b01, mixed mode, sharing)
... and older 1.6.0 versions.
ADDITIONAL OS VERSION INFORMATION :
Windows 7 (32-bit),
Ubuntu Linux 9.10 (64-bit) and older versions.
A DESCRIPTION OF THE PROBLEM :
Returned PageFormat from PrinterJob.pageDialog(PrintRequestAttributeSet) inflates the page size by +1 (dx) and +2 (dy) ... at least for "letter" sized paper. Just click "OK" when the Page Dialog appears - making no changes. Occurs on both Windows and Linux.
On Linux the same error occurs after calling PrinterJob.pageDialog(PageFormat).
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Grab a defaultPage(), invoke pageDialog(), hit the "OK" button, examine the returned PageFormat.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
The Paper size attached to the PageFormat should not change.
ACTUAL -
The page size in the Paper increased (and should not).
ERROR MESSAGES/STACK TRACES THAT OCCUR :
Log file (in HTML) generated by the PrintExplorer test program.
<html>
<style type='text/css'>
.command { background-color: yellow }
</style>
<br>Logfile: C:\Users\preston\print-test-log.html
<br>JRE Vendor = Sun Microsystems Inc.
<br>JRE Version = 1.6.0_17
<br>OS name = Windows 7
<br>OS arch = x86
<br>OS version = 6.1
<br>
<h3>Details</h3>
<b>PrintService</b>
<div>color-supported = supported</div>
<div>printer-name = \\athena\deskjet_5550</div>
<div>queued-job-count = 0</div>
<div>printer-is-accepting-jobs = accepting-jobs</div>
<br>
<div><i>(no UI factory)</i></div>
<br>
<h3>Attributes Before</h3>
<b>JobAttributes</b>
<div>dialog = native</div>
<div>printer = \\athena\deskjet_5550</div>
<div>destination = printer</div>
<div>filename = null</div>
<div>page-min = 1</div>
<div>page-max = 1234</div>
<div>default selection = all</div><div>page-ranges = 1</div>
<div>copies = 1</div>
<div>sides = one-sided</div>
<div>multiple-document-handling = separate-documents-uncollated-copies</div>
<br>
<b>PageAttributes</b>
<div>media = na-letter</div>
<div>orientation requested = portrait</div>
<div>origin = physical</div>
<div>color = color</div>
<div>print quality = normal</div>
<div>printer resolution = 72 72 3</div>
<br>
<h3>PrinterJob Before</h3>
<b>PrinterJob</b>
<div>copies = 1</div>
<div>job-name = Java Printing</div>
<div>user-name = preston</div>
<br>
<b>PrintService</b>
<div>color-supported = supported</div>
<div>printer-name = \\athena\deskjet_5550</div>
<div>queued-job-count = 0</div>
<div>printer-is-accepting-jobs = accepting-jobs</div>
<br>
<div><i>(no UI factory)</i></div>
<br>
<b>PageFormat</b>
<div>orientation: 1</div>
<div>page dx: 612.0 dy: 792.0</div>
<div>imagable x: 72.0 y: 72.0 dx: 468.0 dy: 648.0</div>
<br>
<b>PrintRequestAttributeSet</b>
<div>chromaticity = color</div>
<div>job-name = test printer job</div>
<div>requesting-user-name = A Test User</div>
<div>copies = 1</div>
<br>
<div>STATUS: Ready</div>
<br>
<h3 class='command'>COMMAND: Printer Selected</h3>
<br>
<h3>Details</h3>
(no printer)
<br>
<h3 class='command'>COMMAND: Printer Selected</h3>
<br>
<h3>Details</h3>
<b>PrintService</b>
<div>color-supported = supported</div>
<div>printer-name = HP Photosmart 8400 Series</div>
<div>queued-job-count = 0</div>
<div>printer-is-accepting-jobs = accepting-jobs</div>
<br>
<div><i>(no UI factory)</i></div>
<br>
<h3>Attributes Before</h3>
<b>JobAttributes</b>
<div>dialog = native</div>
<div>printer = HP Photosmart 8400 Series</div>
<div>destination = printer</div>
<div>filename = null</div>
<div>page-min = 1</div>
<div>page-max = 1234</div>
<div>default selection = all</div><div>page-ranges = 1</div>
<div>copies = 1</div>
<div>sides = one-sided</div>
<div>multiple-document-handling = separate-documents-uncollated-copies</div>
<br>
<b>PageAttributes</b>
<div>media = na-letter</div>
<div>orientation requested = portrait</div>
<div>origin = physical</div>
<div>color = color</div>
<div>print quality = normal</div>
<div>printer resolution = 72 72 3</div>
<br>
<h3>PrinterJob Before</h3>
<b>PrinterJob</b>
<div>copies = 1</div>
<div>job-name = Java Printing</div>
<div>user-name = preston</div>
<br>
<b>PrintService</b>
<div>color-supported = supported</div>
<div>printer-name = HP Photosmart 8400 Series</div>
<div>queued-job-count = 0</div>
<div>printer-is-accepting-jobs = accepting-jobs</div>
<br>
<div><i>(no UI factory)</i></div>
<br>
<b>PageFormat</b>
<div>orientation: 1</div>
<div>page dx: 612.0 dy: 792.0</div>
<div>imagable x: 72.0 y: 72.0 dx: 468.0 dy: 648.0</div>
<br>
<b>PrintRequestAttributeSet</b>
<div>chromaticity = color</div>
<div>job-name = test printer job</div>
<div>requesting-user-name = A Test User</div>
<div>copies = 1</div>
<br>
<h3 class='command'>COMMAND: printerJob.pageDialog(printRequestAttributeSet)</h3>
<br>
<h3>PrinterJob After</h3>
<b>PrinterJob</b>
<div>copies = 1</div>
<div>job-name = Java Printing</div>
<div>user-name = preston</div>
<br>
<b>PrintService</b>
<div>color-supported = supported</div>
<div>printer-name = HP Photosmart 8400 Series</div>
<div>queued-job-count = 0</div>
<div>printer-is-accepting-jobs = accepting-jobs</div>
<br>
<div><i>(no UI factory)</i></div>
<br>
<b>PageFormat</b>
<div>orientation: 1</div>
<div>page dx: 613.0 dy: 794.0</div>
<div>imagable x: 72.0 y: 72.0 dx: 468.0 dy: 648.0</div>
<br>
<b>PrintRequestAttributeSet</b>
<div>media-printable-area = (25.4,25.4)->(165.1,228.6)mm</div>
<div>orientation-requested = portrait</div>
<div>chromaticity = color</div>
<div>job-name = test printer job</div>
<div>requesting-user-name = A Test User</div>
<div>media = na-letter</div>
<div>copies = 1</div>
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
Source code is on Kenai.
http://kenai.com/projects/print-explorer
I have had a number of problems with printing, and the above program has the sole purpose of exercising the Print APIs.
---------- END SOURCE ----------