placed method
Stamps where the shape lives; copy gives it a fresh id.
Implementation
UDocShape placed({int? pageIndex, int? blockIndex, int? startMs, int? endMs, bool clearTime = false, bool copy = false}) {
final DateTime now = DateTime.now();
return UDocShape(
id: copy ? _shapeId() : id,
kind: kind,
points: points,
pageIndex: pageIndex ?? this.pageIndex,
blockIndex: blockIndex ?? this.blockIndex,
strokeColor: strokeColor,
fillColor: fillColor,
strokeWidth: strokeWidth,
opacity: opacity,
dashed: dashed,
text: text,
fontSize: fontSize,
bold: bold,
startMs: clearTime ? null : (startMs ?? this.startMs),
endMs: clearTime ? null : (endMs ?? this.endMs),
createdAt: copy ? now : createdAt,
updatedAt: now,
);
}