public class ViewportLayout extends AbstractHintLayout
isObservingVisibility, preferredSize
Constructor and Description |
---|
ViewportLayout() |
Modifier and Type | Method and Description |
---|---|
protected Dimension |
calculateMinimumSize(IFigure figure,
int wHint,
int hHint)
Returns the minimum size required by the input viewport figure.
|
protected Dimension |
calculatePreferredSize(IFigure parent,
int wHint,
int hHint)
Calculates and returns the preferred size of the figure based on the
given hints.
|
protected boolean |
isSensitiveHorizontally(IFigure parent)
Returns whether this layout manager is sensitive to changes in the
horizontal hint.
|
protected boolean |
isSensitiveVertically(IFigure parent)
Returns whether this layout manager is sensitive to changes in the
vertical hint.
|
void |
layout(IFigure figure)
Lays out the given figure.
|
getMinimumSize, getPreferredSize, invalidate
calculatePreferredSize, getBorderPreferredSize, getConstraint, getMinimumSize, getPreferredSize, invalidate, isObservingVisibility, remove, setConstraint, setObserveVisibility
protected Dimension calculateMinimumSize(IFigure figure, int wHint, int hHint)
calculateMinimumSize
in class AbstractHintLayout
figure
- the Figure on which this layout is installedwHint
- the width hinthHint
- the height hintAbstractHintLayout.calculateMinimumSize(IFigure, int, int)
protected Dimension calculatePreferredSize(IFigure parent, int wHint, int hHint)
calculatePreferredSize
in class AbstractLayout
parent
- the Viewport whose preferred size is to be calculatedwHint
- the width hinthHint
- the height hintprotected boolean isSensitiveHorizontally(IFigure parent)
AbstractHintLayout
true
.isSensitiveHorizontally
in class AbstractHintLayout
parent
- the layout's containertrue
if this layout is sensite to horizontal hint
changesAbstractHintLayout.isSensitiveHorizontally(IFigure)
protected boolean isSensitiveVertically(IFigure parent)
AbstractHintLayout
true
.isSensitiveVertically
in class AbstractHintLayout
parent
- the layout's containertrue
if this layout is sensite to vertical hint
changesAbstractHintLayout.isSensitiveHorizontally(IFigure)
public void layout(IFigure figure)
LayoutManager
figure
- The figureLayoutManager.layout(IFigure)
Copyright (c) IBM Corp. and others 2000, 2011. All Rights Reserved.