Updating

This PlugPDF SDK Andorid Developer Guide is temporarily unavailable while we are updating contents.

Please check back shortly!

PlugPDF SDK Android Developer Guide

How to use the Annotation tool?

The PlugPDF SDK provides many annotations tool. You can use these things for editing your pdf. To do that, the changeGestureType method and the setAnnottationTool method should be used. Both methods exist in the ReaderView class. Set a parameter in the  changeGestureType method as BaseGestureProcessor.GestureType.EDIT and a parameter in the setAnnotationTool method as ToolType you want. The below code snippet will help you to understand the usage of them.

mReader.changeGestureType(BaseGestureProcessor.GestureType.EDIT);
mReader.setAnnotationTool(BaseAnnotTool.AnnotToolType.CIRCLE);

What is the annotsetting class?

You can use the Annotation tool to insert various annotations. The annotsetting class is used to control the properties of annotations using the annotation tool. The class use singleton design pattern. The below picture will help you to use this class. (* we will add the details to the API references.)


How to transform annotations?
The PlugPDF SDK provide a property so that you can decide whether to use the trasformation of annotations.
The PropertyManager class help you to do that. Please insert the below code to use it.

PropertyManager.setEnableConfirmErase(true);

Click this to get more information about the PropertyManager class.


How to get annotations list?
You can also get annotations list from some pages. By using the list, you can confirm informations of annotations or how many annotations exist in the pdf. Please use the below code to get the list.

mPageView.getAnnotList()

Click this to get more information about the PageView class.


How to add or remove annotations?
You can use add or remove annotations without using annotation tool. The addAnnot method, the removeAnnotFromPDF method, and the removeAnnotFromPageView method will help you to do that.
The first method use base annotation as an argument.

mPageView.addAnnot(mAnnot);

The second and the third methods use object id as an argument.

mPageView.removeAnnotFromPageView(mAnnot.getObjID());

Click this to get more information about the PageView class.


How to flatten PDF annotations?

To protect the integrity of PDF files, people often want to flatten their PDF file.
The PlugPDF SDK provides the simplest way to make flatten PDF annotations in the PlugPDF SDK.
The method is in the ReaderView class. Click this to get more information about the PageView class.

mReader.flattenAnnots();

You can also make a button and add the function in your pdf viewer.

Read More