Sized Overflow Box Widget
Complete Code For Sized Overflow Box Widget In Flutter
main.dart
import 'package:flutter/material.dart'; void main() => runApp(new MyApp()); class MyApp extends StatelessWidget { @override Widget build(BuildContext context) { return MaterialApp( debugShowCheckedModeBanner: false, home: MyHomePage(), ); } } class MyHomePage extends StatefulWidget { @override State<StatefulWidget> createState() => MyHomePageState(); } class MyHomePageState extends State<MyHomePage> { Widget build(BuildContext context) { return Scaffold( appBar: AppBar( backgroundColor: Colors.green, title: Text("SizedOverflowBox Widget")), body: Center( child: SizedOverflowBox( size: Size(50.0, 50.0), child: Container( height: 50.0, width: 50.0, color: Colors.green, ), ), ), ); } }