statePosition<T> method
Gets the clamped position of the sheet for a given state.
extent: The current extent of the sheet.state: The state index to evaluate.- Returns: The position of the state clamped between
minOffsetandmaxOffset.
Implementation
double statePosition<T>({
required MultiStateSheetExtent<T> extent,
required int state,
}) =>
clampDouble(
offsetFromState(state), extent.minOffset, extent.safeMaxOffset);