round numbers to next integer
This commit is contained in:
parent
be2ab69a3f
commit
9953635ad3
@ -16,9 +16,9 @@ class FoodEntryWidget extends StatelessWidget {
|
||||
padding: const EdgeInsets.only(left: 4.0),
|
||||
child: RowWidget(
|
||||
Text(entry.name),
|
||||
Text(entry.mass.toString()),
|
||||
Text(entry.kcalPerMass.toString()),
|
||||
Text((entry.mass * entry.kcalPerMass / 100).toString()),
|
||||
Text(entry.mass.ceil().toString()),
|
||||
Text(entry.kcalPerMass.ceil().toString()),
|
||||
Text((entry.mass * entry.kcalPerMass / 100).ceil().toString()),
|
||||
IconButton(
|
||||
style: IconButton.styleFrom(padding: EdgeInsets.zero),
|
||||
onPressed: () {
|
||||
|
@ -26,7 +26,7 @@ class _SumWidgetState extends State<SumWidget> {
|
||||
null,
|
||||
null,
|
||||
const Text("kcal heute:"),
|
||||
Text('${sum.toString()}/${state.kcalLimit}'),
|
||||
Text('${sum.ceil().toString()}/${state.kcalLimit.ceil()}'),
|
||||
null,
|
||||
);
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user