All you need to do is set the floatingActionButtonLocation
property on Scaffold
class _MyHomePageState extends State<MyHomePage> {
@override
Widget build(BuildContext context) {
return new Scaffold(
appBar: ...
body: ...
floatingActionButton: MyFloatingActionButton(),
floatingActionButtonLocation: FloatingActionButtonLocation.centerFloat
);
}
class MyFloatingActionButton extends StatelessWidget {
@override
Widget build(BuildContext context) {
return FloatingActionButton.extended(
icon: Icon(Icons.plus_one),
onPressed: () => {},
label: new Text('See all results'));
}
}
Just note this is a duplicate of the question: Flutter - FloatingActionButton in the center