Text Format |
Start page Previous page Next page |
The text format function allows the setting of general properties for text elements. This allows the control of text breaks in tables or paragraphs, for example. The settings for the text format are set by using the option N2PDFSetOption. The following shows the individual options for the text format. The individual values are set via <OptionStr> and <SubOptionStr> of the N2PDFSetOption function.
N2PDFOPTION_FORMAT_DONT_BREAK_TABLES This parameter allows you to set if tables may be broken by page breaks or if tables are always displayed completely on a page (provided a page is large enough to display a table). The parameter is set by using the value <OptionStr>.
N2PDFOPTION_FORMAT_DONT_BREAK_TABLE_ROWS This parameter allows you to set if table rows may be broken by page breaks or if table rows are always displayed completely on a page (provided a page is large enough to display a table row). The parameter is set by using the value <OptionStr>.
N2PDFOPTION_FORMAT_IGNORE_KEEP This parameter allows the definition, if the "keep paragraph on one page" option is to be ignored or if this text property is to be honored for the text formatting. The parameter is set by using the value <OptionStr>.
N2PDFOPTION_FORMAT_IGNORE_KEEPN This parameter allows the definition, if the "keep paragraph with next paragraph" option is to be ignored or if this text property is to be honored for the text formatting. The parameter is set by using the value <OptionStr>.
N2PDFOPTION_FORMAT_AVOID_WIDOWS This parameter allows you to define if a paragraph is to be pushed to a new page if only a single line of the paragraph will fit to the current page. The parameter is set by using the value <OptionStr>.
N2PDFOPTION_FORMAT_AVOID_ORPHANS This parameter allows you to define if an entire paragraph is to be pushed to a new page if only a single line of the paragraph would be displayed on a new page. The parameter is set by using the value <OptionStr>.
N2PDFOPTION_FORMAT_REMOVE_TABLE_OFFSET If a rich text field is passed to the PDF that is positioned in a table in the Notes form, then this field may contain a table offset. This means, i.e. when it is positioned in the second or third column of the table, there is a larger distance to the left margin of the page. This offset may be removed by using the function N2PDFSetOption with the parameter N2PDFOPTION_FORMAT_REMOVE_TABLE_OFFSET. This function will only work if a single rich text field is being exported. During the export of an entire Notes document, this option has no effect. The parameter is set by using the value <OptionStr>.
Example: Call N2PDFSetOption ( JobID,_ N2PDFOPTION_FORMAT_REMOVE_TABLE_OFFSET, N2PDFVALUE_True, "" )
N2PDFOPTION_FORMAT_DELETE_TRAILING_SPACEThis parameter allows you to avoid unwanted page breaks or empty pages at the end of a document. If this option is activated, n2pdf checks if an unnecessary page- or line break is found on the last page of a document. If this is the case and an empty last page is created, n2pdf deletes that unwanted, empty page.
Example: Call N2PDFSetOption ( JobID,_ N2PDFOPTION_FORMAT_DELETE_TRAILING_SPACE, N2PDFVALUE_True, "" )
N2PDFOPTION_FORMAT_TABLE_WIDTH_MODEUse this option to set the manner in which n2pdf should react if tables are encountered during conversion which are larger than the currently set paper format. If tables are wider than the currently defined paper format, then n2pdf can return an error message so that the tables concerned can be adapted manually, or the width of the entire document can be adapted to the table with the greatest width in the document, or the page width on the page concerned only can be adapted to the respective tables. A further parameter is used to make n2pdf adapt all tables to the defined page width.
Example: Call N2PDFSetOption ( JobID,_ N2PDFOPTION_FORMAT_TABLE_WIDTH_MODE, N2PDFVALUE_FORMAT_TABLEWIDTH_ALLPAGES, "" ) |