Search this API

y.view
Class Overview

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by javax.swing.JComponent
              extended by y.view.Graph2DView
                  extended by y.view.Overview
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, java.beans.PropertyChangeListener, java.io.Serializable, java.util.EventListener, javax.swing.ScrollPaneConstants, AnimationListener, View, View2DConstants, ViewContainer

public class Overview
extends Graph2DView
implements java.beans.PropertyChangeListener

This is a specialized View which acts as Overview. The View displays always the entire Graph. Additionally it highlights the region that the associated Graph2DView currently displays.

The Overview has a specialized ViewMode associated with it that allows to change the viewport of the associated Graph2DView by dragging the highlighted area.
To adjust the overview's appearance and behavior one can use the following client properties.
Please note, that these client properties are not part of the official yFiles API and may change in a future yFiles version without further notice. Furthermore the effect of setting those properties might differ depending on the operating system that runs the application.

See Also:
Serialized Form
 
Your browser does not support SVG content.

Nested Class Summary
 
Nested classes/interfaces inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent
 
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
 
Fields inherited from class y.view.Graph2DView
BG_LAYER, CONTENT_POLICY_BACKGROUND_DRAWABLES, CONTENT_POLICY_FOREGROUND_DRAWABLES, CONTENT_POLICY_GRAPH, CONTENT_POLICY_GRAPH_DRAWABLES, FG_LAYER, LAYER_MODE, MOVE_SELECTION_MODE, NORMAL_MODE, SELECTION_BOX_MODE, UNBUFFERED_MODE
 
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface javax.swing.ScrollPaneConstants
COLUMN_HEADER, HORIZONTAL_SCROLLBAR, HORIZONTAL_SCROLLBAR_ALWAYS, HORIZONTAL_SCROLLBAR_AS_NEEDED, HORIZONTAL_SCROLLBAR_NEVER, HORIZONTAL_SCROLLBAR_POLICY, LOWER_LEADING_CORNER, LOWER_LEFT_CORNER, LOWER_RIGHT_CORNER, LOWER_TRAILING_CORNER, ROW_HEADER, UPPER_LEADING_CORNER, UPPER_LEFT_CORNER, UPPER_RIGHT_CORNER, UPPER_TRAILING_CORNER, VERTICAL_SCROLLBAR, VERTICAL_SCROLLBAR_ALWAYS, VERTICAL_SCROLLBAR_AS_NEEDED, VERTICAL_SCROLLBAR_NEVER, VERTICAL_SCROLLBAR_POLICY, VIEWPORT
 
Fields inherited from interface y.view.View2DConstants
GRID_CROSS, GRID_LINES, GRID_NONE, GRID_POINTS
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
Overview(Graph2DView view)
          Create a new Overview for a given Graph2DView.
 
Method Summary
protected  void adjustWorldRect(Graph2DView view)
          Adjusts the world rectangle that defines the accessible area of the given view after its zoom and clip has been changed.
 void propertyChange(java.beans.PropertyChangeEvent ev)
          Updates the view upon receiving a property change event.
 void reshape(int x, int y, int w, int h)
          Called on resize events
 void updateView()
          Updates the View.
 
Methods inherited from class y.view.Graph2DView
addBackgroundDrawable, addDrawable, addViewChangeListener, addViewMode, adjustScrollBarVisibility, animationPerformed, applyLayout, applyLayoutAnimated, calculateContentBounds, closeLabelEditor, createGlassPane, createGraphicsContext, createToolTip, fitContent, fitContent, fitRectangle, fitWorldRect, focusView, getBackgroundDrawables, getBackgroundRenderer, getCanvasComponent, getCanvasSize, getCenter, getComponent, getContentPolicy, getCurrentView, getDrawables, getFitContentOnResize, getFrame, getGlassPane, getGraph2D, getGraph2DRenderer, getGridColor, getGridMode, getGridResolution, getGridType, getHitInfoFactory, getHorizontalScrollBarPolicy, getImage, getPaintDetailThreshold, getRenderingHints, getVerticalScrollBarPolicy, getViewControl, getViewCursor, getViewModes, getViewPoint, getViewPoint2D, getViewSize, getVisibleRect, getVisibleRect2D, getWorldRect, getWorldRect2D, getZoom, isAntialiasedPainting, isFocusTraversable, isGridVisible, isInputSuppressed, isOptimizedDrawingEnabled, isValidateRoot, openLabelEditor, openLabelEditor, openLabelEditor, openLabelEditor, openLabelEditorCentered, openLabelEditorCentered, paintSelectionBox, paintVisibleContent, print, registerDefaultViewActions, registerKeyboardAction, registerKeyboardAction, removeBackgroundDrawable, removeDrawable, removeViewMode, requestFocus, setAntialiasedPainting, setBackgroundRenderer, setBounds, setCenter, setContentPolicy, setDrawingMode, setFitContentOnResize, setGraph2D, setGraph2DRenderer, setGridColor, setGridMode, setGridResolution, setGridType, setGridVisible, setHitInfoFactory, setHorizontalScrollBarPolicy, setInputSuppressed, setPaintDetailThreshold, setRenderingHints, setRenderingHints, setScrollBarPolicy, setSelectionBoxBounds, setSelectionBoxBounds2D, setToolTipText, setVerticalScrollBarPolicy, setViewControl, setViewCursor, setViewPoint, setViewPoint2D, setWorldRect, setWorldRect2D, setZoom, showPopup, toViewCoordX, toViewCoordY, toWorldCoordX, toWorldCoordY, unregisterKeyboardAction, updateView, updateView, updateWorldRect, zoomToArea
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getAccessibleContext, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getUIClassID, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, paramString, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, update, updateUI
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Overview

public Overview(Graph2DView view)
Create a new Overview for a given Graph2DView.

Method Detail

adjustWorldRect

protected void adjustWorldRect(Graph2DView view)
Adjusts the world rectangle that defines the accessible area of the given view after its zoom and clip has been changed. By default, the world rectangle will be adjusted to the size of the graph's bounding box.


updateView

public void updateView()
Updates the View.

Specified by:
updateView in interface View
Overrides:
updateView in class Graph2DView

reshape

public void reshape(int x,
                    int y,
                    int w,
                    int h)
Called on resize events

Overrides:
reshape in class javax.swing.JComponent

propertyChange

public void propertyChange(java.beans.PropertyChangeEvent ev)
Updates the view upon receiving a property change event.

Specified by:
propertyChange in interface java.beans.PropertyChangeListener

© Copyright 2000-2022,
yWorks GmbH.
All rights reserved.