title: Return a new widget on button click on the same page, in a column in Flutter
body: <p>I want to return a new widget on button click on the same page, in a column.
  So I am trying to return a container on the same page as one of the children in a column, when a button is clicked.</p>
  
  <p>This is my sample code:</p>
  
  <pre><code>Column(
        children: &lt;Widget&gt;[
         // here I want to return my container in the show function
  
          Text(
            "This is a sample text",
            style: TextStyle(fontSize: 40),
  
          ),
          RaisedButton(
            child: Text("click"),
            onPressed: () {
              debugPrint("clicked");
              show();
            },
          )
        ],
      );
  
  
  
  show() {
      return SampleContainer();
    }
  
  
  
  class SampleContainer extends StatefulWidget {
    @override
    _SampleContainerState createState() =&gt; _SampleContainerState();
  }
  
  class _SampleContainerState extends State&lt;SampleContainer&gt; {
    @override
    Widget build(BuildContext context) {
      return Container(
        child: Text("hi"),
  
  
  );
    }
  }
  </code></pre>