List of utility methods to do Graphics Environment
| GraphicsConfiguration | getDefaultGraphicsConfig() get Default Graphics Config return defGraphicsConfig;
|
| Dimension | getDesktopSize() get Desktop Size return desktopBounds.getSize();
|
| GraphicsEnvironment | getLocalGraphicsEnvironment() get Local Graphics Environment return GraphicsEnvironment.getLocalGraphicsEnvironment();
|
| Rectangle | getMaximumWindowBounds() GraphicsEnvironment#getMaximumWindowBounds() return getLocalGraphicsEnvironment().getMaximumWindowBounds();
|
| Dimension | getMaximumWindowDimension() get Maximum Window Dimension GraphicsEnvironment env = GraphicsEnvironment.getLocalGraphicsEnvironment(); Rectangle bounds = env.getMaximumWindowBounds(); return new Dimension(bounds.width, bounds.height); |
| int | getMenuShortCutKeyMask() need to guard against headlessExceptions when testing. if (GraphicsEnvironment.isHeadless()) { return ((getOperatingSystem() & OS_MAC) != 0) ? KeyEvent.META_MASK : KeyEvent.CTRL_MASK; return Toolkit.getDefaultToolkit().getMenuShortcutKeyMask(); |
| Rectangle | getWindowMaxBounds() get Window Max Bounds GraphicsEnvironment ge = GraphicsEnvironment.getLocalGraphicsEnvironment();
return ge.getMaximumWindowBounds();
|
| boolean | isInteractive() is Interactive String envVar = System.getProperty("WINTERWELL_HEADLESS"); if (envVar == null) return !GraphicsEnvironment.isHeadless(); return !envVar.toLowerCase().equals("true"); |