Colors
1. color: Colors.blue – set background color
Container(color: Colors.blue);
█████████████████████████████████████
2. color: Colors.black – set text color
Text(‘Black text’, style: TextStyle(color: Colors.black));
█████████████████████████████████████
3. Colors.red.withOpacity(0.5) – transparency
Container(color: Colors.red.withOpacity(0.5));
█████████████████████████████████████
4. Colors.green.shade200 – shade
Container(color: Colors.green.shade200);
█████████████████████████████████████
5. Theme.of(context).primaryColor – use theme color
Container(color: Theme.of(context).primaryColor);
█████████████████████████████████████
Borders & Decoration
6. border: Border.all(color: Colors.black, width: 3)
Container(decoration: BoxDecoration(border: Border.all(color: Colors.black, width: 3)));
█████████████████████████████████████
7. borderRadius: BorderRadius.circular(12) – rounded corners
Container(decoration: BoxDecoration(color: Colors.blue, borderRadius: BorderRadius.circular(12)));
█████████████████████████████████████
8. BoxDecoration(color: Colors.blue) – background color
Container(decoration: BoxDecoration(color: Colors.blue));
█████████████████████████████████████
9. BoxDecoration(border: Border.all(color: Colors.grey)) – border
Container(decoration: BoxDecoration(border: Border.all(color: Colors.grey)));
█████████████████████████████████████
10. BoxDecoration(boxShadow: [BoxShadow(color: Colors.black26, blurRadius: 8)]) – shadow
Container(decoration: BoxDecoration(boxShadow: [BoxShadow(color: Colors.black26, blurRadius: 8)]));
█████████████████████████████████████
Spacing
11. margin: EdgeInsets.all(8) – equal margin
Container(margin: EdgeInsets.all(8));
█████████████████████████████████████
12. margin: EdgeInsets.symmetric(horizontal: 20, vertical: 10)
Container(margin: EdgeInsets.symmetric(horizontal: 20, vertical: 10));
█████████████████████████████████████
13. padding: EdgeInsets.only(left: 12, top: 8)
Container(padding: EdgeInsets.only(left: 12, top: 8));
█████████████████████████████████████
14. SizedBox(height: 20) – vertical space
SizedBox(height: 20);
█████████████████████████████████████
15. SizedBox(width: 20) – horizontal space
SizedBox(width: 20);
█████████████████████████████████████
Text & Styles
16. Text(‘Hello’) – simple text
Text(‘Hello’);
█████████████████████████████████████
17. Text(‘Bold’, style: TextStyle(fontWeight: FontWeight.bold))
Text(‘Bold’, style: TextStyle(fontWeight: FontWeight.bold));
█████████████████████████████████████
18. Text(‘Big’, style: TextStyle(fontSize: 24))
Text(‘Big’, style: TextStyle(fontSize: 24));
█████████████████████████████████████
19. Text(‘Italic’, style: TextStyle(fontStyle: FontStyle.italic))
Text(‘Italic’, style: TextStyle(fontStyle: FontStyle.italic));
█████████████████████████████████████
20. Text(‘Underline’, style: TextStyle(decoration: TextDecoration.underline))
Text(‘Underline’, style: TextStyle(decoration: TextDecoration.underline));
█████████████████████████████████████
21. Text(‘Red’, style: TextStyle(color: Colors.red))
Text(‘Red’, style: TextStyle(color: Colors.red));
█████████████████████████████████████
22. Text(‘Shadow’, style: TextStyle(shadows: [Shadow(color: Colors.black, blurRadius: 4)]))
Text(‘Shadow’, style: TextStyle(shadows: [Shadow(color: Colors.black, blurRadius: 4)]));
█████████████████████████████████████
23. textAlign: TextAlign.center
Text(‘Center text’, textAlign: TextAlign.center);
█████████████████████████████████████
24. textAlign: TextAlign.right
Text(‘Right text’, textAlign: TextAlign.right);
█████████████████████████████████████
Layout Widgets
25. Row(children: [Text(‘A’), Text(‘B’)]) – horizontal
Row(children: [Text(‘A’), SizedBox(width: 8), Text(‘B’)]);
█████████████████████████████████████
26. Column(children: [Text(‘Top’), Text(‘Bottom’)]) – vertical
Column(children: [Text(‘Top’), SizedBox(height: 8), Text(‘Bottom’)]);
█████████████████████████████████████
27. Stack(children: […]) – overlap
Stack(children: [Container(width: 100, height: 100, color: Colors.blue), Positioned(top: 20, left: 20, child: Text(‘On top’))]);
█████████████████████████████████████
28. Expanded(child: Text(‘Fill space’))
Row(children: [Expanded(child: Text(‘This fills space’))]);
█████████████████████████████████████
29. Flexible(child: Text(‘Flexible’))
Row(children: [Flexible(child: Text(‘Flexible text that wraps’))]);
█████████████████████████████████████
30. Wrap(children: [Text(‘One’), Text(‘Two’)])
Wrap(spacing: 8, children: [Text(‘One’), Text(‘Two’), Text(‘Three’)]);
█████████████████████████████████████
31. Spacer() – empty flexible space
Row(children: [Text(‘Left’), Spacer(), Text(‘Right’)]);
█████████████████████████████████████
Containers & Boxes
32. Container(width: 100, height: 100, color: Colors.blue)
Container(width: 100, height: 100, color: Colors.blue);
█████████████████████████████████████
33. Card(child: Text(‘Inside card’))
Card(child: Padding(padding: EdgeInsets.all(8), child: Text(‘Inside card’)));
█████████████████████████████████████
34. CircleAvatar(backgroundColor: Colors.blue, child: Icon(Icons.person))
CircleAvatar(backgroundColor: Colors.blue, child: Icon(Icons.person));
█████████████████████████████████████
35. Divider(thickness: 2, color: Colors.black)
Divider(thickness: 2, color: Colors.black);
█████████████████████████████████████
Alignment & Position
36. Align(alignment: Alignment.center)
Align(alignment: Alignment.center, child: Text(‘Centered’));
█████████████████████████████████████
37. Align(alignment: Alignment.topLeft)
Align(alignment: Alignment.topLeft, child: Text(‘Top left’));
█████████████████████████████████████
38. Center(child: Text(‘Centered’))
Center(child: Text(‘Centered’));
█████████████████████████████████████
39. Positioned(top: 20, left: 10, child: Text(‘Absolute’))
Stack(children: [Positioned(top: 20, left: 10, child: Text(‘Absolute’))]);
█████████████████████████████████████
Input & Buttons
40. TextField(decoration: InputDecoration(labelText: ‘Enter name’))
TextField(decoration: InputDecoration(labelText: ‘Enter name’));
█████████████████████████████████████
41. ElevatedButton(onPressed: () {}, child: Text(‘Click’))
ElevatedButton(onPressed: () {}, child: Text(‘Click’));
█████████████████████████████████████
42. TextButton(onPressed: () {}, child: Text(‘Flat’))
TextButton(onPressed: () {}, child: Text(‘Flat’));
█████████████████████████████████████
43. IconButton(onPressed: () {}, icon: Icon(Icons.add))
IconButton(onPressed: () {}, icon: Icon(Icons.add));
█████████████████████████████████████
Images & Icons
44. Image.network(‘https://example.com/img.png’)
Image.network(‘https://example.com/img.png’);
█████████████████████████████████████
45. Image.asset(‘assets/logo.png’)
Image.asset(‘assets/logo.png’);
█████████████████████████████████████
46. Icon(Icons.home, size: 32, color: Colors.blue)
Icon(Icons.home, size: 32, color: Colors.blue);
█████████████████████████████████████
Lists & Grids
47. ListView(children: [Text(‘Item 1’), Text(‘Item 2’)])
ListView(children: [Text(‘Item 1’), Text(‘Item 2’)]);
█████████████████████████████████████
48. GridView.count(crossAxisCount: 2, children: […])
GridView.count(crossAxisCount: 2, children: [Text(‘A’), Text(‘B’), Text(‘C’), Text(‘D’)]);
█████████████████████████████████████
49. ListTile(leading: Icon(Icons.star), title: Text(‘Title’), subtitle: Text(‘Subtitle’))
ListTile(leading: Icon(Icons.star), title: Text(‘Title’), subtitle: Text(‘Subtitle’));
█████████████████████████████████████
Other Handy Widgets
50. Scaffold(appBar: AppBar(title: Text(‘App’)), body: Text(‘Body’))
Scaffold(appBar: AppBar(title: Text(‘App’)), body: Center(child: Text(‘Body’)));
█████████████████████████████████████
