Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

ch.laoe.plugin
Class GPZoom  view GPZoom download GPZoom.java

java.lang.Object
  extended bych.laoe.plugin.GPlugin
      extended bych.laoe.plugin.GPluginFrame
          extended bych.laoe.plugin.GPZoom
All Implemented Interfaces:
java.awt.event.ActionListener, java.util.EventListener, java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.awt.event.WindowListener

public class GPZoom
extends GPluginFrame

This file is part of LAoE. LAoE is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. LAoE is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with LAoE; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA Class: GPZoom Autor: olivier gäumann, neuchâtel (switzerland) JDK: 1.3 Desctription: plugin to zoom the clip-view. mouse action table: ------------------------------------------------------------ press/drag/release click double-click ------------------------------------------------------------ no key translate xy - - shift zoom in x zoom out x autoscale x shift&ctrl zoom in xy zoom out xy autoscale xy ctrl zoom in y zoom out y autoscale y ------------------------------------------------------------ History: Date: Description: Autor: 30.08.00 erster Entwurf oli4 10.11.00 better zoom support of plotters is used here oli4 30.01.01 extended zoom-functions controlled by mouse oli4 24.03.01 individual layers / common clip zoom oli4 14.04.01 cursors added oli4 09.12.01 autoscale-modes and selectable x/y added oli4 10.02.02 add different y autoscale-modes oli4


Nested Class Summary
private  class GPZoom.EventDispatcher
           
 
Nested classes inherited from class ch.laoe.plugin.GPluginFrame
GPluginFrame.AutoCloseManager
 
Field Summary
private  java.awt.Cursor actualCursor
           
private  javax.swing.JButton autoScale
           
private  javax.swing.JCheckBox autoX
           
private  javax.swing.JCheckBox autoY
           
private  boolean ctrlActive
           
private  java.awt.BasicStroke dashedStroke
           
private  GPZoom.EventDispatcher eventDispatcher
           
private  javax.swing.JCheckBox individualY
           
private  ch.laoe.clip.AChannelPlotter mouseChannelPlotter
           
private  boolean mouseDown
           
private  int mouseZoomX1
           
private  int mouseZoomX2
           
private  int mouseZoomY1
           
private  int mouseZoomY2
           
private  java.awt.Cursor moveCursor
           
private  java.awt.BasicStroke normalStroke
           
private  UiControlText offsetX
           
private  UiControlText offsetY
           
private  UiControlText scaleX
           
private  UiControlText scaleY
           
private  boolean shiftActive
           
private  javax.swing.JComboBox xAutoMode
           
private  java.awt.Cursor xCursor
           
private  java.awt.Cursor xyCursor
           
private  javax.swing.JComboBox yAutoMode
           
private  java.awt.Cursor yCursor
           
 
Fields inherited from class ch.laoe.plugin.GPluginFrame
frame
 
Fields inherited from class ch.laoe.plugin.GPlugin
persistance, pluginHandler
 
Constructor Summary
GPZoom(GPluginHandler ph)
           
 
Method Summary
 javax.swing.JMenuItem createMenuItem()
           
protected  java.lang.String getName()
          returns the normal one-word name of the plugin.
 void initGui()
           
 void mouseClicked(java.awt.event.MouseEvent e)
          This method is called when the mouse is clicked (pressed and released in short succession) on a component.
 void mouseDragged(java.awt.event.MouseEvent e)
          This method is called when the mouse is moved over a component while a button has been pressed.
 void mouseEntered(java.awt.event.MouseEvent e)
          This method is called when the mouse enters a component.
 void mouseMoved(java.awt.event.MouseEvent e)
          This method is called when the mouse is moved over a component while no button is pressed.
 void mousePressed(java.awt.event.MouseEvent e)
          This method is called when the mouse is pressed over a component.
 void mouseReleased(java.awt.event.MouseEvent e)
          This method is called when the mouse is released over a component.
 void paintOntoClip(java.awt.Graphics2D g2d, java.awt.Rectangle rect)
          called by ui when this plugin needs to print onto the clip
 void reload()
          called by ui if a plugin should reload its values
private  void reloadZoomFrame()
           
 void start()
          called when this plugin gets active and focussed
 
Methods inherited from class ch.laoe.plugin.GPluginFrame
autoCloseFrame, backupLocation, getState, isVisible, onBackup, pack, restoreLocation, setState, showErrorDialog, wasVisibleOnExit, windowActivated, windowClosed, windowClosing, windowDeactivated, windowDeiconified, windowIconified, windowOpened
 
