> ## Documentation Index
> Fetch the complete documentation index at: https://docs.abbyy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# RTFExportParams Object (IRTFExportParams Interface)

This object provides functionality for tuning parameters of recognized text export in RTF, DOCX, or ODT format by means of ABBYY FineReader Engine export methods. A pointer to this object is passed into the export methods as an input parameter, and thus affects the results of export. All properties of a newly created object of this type are set to reasonable defaults noted below.

The RTFExportParams object is a persistent object. This means that the object's current state can be written to persistent storage. Later, the object can be re-created by reading the object's state from the persistent storage. The following methods provide persistence of the object:

Linux: [SaveToFile](/fine-reader/engine/api-reference/supplementary-objects-and-methods/savetofile-method), and [LoadFromFile](/fine-reader/engine/api-reference/supplementary-objects-and-methods/loadfromfile-method)

Windows [SaveToFile](/fine-reader/engine/api-reference/supplementary-objects-and-methods/savetofile-method), [LoadFromFile](/fine-reader/engine/api-reference/supplementary-objects-and-methods/loadfromfile-method), [SaveToMemory](/fine-reader/engine/api-reference/supplementary-objects-and-methods/savetomemory-method), and [LoadFromMemory](/fine-reader/engine/api-reference/supplementary-objects-and-methods/loadfrommemory-method).

## Properties

