-
-
Save mmanflori/99b9293a99ee3f92f86d3c16fac194eb to your computer and use it in GitHub Desktop.
xxxhdpi und co
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(Tut09()); | |
class Tut09 extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( | |
title: 'Flutter Demo', | |
theme: ThemeData( | |
primarySwatch: Colors.blue, | |
scaffoldBackgroundColor: Colors.white, | |
), | |
home: Tut09Demo(title: 'Tut09 Demo'), | |
); | |
} | |
} | |
class Tut09Demo extends StatelessWidget { | |
Tut09Demo({Key key,this.title}):super(key:key); | |
final String title; | |
@override | |
Widget build(BuildContext context) { | |
var assetsImage = new AssetImage("bilder/london.png"); | |
var image =new Image(image: assetsImage,height: 48.0,width: 48.0); | |
return Scaffold( | |
body: Center( | |
child: Column( | |
mainAxisAlignment: MainAxisAlignment.center, | |
children: <Widget>[ | |
Container( | |
decoration: BoxDecoration( | |
color: Colors.white, | |
boxShadow: <BoxShadow>[ | |
BoxShadow ( | |
color: const Color(0xcc000000), | |
offset: Offset(0.0, 2.0), | |
blurRadius: 4.0, | |
), | |
], | |
borderRadius:BorderRadius.all(const Radius.circular(24.0)), | |
), | |
padding: EdgeInsets.all(10.0), | |
margin: EdgeInsets.all(10.0), | |
child: Card( | |
elevation: 5.0, | |
child: Column( | |
children: <Widget>[ | |
image, | |
], | |
), | |
), | |
) | |
], | |
), | |
), | |
); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment