formatting

This commit is contained in:
Luan Nico
2018-05-21 01:59:07 -03:00
parent 011aff0fff
commit 6be3d28493
10 changed files with 107 additions and 57 deletions

View File

@ -29,16 +29,17 @@ class Util {
});
}
material.TextPainter text(String text, {
double fontSize: 24.0,
Color color: material.Colors.black,
String fontFamily: 'Arial',
TextAlign textAlign: TextAlign.left,
TextDirection textDirection: TextDirection.ltr
}) {
material.TextStyle style = new material.TextStyle(color: color, fontSize: fontSize, fontFamily: fontFamily);
material.TextPainter text(String text,
{double fontSize: 24.0,
Color color: material.Colors.black,
String fontFamily: 'Arial',
TextAlign textAlign: TextAlign.left,
TextDirection textDirection: TextDirection.ltr}) {
material.TextStyle style = new material.TextStyle(
color: color, fontSize: fontSize, fontFamily: fontFamily);
material.TextSpan span = new material.TextSpan(style: style, text: text);
material.TextPainter tp = new material.TextPainter(text: span, textAlign: textAlign, textDirection: textDirection);
material.TextPainter tp = new material.TextPainter(
text: span, textAlign: textAlign, textDirection: textDirection);
tp.layout();
return tp;
}