facets.core.app.avatar
Class ZoomPanViewWorks

java.lang.Object
  extended by facets.util.Tracer
      extended by facets.util.StatefulCore
          extended by facets.core.superficial.app.SelectionView
              extended by facets.core.app.avatar.AvatarViewWorks
                  extended by facets.core.app.avatar.PlaneViewWorks
                      extended by facets.core.app.avatar.ZoomPanViewWorks
All Implemented Interfaces:
AvatarView, PlaneView, ZoomPanView, SView, Stateful, Titled, java.io.Serializable

public class ZoomPanViewWorks
extends PlaneViewWorks
implements ZoomPanView

PlaneViewWorks that implements ZoomPanView.

Also has a number of utility class methods.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface facets.core.app.avatar.PlaneView
PlaneView.ResizeResponse
 
Field Summary
static int MODEL_START
           
static int MODEL_ZOOM
           
 
Fields inherited from class facets.core.app.avatar.PlaneViewWorks
LINES_GROUP, LINES_SINGLE, MODEL_CONSTRAIN, MODEL_EDIT, MODEL_ELEMENTS, MODEL_SNAP, NO_SCALE
 
Fields inherited from class facets.core.app.avatar.AvatarViewWorks
avatars
 
Fields inherited from interface facets.core.app.avatar.PlaneView
INCH_PTS, ZOOM_IN, ZOOM_OUT
 
Fields inherited from interface facets.core.superficial.app.SView
NO_VIEW
 
Constructor Summary
ZoomPanViewWorks(java.lang.String title, double showWidth, double showHeight, AvatarPolicies policies)
           
 
Method Summary
protected  AvatarPolicies fetchActorPolicies()
           
 Point focusAt()
          The last position set with ZoomPanView.setFocusAt(Point).
 STarget newFrame()
           
 double originToLeft()
          The unscaled distance from the viewport origin to the left edge of the bounded plane.
 double originToTop()
          The unscaled distance from the viewport origin to the top edge of the bounded plane.
 double planeHeight()
          The unscaled height of the bounded plane.
 double planeWidth()
          The unscaled width of the bounded plane.
 PlaneView.ResizeResponse resizeResponse()
          Does the view adjust its scale or its shape if the viewer facet is resized?
 void setFocusAt(Point at)
          Set a position within the bounded plane that should appear as near as possible to the centre of the viewport.
 void setState(java.lang.Object state)
          Implements interface method.
 java.lang.Object stamp()
          Identifier that should change with each change in view properties.
 
Methods inherited from class facets.core.app.avatar.PlaneViewWorks
backgroundStyle, doConstrain, doSnap, isLive, markLeapPixels, markPixels, newFrameElements, newLineSets, newTestLineSet, pickHitPixels, plotShift, scale, setShowValues, showHeight, showWidth, toString, ySign
 
Methods inherited from class facets.core.app.avatar.AvatarViewWorks
allowMultipleSelection, avatars, doesDnD
 
Methods inherited from class facets.core.superficial.app.SelectionView
newViewerSelection
 
Methods inherited from class facets.util.StatefulCore
copyState, setTitle, stateEquals, stateStamp, title, updateStateStamp
 
Methods inherited from class facets.util.Tracer
trace, trace, trace, trace, trace, traceDebug, traceDebug, traceObjectText, traceOutput, traceOutputWithClass
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface facets.core.app.avatar.PlaneView
plotShift, scale, setShowValues, showHeight, showWidth, ySign
 
Methods inherited from interface facets.core.app.avatar.AvatarView
avatars, backgroundStyle, doesDnD, markLeapPixels, markPixels, pickHitPixels
 
Methods inherited from interface facets.core.superficial.app.SView
allowMultipleSelection, isLive
 
Methods inherited from interface facets.util.Titled
title
 

Field Detail

MODEL_START

public static final int MODEL_START
See Also:
Constant Field Values

MODEL_ZOOM

public static final int MODEL_ZOOM
See Also:
Constant Field Values
Constructor Detail

ZoomPanViewWorks

public ZoomPanViewWorks(java.lang.String title,
                        double showWidth,
                        double showHeight,
                        AvatarPolicies policies)
Method Detail

resizeResponse

public final PlaneView.ResizeResponse resizeResponse()
Description copied from interface: PlaneView
Does the view adjust its scale or its shape if the viewer facet is resized?

Specified by:
resizeResponse in interface PlaneView
Overrides:
resizeResponse in class PlaneViewWorks

focusAt

public final Point focusAt()
Description copied from interface: ZoomPanView
The last position set with ZoomPanView.setFocusAt(Point).

Specified by:
focusAt in interface ZoomPanView

newFrame

public STarget newFrame()
Overrides:
newFrame in class PlaneViewWorks

originToLeft

public final double originToLeft()
Description copied from interface: ZoomPanView
The unscaled distance from the viewport origin to the left edge of the bounded plane.

Specified by:
originToLeft in interface ZoomPanView
Returns:
any double

originToTop

public final double originToTop()
Description copied from interface: ZoomPanView
The unscaled distance from the viewport origin to the top edge of the bounded plane.

Specified by:
originToTop in interface ZoomPanView
Returns:
any double

planeHeight

public final double planeHeight()
Description copied from interface: ZoomPanView
The unscaled height of the bounded plane.

Specified by:
planeHeight in interface ZoomPanView
Returns:
a positive double

planeWidth

public final double planeWidth()
Description copied from interface: ZoomPanView
The unscaled width of the bounded plane.

Specified by:
planeWidth in interface ZoomPanView
Returns:
a positive double

setFocusAt

public final void setFocusAt(Point at)
Description copied from interface: ZoomPanView
Set a position within the bounded plane that should appear as near as possible to the centre of the viewport.

Specified by:
setFocusAt in interface ZoomPanView
Parameters:
at - should define a position within the bounded plane

setState

public void setState(java.lang.Object state)
Description copied from class: StatefulCore
Implements interface method.

Does not actually set any state, but does change the value returned by StatefulCore.stateStamp(): if updating itself by calling StatefulCore.updateStateStamp(), otherwise by casting src to a Stateful and copying its StatefulCore.stateStamp()

Specified by:
setState in interface Stateful
Overrides:
setState in class PlaneViewWorks
Parameters:
state - must be non-null and interpretable by the implementation as state information; it will usually be another instance of the Stateful's class.

stamp

public final java.lang.Object stamp()
Description copied from interface: PlaneView
Identifier that should change with each change in view properties.

Specified by:
stamp in interface PlaneView
Overrides:
stamp in class PlaneViewWorks
Returns:
typically an Integer containing an auto-incremented value

fetchActorPolicies

protected AvatarPolicies fetchActorPolicies()