Show / Hide Table of Contents

Class Reflow

Reflow annotations between PDF and HTML

Inheritance
System.Object
Reflow
Implements
System.IDisposable
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ToString()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: pdftron.PDF
Assembly: PDFNetiOS.dll
Syntax
public class Reflow : IDisposable

Constructors

Reflow(IntPtr)

Declaration
public Reflow(IntPtr impl_ptr)
Parameters
Type Name Description
System.IntPtr impl_ptr

Methods

Destroy()

Declaration
public void Destroy()

Dispose()

Declaration
public void Dispose()

Dispose(Boolean)

Declaration
protected virtual void Dispose(bool disposing)
Parameters
Type Name Description
System.Boolean disposing

Finalize()

Declaration
protected void Finalize()

GetAnnot(String)

Gets PDF annotation(s) as JSON.

Declaration
public string GetAnnot(string in_id)
Parameters
Type Name Description
System.String in_id

an annotation ID, or an empty string

Returns
Type Description
System.String

returns JSON string

GetHtml()

Converts PDF to HTML.

Declaration
public string GetHtml()
Returns
Type Description
System.String

returns HTML as a string

SetAnnot(String)

Updates PDF annotation.

Declaration
public string SetAnnot(string in_json)
Parameters
Type Name Description
System.String in_json

update instructions (JSON)

Returns
Type Description
System.String

returns JSON string

SetCustomStyles(String)

Declaration
public void SetCustomStyles(string styles)
Parameters
Type Name Description
System.String styles

SetDoNotReflowTextOverImages(Boolean)

Determines whether to not reflow text that appears over images. Default is false.

Declaration
public void SetDoNotReflowTextOverImages(bool do_not_reflow_text_over_images)
Parameters
Type Name Description
System.Boolean do_not_reflow_text_over_images

if true, text that appears over images will not be included in the output HTML

SetFontOverrideName(String)

Overrides the font to use for reflowed content. If this property is empty, the default PDF font will be used. Default is no override.

Declaration
public void SetFontOverrideName(string font_family)
Parameters
Type Name Description
System.String font_family

the font-family value that goes to the CSS in the output HTML

SetHideBackgroundImages(Boolean)

Determines whether to hide background images. Default is false.

Declaration
public void SetHideBackgroundImages(bool hide_background_images)
Parameters
Type Name Description
System.Boolean hide_background_images

if true, background images will not be included in the output HTML

SetHideImagesUnderInvisibleText(Boolean)

Determines whether to hide images that are covered by invisible text (typically produced by OCR). Default is true.

This options works only if SetHideImagesUnderText() is set to false. If SetHideImagesUnderText() is set to true, then images that are covered by any text, whether visible or not, will not be included in the output HTML.

If SetHideImagesUnderInvisibleText() is set to true while SetHideImagesUnderText() is set to false, then images that are covered by invisible text will not be included in the output HTML. This can be useful when processing scanned documents that are processed by OCR.

Declaration
public void SetHideImagesUnderInvisibleText(bool hide_images_under_invisible_text)
Parameters
Type Name Description
System.Boolean hide_images_under_invisible_text

if true, images that are covered by invisible text will not be included in the output HTML

SetHideImagesUnderText(Boolean)

Determines whether to hide images that are covered by text. Default is false.

Declaration
public void SetHideImagesUnderText(bool hide_images_under_text)
Parameters
Type Name Description
System.Boolean hide_images_under_text

if true, images that are covered by text will not be included in the output HTML

SetHTMLOutputTextMarkup(Boolean)

Determines whether to write text markup tags into the output HTML. Default is false.

Declaration
public void SetHTMLOutputTextMarkup(bool include)
Parameters
Type Name Description
System.Boolean include

if true text markup tags will be included in the output HTML.

SetIncludeBBoxForRecognizedZones(Boolean)

Determines whether to include bounding box information (of the original PDF) in the output HTML. Default is false.

The bounding box information will be stored using the attribute called "data-bbox" (value is written as "x1,y1,x2,y2", in PDF coordinates).

Note: This option is only available when pre-recognized zoning information is set through SetRecognizedZones().

Declaration
public void SetIncludeBBoxForRecognizedZones(bool include)
Parameters
Type Name Description
System.Boolean include

if true bounding box information will be included in the output HTML

SetIncludeImages(Boolean)

Determines whether to include images in the output HTML. Default is false.

Declaration
public void SetIncludeImages(bool include)
Parameters
Type Name Description
System.Boolean include

if true images will be included in the output HTML

SetMessageWhenNoReflowContent(String)

Sets the error message in the output HTML when the page doesn't contain reflowable text. Use it for localization purposes. Default: "This page doesn't contain reflowable text".

Declaration
public void SetMessageWhenNoReflowContent(string content)
Parameters
Type Name Description
System.String content

the localized message

SetMessageWhenReflowFailed(String)

Sets the error message in the output HTML when reflow conversion fails. Use it for localization purposes. Default: "Could not reflow this page".

Declaration
public void SetMessageWhenReflowFailed(string content)
Parameters
Type Name Description
System.String content

the localized message

Implements

System.IDisposable
In This Article
Back to top Generated by DocFX