Some test text!

keyboard_arrow_down

Get started

Download PDFTron SDK
play_arrow

Quick start - view a document

Integrate with NuGetIntegrate manuallyAdd license keyPermissions (Android)Run samplesUpdate to latest version
keyboard_arrow_down

Xamarin.Forms

keyboard_arrow_down

Fundamentals

Java binding (Android)Objective-C binding (iOS)Code sharingDocument lockingDocument saving
keyboard_arrow_down

Document Viewer

play_arrow

Xamarin.Android

OverviewShow a document in an ActivityShow a document in a FragmentViewer configurationToolManager configurationDay and Night themes
play_arrow

Xamarin.iOS

Open from online URL
keyboard_arrow_down

Document Viewer components

Overview
play_arrow

PDFViewCtrl

play_arrow

Reflow

Xamarin.AndroidXamarin.iOSQuick menuCustomize quick menu
play_arrow

Annotation toolbar

play_arrow

Annotation style editor

play_arrow

Page slider

play_arrow

List container

Xamarin.AndroidXamarin.iOS
play_arrow

Annotation list

play_arrow

Document outline

play_arrow

User bookmark list

play_arrow

Thumbnail browser

Add pages dialogCrop pages dialogRotate pages dialogView mode dialog
keyboard_arrow_down

Annotation and collaboration

OverviewToolManager setupRead only mode
play_arrow

Disable annotation creation and editing

Xamarin.AndroidXamarin.iOS
play_arrow

Default annotation properties

play_arrow

Change tool mode

play_arrow

Events

play_arrow

Override annotation handling

Show and hide existing annotationsRealtime collaboration
keyboard_arrow_down

Advanced customization

play_arrow

Add a custom view to a page

Xamarin.AndroidXamarin.iOSCreate a custom toolPage color modePage fit modePage layout modeScrolling direction
keyboard_arrow_down

Conversion

play_arrow

Convert documents to PDF

Xamarin.AndroidXamarin.iOS
play_arrow

Convert HTML to PDF

Xamarin.AndroidXamarin.iOS
keyboard_arrow_down

Parsing and extraction

keyboard_arrow_down

Digital signatures

keyboard_arrow_down

Form filling

keyboard_arrow_down

Search

play_arrow

Text search

Xamarin.AndroidXamarin.iOS
keyboard_arrow_down

Redaction

keyboard_arrow_down

Advanced topics

PrintUnderstand coordinatesGenerate page thumbnails
keyboard_arrow_down

Reference

LocalizationIcon cheat sheet
keyboard_arrow_down

PDF Processing API

Xamarin.Androidkeyboard_arrow_down

Reflow

In this document
chevron_rightShowing reflow pager
chevron_rightImplementation
chevron_rightPost-processing color
chevron_rightNotifying the reflow pager that the document has been modified
chevron_rightSetting the text size
chevron_rightSetting background color
chevron_rightSetting right-to-left direction
chevron_rightGenerating a reflow page
This tutorial only applies to Xamarin.Android.
Reflow requires the full version of PDFTron library. See PDFTron full or standard?

Reflow makes the document more flexible and easier to read, especially on small devices. PDFTron is able to extract the reflowable layout of each page in a PDF document to an HTML file. First, we explain how simple it is to show a widget that allows the user to swipe left or right through the pages of the document to see reflowable document pages. Then, we provide the methods necessary for converting a hard-layout PDF page to an HTML document page.

linkShowing reflow pager

ReflowControl is a ViewPager that allows the user to flip left and right through the reflowable layout of pages in a PDF document.

linkImplementation

To set up your layout with ReflowControl, add a <ReflowControl> element to your XML layout. For example, if each page in the swipe view should consume the entire layout, then your layout looks like this:

<pdftron.PDF.Controls.ReflowControl
    android:id="@+id/reflow"
    android:layout_width="match_parent"
    android:layout_height="match_parent" />

Then, you need to attach a PDFDoc to the reflow pager:


That is everything you need to have a simple reflow pager.

linkNotifying the reflow pager that the document has been modified

To refresh the reflow pager to show the latest changes on your document, you should let the reflow pager know that the document has been modified:

linkSetting the text size

It is possible to change the size of reflowable text. The default text size is 100; valid values are 5, 10, 25, 50, 75, 100, 125, 150, 200, 400, 800, and 1600. See the following code as an example:

Alternatively, you can zoom in/out to change the reflowable text size:

Assuming the current text size is 100%, by calling zoomReflow(reflowControl, true) and zoomReflow(reflowControl, false) the new text size will be 125% and 75% of the original size, respectively.

linkSetting background color

There are three methods to change the background color:

setDayMode(): no background

setNightMode(): night background

setCustomColorMode(int): customized background

linkSetting right-to-left direction

You can support right-to-left languages by setting the direction of reflowable text by calling RightToLeftDirection