Sets the rounded rectangle corner diameter (pixels).
(int size)
| 1063 | |
| 1064 | /** Sets the rounded rectangle corner diameter (pixels). */ |
| 1065 | public static void setRoundRectArcSize(int size) { |
| 1066 | if (size<=0) |
| 1067 | rectType = RECT_ROI; |
| 1068 | else { |
| 1069 | arcSize = size; |
| 1070 | Prefs.set(CORNER_DIAMETER, arcSize); |
| 1071 | } |
| 1072 | repaintTool(RECTANGLE); |
| 1073 | ImagePlus imp = WindowManager.getCurrentImage(); |
| 1074 | Roi roi = imp!=null?imp.getRoi():null; |
| 1075 | if (roi!=null && roi.getType()==Roi.RECTANGLE) |
| 1076 | roi.setCornerDiameter(rectType==ROUNDED_RECT_ROI?arcSize:0); |
| 1077 | } |
| 1078 | |
| 1079 | /** Returns 'true' if the multi-point tool is enabled. */ |
| 1080 | public static boolean getMultiPointMode() { |
no test coverage detected