<table><thead><tr><th><p><strong>Name</strong></p></th><th><p><strong>Type</strong></p></th><th><p><strong>Description</strong></p></th></tr></thead><tbody><tr><td><p><strong>Application</strong></p></td><td><p><strong><a href="/fine-reader/engine/api-reference/engine-object-iengine-interface">Engine</a></strong>, <a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties#readonly_properties">read-only</a></p></td><td><p>Returns the <strong>Engine</strong> object.</p></td></tr><tr><td colspan="3"><p><em>Format settings</em></p></td></tr><tr><td><p><a name="pagesynthesismode" /><strong>PageSynthesisMode</strong></p></td><td><p><strong><a href="/fine-reader/engine/api-reference/enumerations/rtfpagesynthesismodeenum">RTFPageSynthesisModeEnum</a></strong></p></td><td><p>Specifies the mode of output file synthesis from the recognized text.</p><p>This property is PSM\_RTFEditableCopy by default.</p></td></tr><tr><td><p><a name="usedocumentstructure" /><strong>UseDocumentStructure</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">VARIANT\_BOOL</a></strong></p></td><td><p>Specifies whether the logical structure of the document should be used for restoring the order of the output text. If this property is FALSE, the order of the output text is based on the order of the layout blocks.</p><p>The value of this property is used only if the <strong>PageSynthesisMode</strong> property is set to PSM\_RTFFormatParagraphs or PSM\_RTFPlainText; otherwise, it is ignored.</p><p>This property is TRUE by default.</p></td></tr><tr><td><p><a name="keeppagebreaks" /><strong>KeepPageBreaks</strong></p></td><td><p><strong><a href="/fine-reader/engine/api-reference/enumerations/threestatepropertyvalueenum">ThreeStatePropertyValueEnum</a></strong></p></td><td><p>Specifies if the page breaks must be retained in the output document.</p><p>The default value of this property is TSPV\_Auto, which means that for <strong>PageSynthesisMode</strong> = PSM\_RTFEditableCopy the page breaks are not retained, for <strong>PageSynthesisMode</strong> = PSM\_RTFExactCopy the page breaks are always retained.</p><p>Notes:</p><ul><li>If the value of the <strong>PageSynthesisMode</strong> property is PSM\_RTFExactCopy, this property cannot be set to TSPV\_No.</li><li>Not retaining page breaks does not necessarily mean that there will be no page breaks at all in the output file, only that they are not guaranteed to coincide with those in the original.</li></ul></td></tr><tr><td><p><a name="keeplines" /><strong>KeepLines</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">VARIANT\_BOOL</a></strong></p></td><td><p>Specifies if original lines in recognized text should be retained in the output file.</p><p>This property is FALSE by default.</p></td></tr><tr><td><p><a name="removesofthyphens" /><strong>RemoveSoftHyphens</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">VARIANT\_BOOL</a></strong></p></td><td><p>Tells ABBYY FineReader Engine to remove optional hyphens in the output file.</p><p>Notes:</p><ul><li>If the <strong>KeepLines</strong> property is TRUE, optional hyphens are replaced with hyphens.</li><li>If the value of the <strong>PageSynthesisMode</strong> property is PSM\_RTFExactCopy, optional hyphens may be replaced with hyphens regardless of the values of the <strong>RemoveSoftHyphens</strong> and <strong>KeepLines</strong> properties if that is necessary to retain original formatting of the document.</li></ul><p>By default, this property is FALSE.</p></td></tr><tr><td><p><a name="writerunningtitles" /><strong>WriteRunningTitles</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">VARIANT\_BOOL</a></strong></p></td><td><p>Specifies whether the running titles should be saved to the output file.</p><p>This property is TRUE by default.</p></td></tr><tr><td><p><a name="metadatawritingparams" /><strong>MetaDataWritingParams</strong></p></td><td><p><strong><a href="/fine-reader/engine/api-reference/parameter-objects/export-parameters/documentcontentinfowritingparams">DocumentContentInfoWritingParams</a></strong>, <a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties#readonly_properties">read-only</a></p></td><td><p>Specifies if the author, subject, title, and keywords of the document should be written into the output file. These parameters of the document are defined in the <strong><a href="/fine-reader/engine/api-reference/document-related-objects/documentcontentinfo">DocumentContentInfo</a> </strong>subobject of the <strong><a href="/fine-reader/engine/api-reference/document-related-objects/frdocument">FRDocument</a></strong> object.</p></td></tr><tr><td><p><a name="filterseparators" /><strong>FilterSeparators</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">VARIANT\_BOOL</a></strong></p></td><td><p>Specifies whether to apply separator filtration. This setting takes effect only when <strong><a href="/fine-reader/engine/api-reference/parameter-objects/export-parameters/rtfexportparams#pagesynthesismode">PageSynthesisMode</a></strong> is PSM\_RTFExactCopy. When <strong>FilterSeparators</strong> is FALSE, more separators are retained in the output file.</p><p>This property is TRUE by default.</p></td></tr><tr><td><p><a name="writespace" /><strong>WriteSpaceAtCJTLineBreaks</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">VARIANT\_BOOL</a></strong></p></td><td><p>Specifies whether to spaces will be added at end of line when CJT languages are used.</p><p>This property is TRUE by default.</p></td></tr><tr><td colspan="3"><p><em>Color settings</em></p></td></tr><tr><td><p><a name="keeptextcolor" /><strong>KeepTextColor</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">VARIANT\_BOOL</a></strong></p></td><td><p>Specifies if original colors of text should be retained in the output file.</p><Note>The text color can be retained during export only if the <a href="/fine-reader/engine/api-reference/parameter-objects/preprocessing-analysis-recognition-and-synthesis-parameters/synthesisparamsforpage#detecttextcolor">ISynthesisParamsForPage::DetectTextColor</a> property was set to TSPV\_Yes or TSPV\_Auto during page synthesis.</Note><p>This property is TRUE by default.</p></td></tr><tr><td><p><a name="backgroundcolormode" /><strong>BackgroundColorMode</strong></p></td><td><p><strong><a href="/fine-reader/engine/api-reference/enumerations/backgroundcolormodeenum">BackgroundColorModeEnum</a></strong></p></td><td><p>Specifies the mode of background color saving in the output file.</p><Note>The background color can be retained during export only if the <a href="/fine-reader/engine/api-reference/parameter-objects/preprocessing-analysis-recognition-and-synthesis-parameters/synthesisparamsforpage#detectbackgroundcolor">ISynthesisParamsForPage::DetectBackgroundColor</a> property was set to TSPV\_Yes or TSPV\_Auto during page synthesis.</Note><p>This property is BCM\_Color by default, which means background color should be saved.</p></td></tr><tr><td colspan="3"><p><em>Picture embedding</em></p></td></tr><tr><td><p><a name="writepictures" /><strong>WritePictures</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">VARIANT\_BOOL</a></strong></p></td><td><p>Specifies if pictures should be written into the output file.</p><p>By default, this property is TRUE.</p></td></tr><tr><td><p><a name="pictureexportparams" /><strong>PictureExportParams</strong></p></td><td><p><strong><a href="/fine-reader/engine/api-reference/parameter-objects/export-parameters/pictureexportparams">PictureExportParams</a></strong>, <a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties#readonly_properties">read-only</a></p></td><td><p>Specifies the image format and JPEG quality which should be used for embedded pictures in the output file.</p></td></tr><tr><td colspan="3"><p><em>Page size and orientation</em></p></td></tr><tr><td><p><a name="increasepapersizetofitcontent" /><strong>IncreasePaperSizeToFitContent</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">VARIANT\_BOOL</a></strong></p></td><td><p>Specifies whether the page size should be increased automatically if the contents do not fit on the page. This property takes effect only when the <strong><a href="/fine-reader/engine/api-reference/parameter-objects/export-parameters/papersizeparams#papersizemode">IPaperSizeParams::PaperSizeMode</a></strong> property is set to PSM\_UserDefined.</p><p>By default, this property is FALSE.</p></td></tr><tr><td><p><a name="pageorientation" /><strong>PageOrientation</strong></p></td><td><p><strong><a href="/fine-reader/engine/api-reference/enumerations/pageorientationenum">PageOrientationEnum</a></strong></p></td><td><p>Specifies page orientation in the output file.</p><p>The value of this property is ignored in the following cases:</p><ul><li>if the <strong>PageSynthesisMode</strong> property is set to PSM\_RTFEditableCopy</li><li>if the <strong><a href="/fine-reader/engine/api-reference/parameter-objects/export-parameters/papersizeparams#papersizemode">IPaperSizeParams::PaperSizeMode</a></strong> property is set to PSM\_ImageSize, PSM\_SynthesisSize, PSM\_UserDefined.</li></ul><p>If this is the case, portrait orientation is used.</p><p>By default, the property is set to POM\_Auto.</p></td></tr><tr><td><p><a name="papersizeparams" /><strong>PaperSizeParams</strong></p></td><td><p><strong><a href="/fine-reader/engine/api-reference/parameter-objects/export-parameters/papersizeparams">PaperSizeParams</a></strong>, <a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties#readonly_properties">read-only</a></p></td><td><p>Specifies paper height and width.</p></td></tr><tr><td><p><a name="pagemargins" /><strong>PageMargins</strong></p></td><td><p><strong><a href="/fine-reader/engine/api-reference/parameter-objects/export-parameters/pagemargins">PageMargins</a></strong></p></td><td><p>Specifies page margins in the output file.</p><p>The property is only usable when the <strong>UseCustomPageMargins </strong>property is set to TRUE, or otherwise, the value of this property is ignored.</p></td></tr><tr><td><p><a name="usecustompagemargins" /><strong>UseCustomPageMargins</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">VARIANT\_BOOL</a></strong></p></td><td><p>Specifies whether the values of the <strong>PageMargins </strong>property must be used in the output file.</p><p>This property takes effect if the <strong>PageSynthesisMode</strong> property is set to PSM\_RTFPlainText or PSM\_RTFFormatParagraphs.</p><p>By default, this property is FALSE.</p></td></tr><tr><td colspan="3"><p><em>Error highlighting</em></p></td></tr><tr><td><p><a name="highlighterrorswithbackgroundcolor" /><strong>HighlightErrorsWithBackgroundColor</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">VARIANT\_BOOL</a></strong></p></td><td><p>Specifies if uncertainly recognized symbols are highlighted with background color in the output file. The color with which to highlight the background of uncertainly recognized symbols is stored in the property <strong>ErrorBackgroundColor</strong>.</p><p>This property is FALSE by default.</p></td></tr><tr><td><p><a name="highlighterrorswithtextcolor" /><strong>HighlightErrorsWithTextColor</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">VARIANT\_BOOL</a></strong></p></td><td><p>Specifies if uncertainly recognized symbols are highlighted with text color in the output file. The color with which to highlight the text of uncertainly recognized symbols is stored in the property <strong>ErrorTextColor</strong>.</p><p>This property is FALSE by default.</p></td></tr><tr><td><p><a name="errorbackgroundcolor" /><strong>ErrorBackgroundColor</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">int</a></strong></p></td><td><p>Stores the value of color used to highlight uncertainly recognized symbols' background in the output file.</p><p>This property is used only when the <strong>HighlightErrorsWithBackgroundColor</strong> property is TRUE.</p><p>The value of this property can be -1, which means that the color is transparent.</p><Note>The int value is calculated from the RGB triplet using the formula: ( red value ) + (256 x green value ) + (65536 x blue value ), where red value is the first triplet component, green value is the second triplet component, blue value is the third triplet component. For example, the int value of the color white equals 16777215.</Note><p>By default, this property is set to 65280, i.e., (0,255,0) in RGB format, which corresponds to green color.</p></td></tr><tr><td><p><a name="errortextcolor" /><strong>ErrorTextColor</strong></p></td><td><p><strong><a href="/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties">int</a></strong></p></td><td><p>Stores the value of color used to highlight uncertainly recognized symbols in the output file.</p><p>This property is used only when the <strong>HighlightErrorsWithTextColor</strong> property is TRUE.</p><p>The value of this property can be -1, which means that the color is transparent.</p><Note>The int value is calculated from the RGB triplet using the formula: ( red value ) + (256 x green value ) + (65536 x blue value ), where red value is the first triplet component, green value is the second triplet component, blue value is the third triplet component. For example, the int value of the color white equals 16777215.</Note><p>By default, this property is set to 65280, i.e., (0,255,0) in RGB format, which corresponds to green color.</p></td></tr></tbody></table>

