We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 94e06b5 commit 40bd474Copy full SHA for 40bd474
src/main/java/org/scijava/ui/swing/widget/SwingNumberWidget.java
@@ -341,7 +341,7 @@ private void syncSliders() {
341
/** Generate a suitable format pattern. */
342
private String suitableFormat(Number... values) {
343
Integer maxScale = Arrays.stream(values)
344
- .map(n -> new BigDecimal("" + n.doubleValue()).stripTrailingZeros().scale()).max(Integer::compare)
+ .map(n -> new BigDecimal("" + (n == null ? 0.0 : n.doubleValue())).stripTrailingZeros().scale()).max(Integer::compare)
345
.get();
346
return formatForScale(maxScale);
347
}
0 commit comments