-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathresult_page (2).txt
71 lines (69 loc) · 2.37 KB
/
result_page (2).txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
import 'package:flutter/cupertino.dart';
import 'main.dart';
import 'package:flutter/material.dart';
import 'calculatorBrain.dart';
// ignore: must_be_immutable
class ResultPage extends StatelessWidget {
ResultPage({this.height,this.weight});
final int height;
final int weight;
Widget build(BuildContext context) {
CalculatorBrain obj=CalculatorBrain(height: height,weight: weight);
return Scaffold(
backgroundColor: Color(0xff0C1234),
appBar: AppBar(
title: Text('BMI CALCULATOR'),
backgroundColor: Color(0xFF101639),
),
body: Container(
margin: EdgeInsets.fromLTRB(20.0, 30.0, 20.0, 200.0),
decoration: BoxDecoration(
color: inactiveCardColor,
borderRadius: BorderRadius.circular(10.0),
),
width: double.infinity,
child: Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
children: <Widget>[
Padding(
padding: EdgeInsets.fromLTRB(0, 30.0, 0, 0),
child: Text(
'Your BMI IS',
style: TextStyle(
fontSize: 30,
fontWeight: FontWeight.bold,
color: Colors.white),
)),
Text(
obj.getBMI(),
style: TextStyle(color: Colors.green, fontSize: 30.0),
),
obj.getBmiText(),
Text(obj.getbmiDetails(),style: TextStyle(fontSize: 20.0,color: Colors.white,),)
,GestureDetector(
onTap:(){ Navigator.pop(context);},
child: Container(
margin: EdgeInsets.only(top:10.0),
width: double.infinity,
height: 100.0,
child: Center(
child: Text(
'Recalculate',
style: TextStyle(
fontSize: 30.0,
fontWeight: FontWeight.bold,
color: Colors.white),
),
),
decoration: BoxDecoration(
color: Colors.pink,
),
),
), ],
),
),
),
);
}
}