> For the complete documentation index, see [llms.txt](https://docs.apryse.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.apryse.com/xamarin/guides/viewer-components/reflow.md).

# Reflow document content in Xamarin

Learn how to implement reflowable layout for PDF documents in Xamarin.iOS. Create a user-friendly experience with swipe navigation through pages. Customize text scale and more advanced features. The A

{% hint style="info" %}
**This tutorial only applies to Xamarin.iOS. See Xamarin.Android equivalent here .**
{% endhint %}

Reflow makes the document more flexible and easier to read, especially on small devices. Apryse is able to extract the reflowable layout of each page of a PDF document as an HTML file. In this guide, 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.

The [`PTReflowViewController`](https://sdk.apryse.com/api/xamarinios/tools/api/pdftron.PDF.Controls.PTReflowViewController.html) class allows the user to flip left and right through the reflowable layout of pages in a certain PDF document.

![](https://653871032-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FgjsBtuYmcKhWOdM9VCg4%2Fuploads%2Fgit-blob-f106f933af484a4c140bcdf32491ae9b76921a50%2F858672a1b898f759f5072510e7d0fad1e9e3faf6-600x1068.gif?alt=media)

*The reflow control is part of the Tools library, so make sure you have* [*added the Tools library to your project*](/xamarin/ui-customization/setup.md)*.*

## Show a reflow view controller

To create a new reflow view controller instance and display it from another view controller, supply a `PTPDFViewCtrl` instance to the `PTReflowViewController` designated initializer:

{% tabs %}
{% tab title="C#" %}
{% code lineNumbers="true" %}

```csharp
var reflowViewController = new PTReflowViewController(mPdfViewCtrl);
var navigationController = new UINavigationController(reflowViewController);
this.PresentViewController(navigationController, true, null);
```

{% endcode %}
{% endtab %}
{% endtabs %}

That is everything you need to have a simple reflow control. Next, we will go through advanced features.

## Customization

It is possible to change the scale of text in the reflow view controller. The default text scale is 1.0 and can be changed with the [`scale`](https://sdk.apryse.com/api/xamarinios/tools/api/pdftron.PDF.Controls.PTReflowViewController.html#pdftron_PDF_Controls_PTReflowViewController_Scale) property.

Similar to the [PDFViewCtrl ](/xamarin/guides/ios/basics/open.md#view), tapping on the left or right edge of the reflow view controller can change the page. This behavior is disabled by default and can be enabled with the [`turnPageOnTap`](https://sdk.apryse.com/api/xamarinios/tools/api/pdftron.PDF.Controls.PTReflowViewController.html#pdftron_PDF_Controls_PTReflowViewController_TurnPageOnTap) property.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.apryse.com/xamarin/guides/viewer-components/reflow.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
