Bottom of Flutter cheat sheet

Flutter has more than one kind of buttons I would like to write it in the list at this time.

FlatButton

Preview

FlatButton (
       color: Colors.grey,
       onPressed: () {}, child: Text ("flat button")
),

RaiseButton

Preview

RaisedButton (
       onPressed: () {},
       child: Text ("raise button"),
),

OutlineButton

Preview

OutlineButton (
      onPressed: () {},
      child: Text ("outline text"),
      borderSide: BorderSide (color: Colors.black),
)

borderSide shape By customizing the attributes and attributes you can create various buttons.

OutlineButton(
      onPressed: (){},
      child: Text("FlatButton", style: TextStyle(color: Colors.blue),),
      borderSide: BorderSide(color: Colors.blue),
      shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(30.0)),
),

IconButton

Preview

IconButton(
      icon: Icon(Icons.android, color: Colors.green,),
      onPressed: (){}
),

FloatingButton

Preview

Scaffold(
      appBar: AppBar(),
      floatingActionButton: FloatingActionButton(
        onPressed: () {},
        child: Icon(Icons.add),
),)

Large FloatingButton can also be created.

Preview

Scaffold(
      appBar: AppBar(),
      floatingActionButton: FloatingActionButton.extended(
        onPressed: () {},
        label: Text("Large Floating Button"),
        icon: Icon(Icons.add),
      ),
      floatingActionButtonLocation: FloatingActionButtonLocation.centerFloat,
)

PopupMenuButton

When you push the button, it will become such a button that Pull Down appears.

Preview

PopupMenuButton<String>(
  itemBuilder: (BuildContext context) => <PopupMenuEntry<String>>[
    const PopupMenuItem<String>(
      child: Text('test 1'),
    ),
    const PopupMenuItem<String>(
      child: Text('test 2'),
    ),
    const PopupMenuItem<String>(
      child: Text('test 3'),
    ),
    const PopupMenuItem<String>(
      child: Text('test 4'),
    ),
  ]