public final class ScreenUtil
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static void |
center(java.awt.Window windowRef,
java.awt.Window windowToCenter)
Center a
Window on the screen where is a reference Window. |
static java.awt.Rectangle |
getScreenRectangle(java.awt.Window window)
Return a
Rectangle describing the screen on wich is a provided Window. |
public static java.awt.Rectangle getScreenRectangle(java.awt.Window window)
Rectangle describing the screen on wich is a provided Window.
If the window is between two screen, the first one is choosen.window - The window for which we want screen rectangle.public static void center(java.awt.Window windowRef,
java.awt.Window windowToCenter)
Window on the screen where is a reference Window.
If the reference window is null, the JFrame to center is centered on the first screen.windowRef - The reference window.windowToCenter - The window to center.