Methods inherited from class ch.laoe.plugin.GPlugin
actionPerformed, autoScaleFocussedClip, createButton, createButton, createCustomCursor, createMenuItem, createMenuItem, getDescription, getFocussedClip, getFocussedClipEditor, getFocussedClipFrame, getLaoeInstallationPath, getMain, getSelectedLayer, isAltKey, isButton1, isButton2, isButton3, isCtrlKey, isShiftKey, loadIcon, loadIcon, mouseExited, onRestore, reloadFocussedClipEditor, repaintFocussedClipEditor, setPluginHandler, updateFrameTitle, updateHistory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dashedStroke

private java.awt.BasicStroke dashedStroke

normalStroke

private java.awt.BasicStroke normalStroke

mouseChannelPlotter

private ch.laoe.clip.AChannelPlotter mouseChannelPlotter

mouseZoomX1

private int mouseZoomX1

mouseZoomY1

private int mouseZoomY1

mouseZoomX2

private int mouseZoomX2

mouseZoomY2

private int mouseZoomY2

shiftActive

private boolean shiftActive

ctrlActive

private boolean ctrlActive

mouseDown

private boolean mouseDown

scaleX

private UiControlText scaleX

scaleY

private UiControlText scaleY

offsetX

private UiControlText offsetX

offsetY

private UiControlText offsetY

autoScale

private javax.swing.JButton autoScale

individualY

private javax.swing.JCheckBox individualY

autoX

private javax.swing.JCheckBox autoX

autoY

private javax.swing.JCheckBox autoY

xAutoMode

private javax.swing.JComboBox xAutoMode

yAutoMode

private javax.swing.JComboBox yAutoMode

eventDispatcher

private GPZoom.EventDispatcher eventDispatcher

moveCursor

private java.awt.Cursor moveCursor

xCursor

private java.awt.Cursor xCursor

yCursor

private java.awt.Cursor yCursor

xyCursor

private java.awt.Cursor xyCursor

actualCursor

private java.awt.Cursor actualCursor
Constructor Detail

GPZoom

public GPZoom(GPluginHandler ph)
Method Detail

getName

protected java.lang.String getName()
Description copied from class: GPlugin
returns the normal one-word name of the plugin.

Specified by:
getName in class GPlugin

createMenuItem

public javax.swing.JMenuItem createMenuItem()
Overrides:
createMenuItem in class GPlugin

start

public void start()
Description copied from class: GPlugin
called when this plugin gets active and focussed

Overrides:
start in class GPluginFrame

reload

public void reload()
Description copied from class: GPlugin
called by ui if a plugin should reload its values

Overrides:
reload in class GPlugin

paintOntoClip

public void paintOntoClip(java.awt.Graphics2D g2d,
                          java.awt.Rectangle rect)
Description copied from class: GPlugin
called by ui when this plugin needs to print onto the clip

Overrides:
paintOntoClip in class GPlugin

mousePressed

public void mousePressed(java.awt.event.MouseEvent e)
Description copied from interface: java.awt.event.MouseListener
This method is called when the mouse is pressed over a component.

Specified by:
mousePressed in interface java.awt.event.MouseListener
Overrides:
mousePressed in class GPlugin

mouseReleased

public void mouseReleased(java.awt.event.MouseEvent e)
Description copied from interface: java.awt.event.MouseListener
This method is called when the mouse is released over a component.

Specified by:
mouseReleased in interface java.awt.event.MouseListener
Overrides:
mouseReleased in class GPlugin

mouseClicked

public void mouseClicked(java.awt.event.MouseEvent e)
Description copied from interface: java.awt.event.MouseListener
This method is called when the mouse is clicked (pressed and released in short succession) on a component.

Specified by:
mouseClicked in interface java.awt.event.MouseListener
Overrides:
mouseClicked in class GPlugin

mouseEntered

public void mouseEntered(java.awt.event.MouseEvent e)
Description copied from interface: java.awt.event.MouseListener
This method is called when the mouse enters a component.

Specified by:
mouseEntered in interface java.awt.event.MouseListener
Overrides:
mouseEntered in class GPlugin

mouseDragged

public void mouseDragged(java.awt.event.MouseEvent e)
Description copied from interface: java.awt.event.MouseMotionListener
This method is called when the mouse is moved over a component while a button has been pressed.

Specified by:
mouseDragged in interface java.awt.event.MouseMotionListener
Overrides:
mouseDragged in class GPlugin

mouseMoved

public void mouseMoved(java.awt.event.MouseEvent e)
Description copied from interface: java.awt.event.MouseMotionListener
This method is called when the mouse is moved over a component while no button is pressed.

Specified by:
mouseMoved in interface java.awt.event.MouseMotionListener
Overrides:
mouseMoved in class GPlugin

initGui

public void initGui()

reloadZoomFrame

private void reloadZoomFrame()