Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.nwoods.jgo
Class JGoOverviewRectangle

    java.lang.Object
      com.nwoods.jgo.JGoObject
          com.nwoods.jgo.JGoDrawable
              com.nwoods.jgo.JGoRectangle
                  com.nwoods.jgo.JGoOverviewRectangle

All Implemented Interfaces:
  java.awt.event.ComponentListener, java.util.EventListener, JGoViewListener, JGoXMLSaveRestore, java.io.Serializable

public class JGoOverviewRectangle
extends JGoRectangle
implements JGoViewListener, java.awt.event.ComponentListener

The rectangle shown and dragged around in the overview window.

This class also takes up the additional responsibilities of keeping track of changes to the view, by being both a JGoViewListener and a ComponentListener.

See Also:
  Serialized Form

Field Summary

Fields inherited from class com.nwoods.jgo.JGoObject
`Bottom, BottomCenter, BottomLeft, BottomMiddle, BottomRight, Center, CenterLeft, CenterRight, Changed4ResizeHandles, ChangedAutoRescale, ChangedBrush, ChangedDraggable, ChangedDragsNode, ChangedGeometry, ChangedGrabChildSelection, ChangedInitializing, ChangedPen, ChangedResizable, ChangedSelectable, ChangedUpdatePartner, ChangedVisible, ChangedZOrder, LastChangedHint, Left, LeftCenter, NoHandle, NoSpot, NumReservedHandles, RepaintAll, Right, RightCenter, SideLeft, SideRight, Top, TopCenter, TopLeft, TopMiddle, TopRight`

Constructor Summary
`JGoOverviewRectangle()`
`JGoOverviewRectangle(java.awt.Point p, java.awt.Dimension d)` Construct a non-resizable rectangle with an extra-wide pen, so that it can show up reasonably at the reduced scale.

Method Summary
`void` | `componentHidden(java.awt.event.ComponentEvent e)`
`void` | `componentMoved(java.awt.event.ComponentEvent e)`
`void` | `componentResized(java.awt.event.ComponentEvent e)`
`void` | `componentShown(java.awt.event.ComponentEvent e)`
`protected void` | `gainedSelection(JGoSelection selection)` Selecting the overview rectangle shouldn't show any handles or do anything else.
`protected void` | `geometryChange(java.awt.Rectangle prevRect)` Handle any change in location (due to dragging) of this rectangle by changing the observed view's viewPosition.
`protected void` | `lostSelection(JGoSelection selection)` Selecting the overview rectangle shouldn't show any handles or do anything else.
`void` | `setBoundingRect(int left, int top, int width, int height)` Keep this rectangle within the bounds of the document.
`void` | `updateRectFromView()` Make this JGoRectangle's position and size correspond to the observed view's position and size in the document.
`void` | `viewChanged(JGoViewEvent e)` Handle basic changes to the observed view's viewPosition or scale.

Methods inherited from class com.nwoods.jgo.JGoRectangle
`copyObject, getNearestIntersectionPoint, paint, SVGReadAttributes, SVGReadObject, SVGWriteAttributes, SVGWriteObject`

Methods inherited from class com.nwoods.jgo.JGoDrawable
`changeValue, copyNewValueForRedo, draw3DRect, draw3DRect, drawEllipse, drawEllipse, drawEllipse, drawLine, drawLine, drawPath, drawPolygon, drawPolygon, drawRect, drawRect, drawRect, drawRoundRect, drawRoundRect, expandRectByPenWidth, getBrush, getNearestIntersectionPoint, getPen, setBrush, setPen, SVGAddPathArgs, SVGUpdateReference`

