()
| 324 | } |
| 325 | |
| 326 | public void positionWindow() { |
| 327 | Dimension screen = IJ.getScreenSize(); |
| 328 | Dimension window = getSize(); |
| 329 | if (window.width==0) |
| 330 | return; |
| 331 | int left = screen.width/2-window.width/2; |
| 332 | int top = screen.height/(IJ.isWindows()?6:5); |
| 333 | if (IJ.isMacOSX()) |
| 334 | top = (screen.height-window.height)/4; |
| 335 | if (top<0) top = 0; |
| 336 | if (nWindows<=0 || xoffset>8*XINC) |
| 337 | {xoffset=0; yoffset=0;} |
| 338 | setLocation(left+xoffset, top+yoffset); |
| 339 | xoffset+=XINC; yoffset+=YINC; |
| 340 | nWindows++; |
| 341 | } |
| 342 | |
| 343 | void setWindowTitle(String title) { |
| 344 | Menus.updateWindowMenuItem(getTitle(), title); |
no test coverage detected