Details
-
Type: Improvement
-
Status: Closed
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: 3.1
-
Fix Version/s: 4.0 - Beta, 4.0
-
Component/s: Viewer RI
-
Labels:None
-
Environment:-
Description
When setting fit to width, the page zooms towards the center rather than
positioning itself at the top. The customer would like us to consider this fix
for our next release. Here is what he has done:
I got this working by modifying the setFitMode(int) method as follows:
At the bottom of the method I replaced the call to setZoom(newZoom, null, true)
with the following logic:
// set appropriate zoom level
// If we're scrolled all the way to the top, center to top of document when zoom.
if (getVerticalScrollBar().getValue() == 0)
{
setZoom(newZoom, new Point(0, 0), true);
}
else
{
setZoom(newZoom, null, true);
}
positioning itself at the top. The customer would like us to consider this fix
for our next release. Here is what he has done:
I got this working by modifying the setFitMode(int) method as follows:
At the bottom of the method I replaced the call to setZoom(newZoom, null, true)
with the following logic:
// set appropriate zoom level
// If we're scrolled all the way to the top, center to top of document when zoom.
if (getVerticalScrollBar().getValue() == 0)
{
setZoom(newZoom, new Point(0, 0), true);
}
else
{
setZoom(newZoom, null, true);
}
Activity
Tyler Johnson
created issue -
Tyler Johnson
made changes -
Field | Original Value | New Value |
---|---|---|
Salesforce Case | [50070000007C5dh] |
Patrick Corless
made changes -
Fix Version/s | 3.2 [ 10212 ] |
Ken Walker
made changes -
Attachment | DocumentViewControllerImpl.java.patch [ 12079 ] |
Ken Fyten
made changes -
Assignee | Patrick Corless [ patrick.corless ] | Carlo Guglielmin [ carlo.guglielmin ] |
Repository | Revision | Date | User | Message |
ICEsoft Public SVN Repository | #19892 | Tue Dec 08 15:43:31 MST 2009 | carlo.guglielmin | |
Files Changed | ||||
MODIFY
/icepdf/trunk/icepdf/viewer/src/org/icepdf/ri/common/views/DocumentViewControllerImpl.java
|
Carlo Guglielmin
made changes -
Status | Open [ 1 ] | Resolved [ 5 ] |
Resolution | Fixed [ 1 ] |
Tyler Johnson
made changes -
Salesforce Case | [50070000007C5dh] | [50070000007C5dh, 5007000000ApPDh] |
Ken Fyten
made changes -
Fix Version/s | 4.0 [ 10222 ] |
Ken Fyten
made changes -
Status | Resolved [ 5 ] | Closed [ 6 ] |
Just to clarify the issue, I don't necessarily want it to scroll to the top whenever you set fit to width...only if you're already scrolled to the top.