padding method
void
padding({
- double? all,
- double? horizontal,
- double? vertical,
- double? top,
- double? bottom,
- double? left,
- double? right,
inherited
Empty space to inscribe inside the decoration
. The child
, if any, is placed inside this padding.
All properties work together
..padding(all: 10, bottom: 20) // gives a different padding at the bottom
Implementation
void padding(
{double? all,
double? horizontal,
double? vertical,
double? top,
double? bottom,
double? left,
double? right}) {
_styleModel.padding = EdgeInsets.only(
top: top ?? vertical ?? all ?? 0.0,
bottom: bottom ?? vertical ?? all ?? 0.0,
left: left ?? horizontal ?? all ?? 0.0,
right: right ?? horizontal ?? all ?? 0.0);
}