public class ScreenPresence
extends java.lang.Object
implements java.io.Serializable
| Constructor and Description |
|---|
ScreenPresence(java.awt.Component component) |
ScreenPresence(java.awt.Point position,
java.awt.Dimension size) |
| Modifier and Type | Method and Description |
|---|---|
void |
fit(java.awt.Component component)
Fit a component to the location and size of this
screen presence.
|
java.awt.Point |
getLocation() |
java.awt.Dimension |
getSize() |
java.awt.Point |
locationToCenter(java.awt.Dimension size)
Return the location relative to this screen area that would
centre something of the given size within this screen area..
|
ScreenPresence |
smaller(double factor)
Create ScreenPresence a factor the size of this.
|
java.lang.String |
toString() |
static ScreenPresence |
wholeScreen() |
public ScreenPresence(java.awt.Point position,
java.awt.Dimension size)
public ScreenPresence(java.awt.Component component)
public void fit(java.awt.Component component)
component - public java.awt.Point getLocation()
public java.awt.Dimension getSize()
public java.awt.Point locationToCenter(java.awt.Dimension size)
size - public ScreenPresence smaller(double factor)
factor - The factor to size the new ScreenPresence by.public static ScreenPresence wholeScreen()
public java.lang.String toString()
toString in class java.lang.Object