HWPadding

Insets a child by an HWEdgeInsets. Use one of the three named constructors to specify uniform, symmetric, or per-side padding.

HWPadding(
  padding: const HWEdgeInsets.symmetric(horizontal: 12, vertical: 8),
  child: HWText.fixed('Padded'),
)

Parameters

HWPadding

NameTypeDefaultDescription
childHWWidgetrequiredWidget being inset.
paddingHWEdgeInsetsrequiredInsets applied to child.

HWEdgeInsets

Three const constructors:

  • HWEdgeInsets.all(double value) — same value on every side.
  • HWEdgeInsets.symmetric({double vertical = 0, double horizontal = 0}) — paired sides.
  • HWEdgeInsets.only({double left = 0, double top = 0, double right = 0, double bottom = 0}) — per-side.

Platform mapping