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'),
)
HWPadding
| Name | Type | Default | Description |
|---|---|---|---|
child | HWWidget | required | Widget being inset. |
padding | HWEdgeInsets | required | Insets 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
- iOS: SwiftUI
.padding(_:)with explicitEdgeInsets. - Android: Glance
GlanceModifier.padding(...)with per-sidedpvalues.