title: JavaFX Integer Spinner (IntegerSpinnerValueFactory) does not wrap around the value to minimum
body: <p>I have created an Integer Spinner with values</p>
  <p><code>min (5), max (15) and initialValue (12)</code> and <code>wrapAround (true)</code>.</p>
  <p>Once the spinner reaches the <code>max (15)</code> value during increment, instead of resetting the value to <code>min (5)</code> as it says in the <a href="https://openjfx.io/javadoc/11/javafx.controls/javafx/scene/control/SpinnerValueFactory.html#setWrapAround(boolean)" rel="nofollow noreferrer">documentation</a>, it is being reset to value <code>10 (max (15) - min (5))</code></p>
  <blockquote>
  <p>public final void setWrapAround​(boolean value)</p>
  <p>Sets the value of the property wrapAround.</p>
  <p><strong>Property description:</strong></p>
  <p>The wrapAround property is used to specify whether the value factory should be circular. For example, should an integer-based value model increment from the maximum value back to the minimum value (and vice versa).</p>
  </blockquote>
  <p>Note: Decrement works properly, once it reaches the <code>min (5)</code> value, Spinner value automatically set to <code>max (15)</code></p>
  <pre><code>public class IntSpinnerTest extends Application
  {
    @Override
    public void start(Stage stage) throws Exception
    {
      var spinner = new Spinner&lt;Integer&gt;();
  
      var factory = new SpinnerValueFactory.IntegerSpinnerValueFactory(5, 15, 12);
      factory.setWrapAround(true);
  
      spinner.setValueFactory(factory);
  
      stage.setScene(new Scene(new BorderPane(spinner), 400, 200));
  
      stage.setTitle(&quot;IntSpinnerTest&quot;);
      stage.centerOnScreen();
      stage.show();
    }
  
    public static void main(String[] args)
    {
      launch(args);
    }
  }
  </code></pre>