flattenAll method

int flattenAll()

Flattens every annotation that has an appearance.

The ones that do not stay on the page, each with a warning in warnings. Returns how many were flattened.

Implementation

int flattenAll() {
  var count = 0;
  for (final view in List<PdfAnnotationView>.of(annotations)) {
    if (flatten(view)) count++;
  }
  return count;
}