## Methods

| Name                                                                                                                                               | Description                                                                                       |
| -------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- |
| [CopyFrom](/fine-reader/engine/visual-components-reference/supplementary-objects/spellwordcollection/copyfrom-method)                              | Initializes properties of the current object with values of similar properties of another object. |
| [LoadFromFile](/fine-reader/engine/api-reference/supplementary-objects-and-methods/loadfromfile-method)                                            | Restores the object contents from a file on disk.                                                 |
| [LoadFromMemory](/fine-reader/engine/api-reference/supplementary-objects-and-methods/loadfrommemory-method) <br /><br /> **Note:** *Windows only.* | Restores the object contents from the global memory.                                              |
| [SaveToFile](/fine-reader/engine/api-reference/supplementary-objects-and-methods/savetofile-method)                                                | Saves the object contents into a file on disk.                                                    |
| [SaveToMemory](/fine-reader/engine/api-reference/supplementary-objects-and-methods/savetomemory-method) <br /><br /> **Note:** *Windows only.*     | Saves the object contents into the global memory.                                                 |

## Related objects

<img src="https://mintcdn.com/abbyy/i-EfCQVmseNiPQcp/images/fine-reader/engine/rtfexportparams.gif?s=5b2346a807c62badf1f6d51474c2ff13" alt="RTFExportParams" width="161" height="161" data-path="images/fine-reader/engine/rtfexportparams.gif" />[](/fine-reader/engine/api-reference/parameter-objects/export-parameters/rtfexportparams#pagemargins)[](/fine-reader/engine/api-reference/parameter-objects/export-parameters/rtfexportparams#papersizeparams)[](/fine-reader/engine/api-reference/parameter-objects/export-parameters/rtfexportparams#metadatawritingparams)[](/fine-reader/engine/api-reference/parameter-objects/export-parameters/rtfexportparams#pictureexportparams)[](/fine-reader/engine/api-reference/parameter-objects/export-parameters/rtfexportparams)[](/fine-reader/engine/api-reference/parameter-objects/export-parameters/pagemargins)[](/fine-reader/engine/api-reference/parameter-objects/export-parameters/papersizeparams)[](/fine-reader/engine/api-reference/parameter-objects/export-parameters/documentcontentinfowritingparams)[](/fine-reader/engine/api-reference/parameter-objects/export-parameters/pictureexportparams)

[Object Diagram](/fine-reader/engine/api-reference/object-diagram)

## Output parameter

This object is the output parameter of the [CreateRTFExportParams](/fine-reader/engine/api-reference/engine-object-iengine-interface/creation-methods/createlessobjectgreater-methods) method of the [Engine](/fine-reader/engine/api-reference/engine-object-iengine-interface) object.

## Input parameter

This object is passed as the input parameter to the following methods:

* [Export](/fine-reader/engine/api-reference/document-related-objects/frdocument/export-method), [ExportPages](/fine-reader/engine/api-reference/document-related-objects/frdocument/exportpages-method), [ExportToMemory](/fine-reader/engine/api-reference/document-related-objects/frdocument/exporttomemory-method) methods of the [FRDocument](/fine-reader/engine/api-reference/document-related-objects/frdocument) object

* [Export](/fine-reader/engine/api-reference/document-related-objects/frpage/export-method) method of the [FRPage](/fine-reader/engine/api-reference/document-related-objects/frpage) object

* [RecognizeImageFile](/fine-reader/engine/api-reference/engine-object-iengine-interface/processing-methods/recognizeimagefile-method) method of the [Engine](/fine-reader/engine/api-reference/engine-object-iengine-interface) object

* [OnExportPages](/fine-reader/engine/visual-components-reference/idocumentviewerevents/onexportpages-method) method of the [IDocumentViewerEvents](/fine-reader/engine/visual-components-reference/idocumentviewerevents) interface for Windows Visual Components

* [OnSendToPages](/fine-reader/engine/visual-components-reference/idocumentviewerevents/onsendtopages-method) method of the [IDocumentViewerEvents](/fine-reader/engine/visual-components-reference/idocumentviewerevents) interface for Windows Visual Components

## Samples

The object is used in the following code samples: [CommandLineInterface](/fine-reader/engine/guided-tour/samples#commandlineinterface) (Windows and Linux)

## See also

[Tuning Export Parameters](/fine-reader/engine/guided-tour/advanced-techniques/tuning-export-parameters)

[Working with Profiles](/fine-reader/engine/guided-tour/advanced-techniques/working-with-profiles)

[Working with Properties](/fine-reader/engine/guided-tour/advanced-techniques/programming-aspects/working-with-properties)
