(Rectangle bounds, Insets insets)
| 159 | } |
| 160 | |
| 161 | private static Rectangle shrinkByInsets(Rectangle bounds, Insets insets) { |
| 162 | Rectangle shrunk = new Rectangle(bounds); |
| 163 | if (insets == null) return shrunk; |
| 164 | shrunk.x += insets.left; |
| 165 | shrunk.y += insets.top; |
| 166 | shrunk.width -= insets.left + insets.right; |
| 167 | shrunk.height -= insets.top + insets.bottom; |
| 168 | return shrunk; |
| 169 | } |
| 170 | |
| 171 | public static Rectangle getZeroBasedMaxBounds() { |
| 172 | for (GraphicsConfiguration config : getScreenConfigs()) { |