scijava / script-editor

Script Editor and Interpreter for SciJava script languages
http://imagej.net/Script_Editor
BSD 2-Clause "Simplified" License
12 stars 12 forks source link

Bug with integer persistence and default value #25

Closed LauLauThom closed 5 years ago

LauLauThom commented 5 years ago

I noticed that the persistence set up an unexpected value (actually 0) when the value entered by the user is the one defined as default.

ex:

#@ int (label="delta", min=-5, value=10) delta 
print delta

The persisted value is indeed recovered in every case, except if the user enters 10, then the next time the script is launched the value is 0 !

Tested on 2 different fiji installations, with Jython and the IJ macro language.

Associated post on the forum

LauLauThom commented 5 years ago

It works fine with Integer though

imagejan commented 5 years ago

Thanks @Jindil for reporting, and sorry for the delayed reply.

I'm closing this in favor of these two issues in scijava-common: