MCPcopy Create free account
hub / github.com/AstroImageJ/astroimagej / saveLUTName

Method saveLUTName

ij/src/main/java/ij/plugin/LutLoader.java:154–164  ·  view source on GitHub ↗
(ImagePlus imp, FileInfo fi)

Source from the content-addressed store, hash-verified

152 }
153
154 private void saveLUTName(ImagePlus imp, FileInfo fi) {
155 if (imp!=null && fi!=null && fi.fileName!=null) {
156 String name = fi.fileName;
157 if (name.endsWith(".lut"))
158 name = name.substring(0,name.length()-4);
159 if (name.equals("grays"))
160 imp.setProp(LUT.nameKey, null);
161 else
162 imp.setProp(LUT.nameKey, name);
163 }
164 }
165
166 void invertLut() {
167 ImagePlus imp = WindowManager.getCurrentImage();

Callers 2

showLutMethod · 0.95
createImageMethod · 0.95

Calls 4

substringMethod · 0.80
setPropMethod · 0.80
lengthMethod · 0.65
equalsMethod · 0.45

Tested by

no test coverage detected