indicesForCurrentPage method
Returns the indices of signatures that belong to currentPage
.
Example: If placements contain signatures across multiple pages, this method filters out only the ones on the specified page.
Implementation
List<int> indicesForCurrentPage(
List<SignaturePlacement> placements, int currentPage) {
final result = <int>[];
for (int i = 0; i < placements.length; i++) {
if (placements[i].page == currentPage) result.add(i);
}
return result;
}