()
| 377 | } |
| 378 | |
| 379 | @AstroImageJ(reason = "make default location 10, 10 instead of -99,-99", modified = true) |
| 380 | public Point getPreferredLocation() { |
| 381 | int ijX = Prefs.getInt(IJ_X,10); |
| 382 | int ijY = Prefs.getInt(IJ_Y,10); |
| 383 | Rectangle maxBounds = GUI.getMaxWindowBounds(); |
| 384 | //System.out.println("getPreferredLoc1: "+ijX+" "+ijY+" "+maxBounds); |
| 385 | if (ijX>=maxBounds.x && ijY>=maxBounds.y && ijX<(maxBounds.x+maxBounds.width-75) |
| 386 | && ijY<(maxBounds.y+maxBounds.height-75)) |
| 387 | return new Point(ijX, ijY); |
| 388 | Dimension tbsize = toolbar.getPreferredSize(); |
| 389 | int ijWidth = tbsize.width+10; |
| 390 | double percent = maxBounds.width>832?0.8:0.9; |
| 391 | ijX = (int)(percent*(maxBounds.width-ijWidth)); |
| 392 | if (ijX<10) ijX = 10; |
| 393 | return new Point(ijX, maxBounds.y); |
| 394 | } |
| 395 | |
| 396 | @AstroImageJ(reason = "Update JLabel on EDT", modified = true) |
| 397 | void showStatus(String s) { |
no test coverage detected