Package org.eclipse.draw2d

# Class AutoscaleFreeformViewport

java.lang.Object
org.eclipse.draw2d.Figure
org.eclipse.draw2d.Viewport
org.eclipse.draw2d.FreeformViewport
org.eclipse.draw2d.AutoscaleFreeformViewport

All Implemented Interfaces:
  `PropertyChangeListener`, `EventListener`, `IFigure`

public class AutoscaleFreeformViewport extends FreeformViewport
IMPORTANT: This class is not part of the GEF public API. It is marked public only so that it can be by other GEF plugins and should never be accessed from application code.

@noreference
  This class is not intended to be referenced by clients.

## Nested Class Summary

## Nested classes/interfaces inherited from class org.eclipse.draw2d.Figure

`Figure.FigureIterator, Figure.IdentitySearch, Figure.ReverseFigureChildrenIterator`

## Nested classes/interfaces inherited from interface org.eclipse.draw2d.IFigure

`IFigure.NoInsets`

## Field Summary

### Fields inherited from class org.eclipse.draw2d.Viewport

`PROPERTY_VIEW_LOCATION`

### Fields inherited from class org.eclipse.draw2d.Figure

`bgColor, border, bounds, fgColor, flags, font, MAX_FLAG, maxSize, minSize, NO_MANAGER, prefSize, toolTip`

### Fields inherited from interface org.eclipse.draw2d.IFigure

`MAX_DIMENSION, MIN_DIMENSION, NO_INSETS`

## Constructor Summary

Constructors
Constructor
Description
`AutoscaleFreeformViewport(boolean useScaledGraphics)`

## Method Summary

Modifier and Type
Method
Description
`IFigure`
`getContents()`
Returns the view, which is the contents of the `ScrollPane` associated with this Viewport.
`protected FreeformFigure`
`getFreeformFigure()`
Returns the `FreeformFigure` that is the contents of this viewport or `null`, if the contents is not set or not a `FreeformFigure`.
`void`
`setContents(IFigure figure)`
Sets this Viewport to be associated with the passed Figure.
`void`
`setScale(double scale)`

### Methods inherited from class org.eclipse.draw2d.FreeformViewport

`readjustScrollBars, useLocalCoordinates`

### Methods inherited from class org.eclipse.draw2d.Viewport

`getClientArea, getContentsTracksHeight, getContentsTracksWidth, getHorizontalRangeModel, getVerticalRangeModel, getViewLocation, isCoordinateSystem, paintClientArea, propertyChange, setContentsTracksHeight, setContentsTracksWidth, setHorizontalLocation, setHorizontalRangeModel, setIgnoreScroll, setVerticalLocation, setVerticalRangeModel, setViewLocation, setViewLocation, translateFromParent, translateToParent, useGraphicsTranslate, validate`

### Methods inherited from class org.eclipse.draw2d.Figure

`add, add, add, add, addAncestorListener, addCoordinateListener, addFigureListener, addFocusListener, addKeyListener, addLayoutListener, addListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, containsPoint, containsPoint, erase, findDescendantAtExcluding, findFigureAt, findFigureAt, findFigureAt, findFigureAtExcluding, findMouseEventTargetAt, findMouseEventTargetInDescendantsAt, fireCoordinateSystemChanged, fireFigureMoved, fireMoved, firePropertyChange, firePropertyChange, firePropertyChange, getBackgroundColor, getBorder, getBounds, getChildren, getChildrenRevIterable, getClientArea, getClippingStrategy, getCursor, getFlag, getFont, getForegroundColor, getInsets, getLayoutManager, getListeners, getListenersIterable, getLocalBackgroundColor, getLocalFont, getLocalForegroundColor, getLocation, getMaximumSize, getMinimumSize, getMinimumSize, getParent, getPreferredSize, getPreferredSize, getSize, getToolTip, getUpdateManager, handleFocusGained, handleFocusLost, handleKeyPressed, handleKeyReleased, handleMouseDoubleClicked, handleMouseDragged, handleMouseEntered, handleMouseExited, handleMouseHover, handleMouseMoved, handleMousePressed, handleMouseReleased, handleMouseWheelScrolled, hasFocus, internalGetEventDispatcher, intersects, invalidate, invalidateTree, isEnabled, isFocusTraversable, isMirrored, isMouseEventTarget, isOpaque, isRequestFocusEnabled, isShowing, isValid, isValidationRoot, isVisible, layout, optimizeClip, paint, paintBorder, paintChildren, paintFigure, primTranslate, remove, removeAll, removeAncestorListener, removeCoordinateListener, removeFigureListener, removeFocusListener, removeKeyListener, removeLayoutListener, removeListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, revalidate, setBackgroundColor, setBorder, setBounds, setChildrenDirection, setChildrenEnabled, setChildrenOrientation, setClippingStrategy, setConstraint, setCursor, setEnabled, setFlag, setFocusTraversable, setFont, setForegroundColor, setLayoutManager, setLocation, setMaximumSize, setMinimumSize, setOpaque, setParent, setPreferredSize, setPreferredSize, setRequestFocusEnabled, setSize, setSize, setToolTip, setValid, setVisible, translate, translateToAbsolute, translateToRelative, useDoublePrecision`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### AutoscaleFreeformViewport

public AutoscaleFreeformViewport(boolean useScaledGraphics)

## Method Details

### getContents

public IFigure getContents()
Description copied from class: `Viewport`
Returns the view, which is the contents of the `ScrollPane` associated with this Viewport.

Overrides:
  `getContents` in class `Viewport`
Returns:
  the contents

### setContents

public void setContents(IFigure figure)
Description copied from class: `Viewport`
Sets this Viewport to be associated with the passed Figure.

Overrides:
  `setContents` in class `Viewport`
Parameters:
  `figure` - the new contents

### setScale

public void setScale(double scale)

### getFreeformFigure

protected FreeformFigure getFreeformFigure()
Description copied from class: `FreeformViewport`
Returns the `FreeformFigure` that is the contents of this viewport or `null`, if the contents is not set or not a `FreeformFigure`.

Overrides:
  `getFreeformFigure` in class `FreeformViewport`