Methods inherited from class com.nwoods.jgo.JGoObject
`canView, computeBoundingRect, computeMove, computeResize, copy, copyObjectDelayed, copyOldValueForUndo, copyRect, doMouseClick, doMouseDblClick, doUncapturedMouseMove, findCommonParent, foredate, geometryChangeChild, getBoundingRect, getDocument, getDraggingObject, getFlags, getHeight, getLayer, getLeft, getLocation, getLocation, getParent, getParentJGoNode, getParentNode, getPartner, getRectangleSpotLocation, getSize, getSize, getSpotLocation, getSpotLocation, getToolTipText, getTop, getTopLeft, getTopLeft, getTopLevelObject, getView, getWidth, growRect, handleMove, handleResize, hideSelectionHandles, is4ResizeHandles, isAutoRescale, isBoundingRectInvalid, isChildOf, isDraggable, isDragsNode, isInitializing, isPointInObj, isResizable, isSelectable, isSkipsUndoManager, isSuspendChildUpdates, isSuspendUpdates, isTopLevel, isUpdatePartner, isVisible, ownerChange, partnerUpdate, pick, redirectSelection, remove, set4ResizeHandles, setAutoRescale, setBoundingRect, setBoundingRect, setBoundingRectForce, setBoundingRectForce, setBoundingRectInvalid, setBoundsRect, setDraggable, setDragsNode, setFlags, setHeight, setInitializing, setLeft, setLocation, setLocation, setLocationOffset, setLocationOffset, setParent, setPartner, setRectangleSpotLocation, setResizable, setSelectable, setSize, setSize, setSizeKeepingLocation, setSkipsUndoManager, setSpotLocation, setSpotLocation, setSpotLocation, setSpotLocationOffset, setSuspendChildUpdates, setSuspendUpdates, setTop, setTopLeft, setTopLeft, setUpdatePartner, setVisible, setWidth, showSelectionHandles, spotOpposite, update, update`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### JGoOverviewRectangle

    public JGoOverviewRectangle()

### JGoOverviewRectangle

    public JGoOverviewRectangle(java.awt.Point p,
                                java.awt.Dimension d)

  Construct a non-resizable rectangle with an extra-wide pen, so that it can show up reasonably at the reduced scale.

Method Detail

### updateRectFromView

    public void updateRectFromView()

  Make this JGoRectangle's position and size correspond to the observed view's position and size in the document.

### setBoundingRect

    public void setBoundingRect(int left,
                                int top,
                                int width,
                                int height)

  Keep this rectangle within the bounds of the document. Don't let this rectangle go to negative positions if the observed view doesn't allow it.

  Overrides:
    `setBoundingRect` in class `JGoObject`
  Parameters:
    `left` - the left side of the new bounding box
    `top` - the top side of the new bounding box
    `width` - the width of the new bounding box
    `height` - the height of the new bounding box

### geometryChange

    protected void geometryChange(java.awt.Rectangle prevRect)

  Handle any change in location (due to dragging) of this rectangle by changing the observed view's viewPosition. Ignore any change caused by a change in the observed view.

  Overrides:
    `geometryChange` in class `JGoObject`

### gainedSelection

    protected void gainedSelection(JGoSelection selection)

  Selecting the overview rectangle shouldn't show any handles or do anything else.

  Overrides:
    `gainedSelection` in class `JGoObject`
  Parameters:
    `selection` - the selection into which this object was added

### lostSelection

    protected void lostSelection(JGoSelection selection)

  Selecting the overview rectangle shouldn't show any handles or do anything else.

  Overrides:
    `lostSelection` in class `JGoObject`
  Parameters:
    `selection` - the selection from which this object was removed

### viewChanged

    public void viewChanged(JGoViewEvent e)

  Handle basic changes to the observed view's viewPosition or scale.

  Specified by:
    `viewChanged` in interface `JGoViewListener`
  Parameters:
    `e` - the view event describing the change to the view

### componentHidden

    public void componentHidden(java.awt.event.ComponentEvent e)

  Specified by:
    `componentHidden` in interface `java.awt.event.ComponentListener`

### componentMoved

    public void componentMoved(java.awt.event.ComponentEvent e)

  Specified by:
    `componentMoved` in interface `java.awt.event.ComponentListener`

### componentShown

    public void componentShown(java.awt.event.ComponentEvent e)

  Specified by:
    `componentShown` in interface `java.awt.event.ComponentListener`

### componentResized

    public void componentResized(java.awt.event.ComponentEvent e)

  Specified by:
    `componentResized` in interface `java.awt.event.ComponentListener`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD