title: Creating sliding on/off Switch button in javaFX
body: <p>Can anyone please suggest me a method to create a on/off switch button like as the image shown below, using JavaFX.</p>
  
  <p><img src="https://i.stack.imgur.com/rVrPi.jpg" alt="enter image description here"></p>
  
  <p>I have tried to find a method but couldn't get it.</p>