FPortalSpacing constructor

const FPortalSpacing(
  1. double spacing, {
  2. bool diagonal,
})

Creates a FPortalSpacing that applies a fixed spacing between the child and its portal when they do not overlap.

The spacing parameter determines the amount of space to apply between the anchors.

The diagonal parameter controls how spacing is applied when both anchors are at corners:

  • When diagonal is false (default), spacing is not applied if both anchors are at corners.
  • When diagonal is true, spacing is applied regardless of anchor positions.

Implementation

const factory FPortalSpacing(double spacing, {bool diagonal}) = _FPortalSpacing;