... when upgrading from WPTools 5 or 6

<< Click to Display Table of Contents >>

Navigation:  Notes for Upgraders >

... when upgrading from WPTools 5 or 6

The RTF-Engine of WPTools 9, 8 and 7 is based on WPTools 6 but has been reorganized.

 

There are the new units WPRTEDefsConsts, WPRTEPlatform, WPRTEEdit which usually have to be added manually to the project. 

 

Further more it is necessary to add unit WPRTEFormatA and, if the AsWebpage view is used, also WPRTEFormatB

 

Unless this units are added, the editor cannot display text. By default the unit WPCtrMemo links in both units - this can be switched off by disabling the $DEFINE  WP_USEFORMATA and / or WP_USEFORMATB in WPINC.INC.

 

WPTools 9 can be compiled as WPTools 8 when the compiler symbol "WP9" is not defined.

 

There are only few changes to version 8 - we tried to make the upgrade as smooth as possible, so we also keep the package file name of WPTools so a simple recompilation is required.

 

 

 

This are the changes compared to WPTools 7.

 

Change of RTFEngine class architecture:

 

a) TWPRTFDataCollectionBase is now the basis RTFDataCollection.

 

b) The Type TWPVirtPageRTFDataRef was removed

 

This used to be a record. It has been replaced with TWPVirtPageRTFDataFrame class.

It is now stored in a list and not an array. This makes it possible to access and store more data.

 

TWPVirtPageRect was removed

 

This is now a class TWPVirtPagePrintRect. The instances are stored in a TList.

 

Several TWPVirtPage "RTFData" functions have been modified to work with the new object class. function ElementPage has been removed.

 

d) DisabledDialogs

 

property DisabledDialogs: TWPCustomRtfEditDialogs was removed from the PreviewDialog and replaced by

property DisabledButtons : TWPPreviewButtons

 

 

e) The method RTFDataBlock.InsertPar was replaced by InsertParEx.

 

f) PastMode wpPasteSimlified was changed to wpPasteSimplified

 

g) Finder.DontIgnoreObjects

 

This property is false by default. Unless true objects such as merge field markers will be ignored. If you use the finder to find tokens in the text and work with the "FontPosition" please set Finder.DontIgnoreObjects := true.

 

* TWPToolBar.DrawOptions now defaults to [wptPaintThemed]

 

* SelectionAsString does not modify DefaultFont anymore

 

* Clicks on TextObjects are ignored if they are inside a hyperlink and

 OneClickHyperlink = true and object selection was not activated in EditOptions

 

* InsertGraphic sets the property StreamName if InsertLink=true. (Previously this property was set to

  '' if the image could be loaded right away with the OnRequestImage event)

 

* ViewOptionsEx - wppNoBlueRectsAroundFootnotesWhileEditing now only works for footnotes as intended.

 

* when loading RTF with nested table empty paragraphs after a nested table will be ignored

 (can be switched off with $define DONT_IGNORE_PAR_AFTER_NESTED_TABLE)