org.icepdf.ri.common.tools
Class ZoomInPageHandler
java.lang.Object
org.icepdf.ri.common.tools.CommonToolHandler
org.icepdf.ri.common.tools.SelectionBoxHandler
org.icepdf.ri.common.tools.ZoomInPageHandler
- All Implemented Interfaces:
- java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.util.EventListener, javax.swing.event.MouseInputListener, ToolHandler
public class ZoomInPageHandler
- extends SelectionBoxHandler
- implements ToolHandler
Handles mouse click zoom in and scroll box zoom in. The zoom is handled at the
AbstractDocumentView level as we accept mouse clicks from anywhere in the
view.
- Since:
- 4.0
| Methods inherited from class org.icepdf.ri.common.tools.SelectionBoxHandler |
clearRectangle, getCurrentRect, getRectToDraw, isOverPageComponent, paintSelectionBox, resetRectangle, setCurrentRect, setRectToDraw, setSelectionSize, updateDrawableRect, updateSelectionSize |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ZoomInPageHandler
public ZoomInPageHandler(DocumentViewController documentViewController,
AbstractPageViewComponent pageViewComponent,
DocumentViewModel documentViewModel)
mouseDragged
public void mouseDragged(java.awt.event.MouseEvent e)
- Specified by:
mouseDragged in interface java.awt.event.MouseMotionListener
mouseClicked
public void mouseClicked(java.awt.event.MouseEvent e)
- Specified by:
mouseClicked in interface java.awt.event.MouseListener
mousePressed
public void mousePressed(java.awt.event.MouseEvent e)
- Specified by:
mousePressed in interface java.awt.event.MouseListener
mouseReleased
public void mouseReleased(java.awt.event.MouseEvent e)
- Specified by:
mouseReleased in interface java.awt.event.MouseListener
mouseEntered
public void mouseEntered(java.awt.event.MouseEvent e)
- Specified by:
mouseEntered in interface java.awt.event.MouseListener
mouseExited
public void mouseExited(java.awt.event.MouseEvent e)
- Specified by:
mouseExited in interface java.awt.event.MouseListener
mouseMoved
public void mouseMoved(java.awt.event.MouseEvent e)
- Specified by:
mouseMoved in interface java.awt.event.MouseMotionListener
setSelectionRectangle
public void setSelectionRectangle(java.awt.Point cursorLocation,
java.awt.Rectangle selection)
- Specified by:
setSelectionRectangle in class SelectionBoxHandler
paintTool
public void paintTool(java.awt.Graphics g)
- Description copied from interface:
ToolHandler
- Paints the tools pre-annotation creation state.
- Specified by:
paintTool in interface ToolHandler
- Parameters:
g - graphics context
installTool
public void installTool()
- Description copied from interface:
ToolHandler
- Callback code that allows post construct task to take place when the
tool is selected via the
AbstractDocumentView.setToolMode(int)
call.
- Specified by:
installTool in interface ToolHandler
uninstallTool
public void uninstallTool()
- Description copied from interface:
ToolHandler
- Callback code that allows pre destroy task to take place when the
tool is unselected via the
AbstractDocumentView.setToolMode(int)
call.
- Specified by:
uninstallTool in interface ToolHandler
calculateZoom
public static float calculateZoom(DocumentViewController documentViewController,
java.awt.Rectangle rectToDraw,
DocumentViewModel documentViewModel)