PdfTextExtractionOptions.PreferFontEncodings Property

Docotic.Pdf Library Help > BitMiracle.Docotic.Pdf Namespace > PdfTextExtractionOptions Class > PdfTextExtractionOptions Properties > PreferFontEncodings Property
Docotic.Pdf documentation
Gets or sets a value indicating whether to prefer encoding specified in font bytes over encoding specified in PDF structures while extracting text.

Namespace: BitMiracle.Docotic.Pdf
Assembly: BitMiracle.Docotic.Pdf (in BitMiracle.Docotic.Pdf.dll)

Syntax

C#
[ObsoleteAttribute("This value will be removed in the next release of Docotic.Pdf. Docotic.Pdf now automatically detects whether to prefer font encoding.")]
public bool PreferFontEncodings { get; set; }
Visual Basic
<ObsoleteAttribute("This value will be removed in the next release of Docotic.Pdf. Docotic.Pdf now automatically detects whether to prefer font encoding.")> 
Public Property PreferFontEncodings As Boolean
	Get
	Set

Property Value

Type: Boolean
true if library should prefer encodings specified in font bytes over encodings specified in PDF structures; false otherwise.

Remarks

Every font in a PDF document has associated encoding which is defined in corresponding PDF structure.

Some PDF generators might create PDF documents with incorrect PDF encodings. For such documents text is usually displayed properly, but can not be properly extracted even by Adobe tools. However, embedded font bytes might specify proper encoding in such documents.

Setting this property to true might help to extract text properly even if document is created with incorrect PDF structures.

Default value: false.

See Also