Disable PDF form editing on Android

You can disable the modification of a specific form field by using setFlags with the READONLY flag, like so:

// Make the annotation read-only.
annotation.setFlags(EnumSet.of(AnnotationFlags.READONLY))

For more information, see the annotation flags guide.

Disabling all form interactions

You can disable all form interactions and modifications using [formEditingEnabled(false)][]:

val builder = PdfActivityConfiguration.Builder(context)
builder.formEditingEnabled(false)