Details
Description
Note from customer:
Changes in the print dialog don't have an effect on the currently printed document but only on next the following documents.
The org.icepdf.ri.common.PrintHelper.java class holds two member member attribute sets that are not functional independent.
private HashDocAttributeSet docAttributeSet;
private HashPrintRequestAttributeSet printRequestAttributeSet;
both are initialized in the
PrintHelper(DocumentViewController,
PageTree
MediaSizeName
PrintQuality)
constructor.
Into both of these attribute sets arte initialized to hold a MediaSize and a MediaPrintableArea Attribute.
Both initial values are set to NA_LETTER if no persisted properties are found or to whatever is defined in the properties file.
Before printing is started a printing dialog is opened.
But if the media size is changed in this dialog, the result is not transferred into the docAttributeSet so these attribute sets are no longer consistent. For rendering the PDF in PrintHelper.print() a PageFormat is given which is taken from the docAttributeSet and the media change in the print dialog is ignored.
It is either necessary to synchronize the Media and MediaPrintableAreaSize attributes in the docAttributeSet and the printRequestAttributeSet after the printDialog returns or not to define these attributes in the docAttributeSet in the first place. So the user has the possibility to change the media size in the print dialog.
Changes in the print dialog don't have an effect on the currently printed document but only on next the following documents.
The org.icepdf.ri.common.PrintHelper.java class holds two member member attribute sets that are not functional independent.
private HashDocAttributeSet docAttributeSet;
private HashPrintRequestAttributeSet printRequestAttributeSet;
both are initialized in the
PrintHelper(DocumentViewController,
PageTree
MediaSizeName
PrintQuality)
constructor.
Into both of these attribute sets arte initialized to hold a MediaSize and a MediaPrintableArea Attribute.
Both initial values are set to NA_LETTER if no persisted properties are found or to whatever is defined in the properties file.
Before printing is started a printing dialog is opened.
But if the media size is changed in this dialog, the result is not transferred into the docAttributeSet so these attribute sets are no longer consistent. For rendering the PDF in PrintHelper.print() a PageFormat is given which is taken from the docAttributeSet and the media change in the print dialog is ignored.
It is either necessary to synchronize the Media and MediaPrintableAreaSize attributes in the docAttributeSet and the printRequestAttributeSet after the printDialog returns or not to define these attributes in the docAttributeSet in the first place. So the user has the possibility to change the media size in the print dialog.
Activity
Ken Fyten
made changes -
Status | Resolved [ 5 ] | Closed [ 6 ] |
Patrick Corless
made changes -
Status | Reopened [ 4 ] | Resolved [ 5 ] |
Resolution | Fixed [ 1 ] |
Tyler Johnson
made changes -
Resolution | Fixed [ 1 ] | |
Status | Resolved [ 5 ] | Reopened [ 4 ] |
Patrick Corless
made changes -
Status | Reopened [ 4 ] | Resolved [ 5 ] |
Resolution | Fixed [ 1 ] |
Tyler Johnson
made changes -
Resolution | Fixed [ 1 ] | |
Status | Resolved [ 5 ] | Reopened [ 4 ] |
Patrick Corless
made changes -
Status | Open [ 1 ] | Resolved [ 5 ] |
Resolution | Fixed [ 1 ] |
Repository | Revision | Date | User | Message |
ICEsoft Public SVN Repository | #23890 | Wed Feb 02 12:01:57 MST 2011 | patrick.corless | |
Files Changed | ||||
MODIFY
/icepdf/trunk/icepdf/viewer/src/org/icepdf/ri/common/PrintHelper.java
|
Patrick Corless
made changes -
Fix Version/s | 4.1.4 [ 10264 ] | |
Fix Version/s | 4.2 [ 10243 ] |
Patrick Corless
made changes -
Assignee Priority | P2 | P1 |
Ken Fyten
made changes -
Fix Version/s | 4.2 [ 10243 ] | |
Assignee Priority | P2 |
Tyler Johnson
made changes -
Field | Original Value | New Value |
---|---|---|
Salesforce Case | [5007000000EV3UV] |
Tyler Johnson
created issue -
Resolving issue as original issue was fixed for 4.1.4. Reference code was sent to client to show use of PropertyManager within a parent application.
If a new issue comes out of the reference code a new issue should be created.