|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.jscroll.widgets.FramePositioning
This class provides internal frame positioning methods for use by
DesktopScrollPane
.
Field Summary |
Fields inherited from interface org.jscroll.widgets.DesktopConstants |
CONTENTS_CHANGED_COLOR, MAX_FRAMES, MAXIMUM_BUTTON_WIDTH, MINIMUM_BUTTON_WIDTH, X_OFFSET, Y_OFFSET |
Constructor Summary | |
FramePositioning(DesktopScrollPane desktopScrollpane)
creates the FramePositioning object |
Method Summary | |
Point |
cascadeInternalFrame(JInternalFrame f)
cascades the given internal frame based upon the current number of internal frames |
void |
cascadeInternalFrames()
cycles through and cascades all internal frames |
boolean |
getAutoTile()
returns the autoTile mode |
void |
setAutoTile(boolean autoTile)
turns autoTile on or off |
void |
tileInternalFrames()
tiles internal frames upon the desktop. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public FramePositioning(DesktopScrollPane desktopScrollpane)
desktopScrollpane
- a reference to the DesktopScrollpane objectMethod Detail |
public void setAutoTile(boolean autoTile)
autoTile
- boolean
representing autoTile mode.
If true
, then all new frames are tiled automatically.
If false
, then all new frames are cascaded automatically.public boolean getAutoTile()
boolean
representing current autoTile modepublic void cascadeInternalFrames()
public Point cascadeInternalFrame(JInternalFrame f)
f
- the internal frame to cascade
public void tileInternalFrames()
while (frames) {
numCols = (int)sqrt(totalFrames);
numRows = totalFrames / numCols;
remainder = totalFrames % numCols
if ((numCols-curCol) <= remainder) {
numRows++; // add an extra row for this column
}
}
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |