Last active
February 5, 2020 00:06
-
-
Save narenarjun/a7a53b96a3c7f5fdf02183dc8d60917a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
void main() { | |
runApp(MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( | |
debugShowCheckedModeBanner: false, | |
home: Scaffold( | |
body: SmoothWidget(), | |
), | |
); | |
} | |
} | |
class SmoothWidget extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return Container( | |
width: 200.0, | |
height: 200.0, | |
decoration: BoxDecoration( | |
borderRadius: BorderRadius.circular(25.0), | |
color: Colors.cyan, | |
border: Border.all(color: Colors.black, width: 6.0), | |
), | |
child: Center( | |
child: Text( | |
"Hello World", | |
style: TextStyle( | |
fontSize: 26.0, | |
fontStyle: FontStyle.italic, | |
fontWeight: FontWeight.bold, | |
color: Colors.amber), | |
), | |
), | |
); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment