How to disable annotation rotation?

Q: How to disable annotation rotation?

If you wish to disable annotation rotation UI, call disableAnnotationRotation() in PdfActivityConfiguration.Builder or PdfConfiguration.Builder:

Copy
1
2
3
4
5
6
7
8
9
10
val configuration = PdfActivityConfiguration.Builder(context)
    .disableAnnotationRotation()
    .build()

// You can set the configuration when building PdfActivity Intent.
val intent = PdfActivityIntentBuilder.fromUri(context, documentUri)
    .configuration(configuration)
    .build()

context.startActivity(intent)