title: Create a Segmented Control Widget with slider button - Flutter
body: <p>How do I create something similar to this?:</p>
  
  <p>Demo :<br>
  <a href="https://i.stack.imgur.com/fJJCk.gif" rel="noreferrer"><img src="https://i.stack.imgur.com/fJJCk.gif" alt="Demo "></a></p>
  
  <p>I know flutter has</p>
  
  <pre><code>CupertinoSegmentedControl()
  </code></pre>
  
  <p>But this creates something similar to tabs, nothing that slides like something a Switch with a button inside.</p>