FlowMapSection

timelines.FlowMapSection(
    source_start,
    source_end,
    target_start,
    label=None,
    target_end=None,
)

A section mapping in a FlowMap.

Represents one contiguous section that maps from a source coordinate range to a target coordinate range. Used internally by FlowMap for coordinate transformation.

In the context of flow control: - Source coordinates: The “folded” timeline (with repeats/jumps compressed) - Target coordinates: The “unfolded” timeline (linear playthrough order)

Both ranges are carried explicitly, which is what lets a FlowMap place its sections rather than only concatenate them. A section is one of two kinds:

  • Played — both ranges have the same non-zero extent. Source material is carried to the target axis, at target_start rather than necessarily at the end of the preceding section.
  • Gap — one range is empty. An insertion (empty source range) is a stretch of target time no material fills; an elision (empty target range) is source material the flow drops. Inverting a FlowMap swaps the two ranges, so an insertion inverts to an elision and back.

Attributes

Name Type Description
source_start Fraction Start coordinate in source timeline (inclusive).
source_end Fraction End coordinate in source timeline (exclusive).
target_start Fraction Start coordinate in target timeline.
label str | None Identity of the section — the source region/section name it was built from, or None when the section names nothing (e.g. built from a bare coordinate pair). Unfolding uses this to name the child timeline and Region it produces for the section.
target_end Fraction | None End coordinate in target timeline. Defaults to None, which derives it from target_start plus the source extent — the concatenating behaviour of an ordinary played section.