Posts by support

    WPTools 8 supports a subest of RichEdit messages to make it possible to use dictation programs with the TWPRichText editor.


    Unfortunately the Delphi XE designer seems to cause a problem when on a form also a regular TRichEdit component is used.


    The latest WPTools, posted on 28.7.2017 solves this issue.

    Please read about the new features here:



    *** WPTools 8.0.3 - 17.7.2017 ***
    * updated installer to set directory properties
    + To modify the ordering in DoublePageView use the flag wpDualPageViewStartsLeft in ViewOptionsEx.
    + function ColumnByName and FindColumn in TableProducer.
    - fix in WPToolsRTFToANSI to handle ; signs
    + Events in TWPColTemplate include parameter state : TWPAdapterCellStates to make it easier
    to distinguish between header, footer and data cells. (Please rebuild the designtime package)
    * improvements to TableProducer and table sorting


    *** WPTools 8.0.2 - 12.7.2017 ***
    + it is now possible to hide TableProducer columns in header and footer
    wpcoIgnoreInFooter, wpcoIgnoreInHeader in TWPColTemplate.Options
    - fix problem in paragraph style property editor
    * improved sorting in tables
    + wpcoTrimFieldText in TWPColTemplate.Options


    *** WPTools 8.0.1 - 11.7.2017 ***
    + TWPTableProducerDB now also supports TGraphicFields
    + TWPTableProducer supports UI option to sort also strings instaed of numbers
    - fix in par.Compare
    - fix in table formatting code
    - fixes in setup script
    + selection in tables recognizes rowspan


    *** WPTools 8.0 - 7.7.2017 ***


    + TWPRichText.TableFilterSort - powerful method to sort and filter the rows in a table.
    + TWPTableProducer and TWPTableProducerDB - unique and innovative to view data in table structure
    with, in contrast to database grids, instant preview, print and export to RTF/DocX
    It is also possible to modify the report in the viewer (=TWPRichTExt)
    The tool has little overhead since it uses the standard WPTools technology
    Instant preview of the table in the IDE designer
    Supports rowspan cells.
    Possibility to create the structures in code - something which can be problematic with live binding.


    + TOUCH SUPPORT: Zoom and Panning (to disable set Touch.InteractiveGestures)
    + Dynamic objects are used by the paint routine to draw special objects
    * WPStyleScroller has been improved to work with styles which are using large fonts
    * several tweeks in WPStyleScroller
    + Dynymic Grids. Created with TableAdd and Option wptblCreateDynamicGrid
    * Support for KeepN defined in table rows. Can be disabled by wpfDontIgnoreKeepNInTable in FormatOptionsEx
    + TWPParagraphList.SortEx now maintains the current order for items with equal content
    + TWPListOfParagraphList makes it possible to sort rows in tables and maintain header/footer and groups.


    + property "TWPStyleCollection.Usage" makes it easy to use the style collection to
    define a basis set of styles to be used by new documents.
    + TParagraph.QuickFind('{~*~}' ... can be used to locate tokens in the text.


    + wpfIgnoreSoftParagraphbreaks in FormatOptionsEx2
    + TableAdd can create up to 3 table header and up to 3 footer rows.
    + WPDataSetTools.pas
    - New Style in drop down did not work properly in a split screen editor
    + TableAdd now optionally accepts styles for header/footer
    + improved table column resizing code
    + WPCELL_FILLERCELL
    + SplitRow
    + Rows now support ColsByName[]
    + TParagraph.CharAttrModify Modify the CharAttr of the complete text or parts of it. You can pass
    a attribute which will be modified. This makes it easy to set a color
    to the text without using the CharAttr interface
    - TWPValueEdit was not loading "value" from DFM
    + TWPMMDataProvider can now load images specified by filename in field. (property LinkedImageFields and others)
    * much improved speed of ClearSelection after a SelectAll (Ctrl+A)


    + new function LoadSelectionFromFile
    + RTF tag \column supported (WPTools Premium)
    * SelectAll/Delete keeps current writing attribute and style
    * improvement for DOCX import of embedded graphics
    + DOCX import now fixes width defined in wrong percent values
    * improved FileSave dialog to add file extension automatically
    * HTML writer now also defaults to write SPAN tags if no format string was used.
    * DocX writer now limits the page width / page height to a 32K value (22 inch) to avoid Word crashing.
    - Contents.InputTextFiledName was not using the attribute of the field
    - Image positions used for mouse click detection sometimes were wrong directly after reformatall
    - SaveSelection saved \page to a file when the page break was on the first saved paragraph
    * paprStartingComment moved to TParagraph.State: wpstStartingComment
    * TParagraph.Compare now ignores trailing whitespace. It optionally compares case insensitve or on base of the first number in the text.
    - apply width and height for loaded images.
    * function TWPTextObj.LoadObjFromStream preserves current width and height defined in TWPTextObj.


    + wpPrintAsBitmap for text objects (useful to hide text elements in PDF output)
    + HandleRichEditMsg to eanble/disable dictation software access
    * don't print character background color in the page margin or between columns
    * better saving of trrh in RTF. (Absolute height takes precedence)
    * GetCharAttr now reads the attributes at the start of a selection if text was selected.
    + The "finder" ignores hyperlink and bookmark objects unless the property DontIgnoreObjects = true. Inserted text will be placed within the objects.

    What new:


    + TWPRichText.TableFilterSort - powerful method to sort and filter the rows in a table.
    + TWPTableProducer and TWPTableProducerDB - unique and innovative to view data in table structure
    with, in contrast to database grids, instant preview, print and export to RTF/DocX
    It is also possible to modify the report in the viewer (=TWPRichTExt)
    The tool has little overhead since it uses the standard WPTools technology
    Instant preview of the table in the IDE designer
    Supports rowspan cells.
    Possibility to create the structures in code - something which can be problematic with live binding.


    + TOUCH SUPPORT: Zoom and Panning (to disable set Touch.InteractiveGestures)
    + Dynamic objects are used by the paint routine to draw special objects
    * WPStyleScroller has been improved to work with styles which are using large fonts
    * several tweeks in WPStyleScroller
    + Dynymic Grids. Created with TableAdd and Option wptblCreateDynamicGrid
    * Support for KeepN defined in table rows. Can be disabled by wpfDontIgnoreKeepNInTable in FormatOptionsEx
    + TWPParagraphList.SortEx now maintains the current order for items with equal content
    + TWPListOfParagraphList makes it possible to sort rows in tables and maintain header/footer and groups.


    + property "TWPStyleCollection.Usage" makes it easy to use the style collection to
    define a basis set of styles to be used by new documents.
    + TParagraph.QuickFind('{~*~}' ... can be used to locate tokens in the text.


    + wpfIgnoreSoftParagraphbreaks in FormatOptionsEx2
    + TableAdd can create up to 3 table header and up to 3 footer rows.
    + WPDataSetTools.pas
    - New Style in drop down did not work properly in a split screen editor
    + TableAdd now optionally accepts styles for header/footer
    + improved table column resizing code
    + WPCELL_FILLERCELL
    + SplitRow
    + Rows now support ColsByName[]
    + TParagraph.CharAttrModify Modify the CharAttr of the complete text or parts of it. You can pass
    a attribute which will be modified. This makes it easy to set a color
    to the text without using the CharAttr interface
    - TWPValueEdit was not loading "value" from DFM
    + TWPMMDataProvider can now load images specified by filename in field. (property LinkedImageFields and others)
    * much improved speed of ClearSelection after a SelectAll (Ctrl+A)


    + new function LoadSelectionFromFile
    + RTF tag \column supported (WPTools Premium)
    * SelectAll/Delete keeps current writing attribute and style
    * improvement for DOCX import of embedded graphics
    + DOCX import now fixes width defined in wrong percent values
    * improved FileSave dialog to add file extension automatically
    * HTML writer now also defaults to write SPAN tags if no format string was used.
    * DocX writer now limits the page width / page height to a 32K value (22 inch) to avoid Word crashing.
    - Contents.InputTextFiledName was not using the attribute of the field
    - Image positions used for mouse click detection sometimes were wrong directly after reformatall
    - SaveSelection saved \page to a file when the page break was on the first saved paragraph
    * paprStartingComment moved to TParagraph.State: wpstStartingComment
    * TParagraph.Compare now ignores trailing whitespace. It optionally compares case insensitve or on base of the first number in the text.
    - apply width and height for loaded images.
    * function TWPTextObj.LoadObjFromStream preserves current width and height defined in TWPTextObj.


    + wpPrintAsBitmap for text objects (useful to hide text elements in PDF output)
    + HandleRichEditMsg to eanble/disable dictation software access
    * don't print character background color in the page margin or between columns
    * better saving of trrh in RTF. (Absolute height takes precedence)
    * GetCharAttr now reads the attributes at the start of a selection if text was selected.
    + The "finder" ignores hyperlink and bookmark objects unless the property DontIgnoreObjects = true. Inserted text will be placed within the objects.

    The toolbar does not have a button for this. But you can of course just drop a button and connect logic to it.


    Or you intercept the OnToolbarSelectIcon event and insert some code to handle the click.


    In any case -
    If an image TWPImageObject uses the property StreamName to be <>'' this is handled to be either a filename (linked image) or the name of an image in a database or http request.


    Since WPTools does not use internet logic you need to provide the code for this using the event:


    OnHTTPRequestImage.


    Here you create the TWPImageObject and load the data (from file or request).


    To insert such an image use a method like the InsertGraphicDialog


    function InsertGraphicDialog(filter: string = ''; InsertLink: Boolean = FALSE;
    ObjectModes: TWPTextObjModes = []; path : string = ''): TWPObject; virtual;


    You find that code in WPCtrRich.pas and it should be a good example how to do this to insert images.

    Hi,


    The source for this in in wpobj_image.pas which is always included.


    Can you check out what happens with aCompressedStream when called in your code?


    I also checked procedure TWPOCustomImage.CompressEx and cannot see an error.


    Julian

    Hi,


    I would recommend to add Wingdings and any symbol fonts to the string list Type3Fonts. This makes sure they are embedded the smallest possible way.


    This happens automatically if the flag wpAllSymbolFontsAsGlyph is activated in the Options property.


    Julian

    Hi,


    Please make sure the WPViewPDF DLL is never unloaded while the application runs.
    This could cause such a problem.


    According to the title of the thread "WPDFView under windows 98" - I would not recommend to use it undoer Windows 98.


    Julian

    Hi,


    the list in the documentation.

    wPDF Version 4.35.1 (4.5.2017)
    + added support for Delphi 10.2
    - fix for stability issue with large unicode fonts in 64bit environment
    - improved XMP writing


    wPDF Version 4.33 (10.10.2016)
    * fixes problem with unicode links
    - fixes problem with ArcTo in paths.
    * improvment for thai fonts
    - fix strikeout problem and Type3 fonts
    * use property ModesEx: wpDisableRotationAlignCorrection to fiox problem is rotated textes are moved


    wPDF Version 4.15 (16.2.2016)
    * updated Arc routine
    * outlines now work also when named destinations were used
    * improvement to attached files


    wPDF Version 4.14 (27.1.2016)
    - improvement in AttachFile method to work with unicode file paths
    - fix in string compare method used when writing names, such as named destinations.
    (Note - please do not use the sign # in named destinations)
    + new method: WPDF_ConvertImageFiles


    wPDF Version 4.12 (2.12.2015)
    - text which looked like barcode was not printed correctly
    - fix problem with dash sign
    - text which looked like barcode was not printed correctly
    - fix problem with dash sign
    * several fixes in PDF conversion (rotated text)


    wPDF Version 4.11 (7.10.2015)
    + support for Delphi 10
    * improved combobox fields
    - fix for Type3 embedding
    - list of embedded files was not always detected correctly by reader
    + added flag wpdfaLevel3B which is essential for the ZUGFeRD support
    - the font Segoe UI Symbol was not exported correctly
    * improved code to undo a SetWorldTransform in PDF code
    - rotated text was not printed at the correct position if it was converted to glyphs



    wPDF Version 4.09 (27.5.2015)
    - fixes problems with CIDFont export when certain glyphs were not found
    - fixes problem with Cambria Math font


    wPDF Version 4.08' (9.3.2015)
    - fixes a problem with polypolygon api used inside of pathes


    wPDF Version 4.08 (28.2.2015)
    - calculation of text rectangles have been updated
    - wpNoTextScaling was ignored before
    - hatches are not drawn with a background (caused black boxes)
    - update of annotation used for embedded data


    wPDF Version 4.07 (7.11.2014)
    * wpAllSymbolFontsAsGlyph mode will now create Type3 fonts for symbols, not individual glyphs.
    +Type1 fonts can now be embedded (subset is not possible)
    - improved y coordinate calculation in glyph output, i.e. when printing symbols
    - improved font ability detection
    + DevModesEx wpPrintTextWordByWord is useful when tabs are printed using the dx parameter of ExtTextOut
    (Only required when Type3 and CIDMode is not used)
    - fixed broken support for WPTools 4


    wPDF Version 4.06' (23.9.2014)
    - further improve support for images with transparency masks
    - fix problem TextOut problem. Only use background color for the text itself.


    wPDF Version 4.06 (19.9.2014)
    + added support for Delphi XE7
    - improved Type3 text printing on rotated coordinate systems
    - fixed problem with semi transparent images
    - with some drawing code a rg command within a path caused a message from the PDF reader
    * when creation annotations it is now possible to suppress that they are added to the interactive AcroForm Fields directory by adding 8192 to the AcroMode parameter


    wPDF Version 4.05 (17.7.2014)
    + property Type3Fonts is a list of fonts which should always be embedded as Type3
    + Create combobox fields using the API DrawTextField
    - fix problem when embedding Verdana Italic


    wPDF Version 4.04 (20.6.2014)
    + WPTools 7.14 or later now export PNG with transparency masks
    * improvement to Type3 font embedding


    wPDF Version 4.03 (5.6.2014)
    * improvements to PDF/A creation
    * improvement to Type3 font embedding
    + PNG support now handles PNGs which use palette
    + DrawPNG function can now draw into the context of the Canvas (for better Z-Order control)
    + DrawJPG - exprt JPEG data directly
    + DrawAnnotation can create various annotations by directly specifying PDF parameters.
    Also appearance streams can be added and Popup Annotations can be assigned
    + GDI commands to create hyperlinks


    wPDF Version 4.02 (11.5.2014)
    + added support for Delphi XE6
    - fixed problem with schema extension with non unicode compiler


    wPDF Version 4.01 (4.4.2014)
    + add new method: function AddFileAttachment(
    Name, Desc : WideString; Filename : WideString;
    const Typ : WideString = 'text/xml';
    ModDate: TDateTime = 0):Boolean;
    + add new method: AddFileAttachment(
    Name, Desc : WideString; Stream : TStream;
    const Typ : WideString = 'text/xml';
    ModDate: TDateTime = 0):Boolean; overload;
    + add new method: procedure AddXMPExtra(const SchemaPartXML, InfoPartXML : WideString) . this method can be used to add custom meta data in XMP format.


    wPDF Version 4.00 (19.3.2014)
    + add new fontmode: wpEmbedType3 - create type3 fonts which are very compact
    + add new fontmode: wpEmbedCIDFonts - select the CID Font "unicode" mode which was added to wPDF 3
    + add properties: Info.CopyrightNotice, Info.CopyrightURL and Info.CopyrightPublicDomain
    + DrawPNGFile. This methods exports a PNG file. It requires the PDF Engine to be able to decode PNG.
    + DrawPNG: This method exports PNG data. It requires the PDF Engine to be able to decode PNG.
    * many optimizations to the EMF conversion engine

    Hi,


    history.txt is installed by the setup - here is the complete list for WPTools 7 since May 2013.
    WPTools 8 will come out this year.


    21.2.2017 - WPTools 7.33.1 - DocX part
    * improvement for DOCX import of embedded graphics
    + DOCX import now fixes width defined in wrong percent values
    * DocX writer now limits the page width / page height to a 32K value (22 inch) to avoid Word crashing.


    26.10.2016 - WPTools 7.33.1
    - improvement for autodetect hyperlinks
    * ClearSelection has a new optional parameter: UpdateCursorPosition
    - Solves the problem that a long table with just a single long cell will move to the next page
    This fix can be disabled by: WPRichText.RTFData._CheckTableHeightInFormat := true
    - Solves format problem when typing tabs which ar using the default tab pos


    12.10.2016 - WPTools 7.33
    - fixes in DocX export for number and text box writing
    * some improvments to hidden paragraphs
    * improvement to wpfAlignTableFootersAtBottom
    + new property Memo.SpecialTextFlagsForAllText can be used to force
    triggering of the event OnGetAttributeColor for the complete text.
    - fix for problem when typing tabs


    13.9.2016 - WPTools 7.32
    + The DocX reader now loads DocDefault paragraph spacing and other properties
    * improved column resize code
    * WPAT_PAR_NAME and WPAT_PAR_COMMAND cannot be inherited by AGetInherited
    * Print procedure now accept an optional parameter "aPrinter" to pass an printer object.
    - fix problem that paper sizes were not updated in printer
    - paragraph padding is calculated in format routine (not par initialization)
    - fix problem in DefaultAction
    - fix SwapWithNextPar
    - improved column balacing
    - several small fixes
    * includes workaround for print problem introduces in August 2016 by Windows Update


    12.8.2016 - WPTools 7.30.2
    - WPStringToColor was broken for compiler < Delphi XE
    - the XML reader now accepts '-' to be used in parameters
    * UNICODE und ANSI reader now apply the paragraph style the text is loaded in.
    * property SelText is now expecting UNICODE strings with Delphi 2009 and later
    * ProtectedProp ppIsInvisible also protected new line characters. This has been changed.
    * XML reader/writer: EM and STRONG are used correctly now



    27.6.2016 - WPTools 7.30
    - fix problem in ParStylePaint
    * procedure WPLoremIpsum has been moved to unit WPRTEEdit
    + Using Memo._DisableClippingInDrawFunction := true the method Draw()
    can be used without internal clipping
    - fix possible memory issue in PasteFromClipboard when styles were copied
    * optimation of unit WPEval
    * optimation of unit WPXMLInt
    + event OnPrintPage allows i.e. custom scaling


    1.5.2016 - WPTools 7.28'
    + TWPTextObj now supports additional property ExtraProp[name] to save string properties with an attribute. This
    property uses the "Extras" string list which was already in before.
    + the HTML reader now reads the "rel" parameter into the hyperlinks textobject ExtraProp['rel'] property
    + the HTML writer saves the hyperlink ExtraProp['rel'] property into the HTML A "rel" attribute
    + the XML reader now reads the "rel" parameter into the hyperlinks textobject ExtraProp['rel']
    + the XML writer saves the hyperlink ExtraProp['rel'] property into the HTML A "rel" attribute
    + the HTML reader now reads the "class" parameter into the hyperlinks StyleName property
    - fix in HTML writer to write <font> tag for <a> tags
    - fix in HTML reader to get confused by un balanced font and span tags
    * procedure WPLoremIpsum has been moved to unit WPRTEEdit
    + Using Memo._DisableClippingInDrawFunction := true the method Draw()
    can be used without internal clipping
    - fix possible memory issue in PasteFromClipboard when styles were copied
    * optimation of unit WPEval
    * optimation of unit WPXMLInt
    - html entities were not read correctly by HTML reader
    + the color dropdowns it toolbar now show hints


    20.4.2016 - WPTools 7.28
    + added support for Delphi 10.1 Berlin


    9.4.2016 - WPTools 7.28
    + handling of thai composite characters
    - change in WPReporter to avoid empty line at start
    * removed redundant StoreOptions "soWriteObjectsAsRTFBinary"
    - fix for WPStringToColor
    - solved problem with tables and page breakes in report builder rendering
    - fixed problem with missing borders after page break
    (set WPRichText.RTFData._TableRowOverflow := true if you see double borders or backgrounds)



    6.3.2016 - WPTools 7.27'
    - fix problem with cell borders
    + RTF writer option 'RTF-NoWPToolsProps' prohibits the writing of all properties which are proprietary to WPTools



    4.3.2016 - WPTools 7.27
    - fix to support C++Builder 10
    * improvement to format routine to avoid orphane header rows
    - fix for wrong right alignment of textobjects in header/footer
    - fix for cell background bleeding which occured sometimes with nested cells
    - fix in DocX reader handler for strike out text
    - fix in font collection rotine to avoid AV when a long font name was found
    * change in RTF engine to truncate numbertexts which are longer than 40 characters.
    this is controlled by the global variable wpMAXNUMTEXTLEN. Set to 0 to deactivate.
    * some enhancements to structure of the units
    * WPToolsRTFToANSI now has additional parameter for maxlength



    17.11.2015 - WPTools 7.26.1
    - fix problem with tab followed by < sign in docx writer
    - fix for landscape reading in RTF code
    - DocX Reader - support positionH mode "column" for textboxes
    - DocX Reader improve frame prop reading for textboxes


    7.10.2015 - WPTools 7.26''
    + new flag in ViewOptionsEx: wppNoBlueRectsAroundFootnotesWhileEditing (switch off blue lines around footnotes)


    24.9.2015 - WPTools 7.26'
    - Delphi <2009 only: fixed problem with style names which contained accent characters when doing copy & paste



    22.9.2015 - WPTools 7.26
    + Support for Delphi 10 (DCUs are stored in directory DX10)
    - character background color was not painted
    - fix display problem of text objects in selected paragraphs
    - fix possible memory leak in TWPMMInsertTextContents.LoadImageFromFile
    - vertical alignmen was not working in cells
    - change in painter to fill background a bit wider
    - improve cursor positioning after click at end of page
    - the ruler was not drawn correctly when it was not positioned at the left most position
    - improvement of display of hyperlinks with arabic text



    3.8.2015 - WPTools 7.25.2
    * read RTF which do not use ; in the font table
    - DOCX reader: Handle right tabs correctly
    + DOCX reader: Load footnotes
    * DOCX writer: write /word main directory to increase compatibility with SoftMaker Office 2016
    * DOCX Improvemnent to numbering loading
    + DOCX DefaultTabstop load & Save
    + DOCX empty paragraph are loaded
    * fix in WPEval.pas



    24.5.2015 - WPTools 7.25.1
    * change in MoveToPreviousField
    - fix possible range check error
    - fix cell background color overflow
    - fix lost cell in nested table and page break when there was another table in second cell
    - ColorDropdown did not call ChangeApplied


    - Updated DOCX reader and writer fixes problems with & sign in hyperlinks
    - LoadFromString now calls LoadSelectionFromStream as WPTools V6 did if "WithClea = false"
    - Improvement to RTL Support



    16.4.2015 - WPTools 7.25
    + added support for Delphi XE8 and C++Builder XE8
    - in rare cases the footer of the next table was painted over the last cell of the previous
    - fixed problem with formatting when tables where not seperated by at least one paragraph
    * added flag to FormatOptionsEx2: wpfAlwaysGenerateParBetweenTables. The format routine will create
    an empty hidden paragraph between tables to make sure the user can move there
    * the DOCX writer will add '#' to hyperlinks which lead to internal bookmarks
    * the DOCX reader will remove '#' sign at the start of hyperlinks
    - some minor fixes.




    26.3.2015 - WPTools 7.24


    * optimized sizer rects for images and text boxes
    * WPRichText1.RTFData.TextBoxPadding can be used to change the minimum padding for text boxes
    + new flag wpfHideFirstTableHeaderRowAtStartin FormatOptionsEx2
    + new flag wpfHideSecondTableHeaderRowAtStart in FormatOptionsEx2
    + new flag wpfHideTableFooterRowAtEnd in FormatOptionsEx2
    + new wpfUseFloatingImagesOfHiddenParagraph in FormatOptionsEx2. Images which use
    an invisible paragraph as anchor are still visible



    1.3.2015 - WPTools 7.23.3
    + wpSwapCursorKeysInRTLMode in EditOptionsEx2
    - buttons in preview dlg were disabled



    6.2.2015 - WPTools 7.23.2
    - fix a problem in the function TParagraph.IsWordDelimiter
    * improved cell de-selection
    - curly underlines were not rendered
    - fix small problem in DOCX support which caused MS WSord 2007 not to open the file
    + added feature to DOCX support: use format string "DOCX-ActivateTrackChanges' to make MS Word
    open the file with change tracking being active.
    * Zoom with mouse wheel (activated with EditOptionEx wpZoomWithMouseWheel) automatically
    disables AutoZoom Width/FullPage



    27.1.2015 - WPTools 7.23.1
    - add a missing unit to uses clause in WPIOXML1.pas
    + if a row uses a fixed height, overflow lines will now be hidden. If course is moved
    to the hidden text, the caret is displayed after last visible position.
    This can be switched off with FormatOptionsEx2 wpfDontHideOverflowLinesInTableCells
    * the sign . and , will not be interpreted as word delimiter anymore if it is written
    between two numbers. This makes sure that 123.45 is not separated.
    - improvement in DOCX export to workaround problem in Delphi TZipFile



    21.1.2015 - WPTools 7.23
    - since the WPToolbar disables itself without a TWPRichText being attached, the buttons on WPPreviewForm
    did not work. The behaviour has been modified, the toolbar only disables itself if AutoEnablingControls is true
    + further enhancements to DOCX writer and DOCX reader
    * improved text selection code
    + much work has been put into the support for RTL writing. To activate the special rendering
    and cursor movement add wpWriteRightToLeft in property FormatOptions.
    * improvement to table cell resizing method
    * modification to GetAttributeColor handling so it is also called at print-time.



    15.1.2015 - WPTools 7.22 - WPTools' 19th birthday
    - WPSuperMerge, OnPostProcessBand, StartPar and EndPar parameter was reversed. Now it is consistent
    + WPSuperMerge Option wpAllowSectionStartInHeaderFooterBands - useful for templates converted from regular text
    + InputSection can now also create a new page - use parameter mode = [wpStartNewPage]
    + FormatOptionsEx2: wpfSectionsWithPagesizeStartNewPage for better compatibility to MS Word
    + CodeMoveTo can now also search for a certain ObjectTag, use wpCompareObjTag
    + CodeMoveTo can ignore the object type, use wpDontCompareObjType in the mode
    + Addition to WPSuperMage.AddBand to make it easier to create report groups and bands in code
    - change in RTFEngine - MailMerge did not work if an external TWPRTFDataCollection was used.
    * several enhancements to the reader/writer architecture to set the base for the optional DOCX support



    22.12.2014 - WPTools 7.21
    - fix ms word table reading problem in RTF reader
    - fix rare display problem with display of fields in header
    * old demo was expired
    - WPReporter: Subtotal footer rows were not displayed
    + lowlevel TWPTextStyle _AGetWPAT_Count and _AGetWPAT_GetValue to retrieve count and
    value of properties stored in a TWPTextStyle and TWPParagraph.


    2.12.2014 - WPTools 7.20.1
    * TParagraph.ANSIChr[index] will now return #255 for all characters > #255. Previously it was
    The lower byte of the uniciode value
    - SelectWord did not work correctly for unicode text
    - footnotes were duplicated in rare cases (Premium)



    18.11.2014 - WPTools 7.20
    * the demo project "Demos\I) MailMerge\EditFields" has been updated. Please check it out.
    + new component TWPTextObjectClasses (see new chapter in this manual)
    + create drop down listbox for edit fields
    * enhanced component TWPMMDataProvider
    + FORMCHECKBOX fields: accept as positive value in Params: true, yes, T, 1 and
    as negative '', false, no, F, 0
    + TWPAbstractCharAttrInterface.AssignTo to assign character attributes to a Canvas.TFont
    + TWPTextObj.EmbeddedTextWidthAndLength(emTextWidth, emTextLength)
    + function TWPCustomRtfEdit.GetObjXYBottomlineScreen to calculate screen point
    + API InputTextFieldName got an additional optional parameter FieldParams
    + TWPMMInsertTextContents.Options now includes mmHandleFORMCHECKBOX to handle checkbox fields automatically
    + function TWPTextObj.GetContainedObject to read an object included in a field or link.
    + wpobjWithinProtected can be used for edit fields to allow focus but not change
    + event: OnEditFieldCheckInputString to check the data which is typed into an edit field
    + event: OnEditFieldFocus now trigged for cursor up/down to react on enter/leave
    - improvement to RTF reader to load switched off character style attributes
    - For FORMCHECKBOX fields the OnTextObjectGetText event is not triggered to avoid
    that the checkbox is not painted.
    + function InputParagraph now accepts optional count parameter
    + new property AutoEnablingControls - only the emebedded controls are disabled
    when the toolbar is disconnected
    + BeforeChange event
    - fix printing of background color with justified text
    - fix in function WPToolsRTFtoANSI




    24.10.2014 - WPTools 7.17
    - fix problem with repeated header tables rows
    - images larger than a page were painted distorted on screen - this has been improved
    + new option: wpDisableAutomaticImageAntialiasing with ViewOptionsEx




    21.9.2014 - WPTools 7.16
    + function TextWidth(resolution : Integer) : Integer
    + function TextHeight(resolution : Integer) : Integer;
    + using the global var WPSpecialCharacterAttrOrder : array[TWPSpecialCharacterAttrKind] of TWPSpecialCharacterAttrKind
    it is now possible to customize the order special attributes are applied to the text, i.e. to
    also hightlight fields inside of protected text do this:
    WPSpecialCharacterAttrOrder[wpInsertpoints] := wpProtectedText;
    WPSpecialCharacterAttrOrder[wpProtectedText] := wpInsertpoints;



    15.9.2014 - WPTools 7.15
    + the HTML writer understand the format option "-WriteNumbers" to convert the oulines and lists directly into text.
    - RTF writer writes \pard before a table
    + add support for Delphi XE 7
    + you can add compiler symbol to project NOGDIPLUS to deactivate GDIPLUS
    - TWPRichText property editor did not show manage header&footer dialog
    - fix in HTML writer which to write style property of img tag
    - fix auto capitalize mode.
    - InternalHeight did not work for table rows correctly
    - Cells with black background will be imported by RTF reader with white text automatically (Compatibility to MSWord)
    - RTF reader did not read tables which did not use \intbl correctly




    20.6.2014 - WPTools 7.14


    + The ANSI Text reader will now also read UTF8 text files with BOM (requires Delphi 2009 or later)
    + The ANSI Text reader will now also read UTF8 text text files with option "-utf8' (requires Delphi 2009 or later)
    + The ANSI Text writer will now also write UTF8 text text files with option "-utf8' (requires Delphi 2009 or later)
    + with wPDF V4 and Delphi XE PNG files can be exported to PNG including a transparency mask.
    + With Delphi <XE Please activate the compiler symbol EMBEDD_PNGJPG in in wpobj_image and, in case you use wPDF 4 PLUS
    also add the unit WPPDFR_PLUS to the project




    5.6.2014 - WPTools 7.13.1
    * DecIndent now works better for numbered and outlined text
    * improved PDF/A Tag creation in combination with wPDF V4
    * Carriage Return now also triggers the AfterCompleteWordEvent
    + Memo._MeasureObjectCurrPage available in OnTextObjGetTextEx
    (see example in manual, "Use TextObjects (i.e. page numbers, sum fields, dynamic chapter headlines)")
    * C++Builder 2010 and later only: Memo.GetBlockAttr and TWPBlockAttribute has been modified to workaround a XE compiler problem.
    * TWPCustomRichText.FontSelect has been optimized. It does not use GetBlockAttr anymore.
    * The VCL will now use String instead of TFontname to get and set fonts.
    * C++Builder 2010 and later only: the overloaded method
    function TWPAbstractCharAttrInterface.GetFontName(var FontName: TFontName): Boolean;
    has been renamed to TWPAbstractCharAttrInterface.GetTFontName(var FontName: TFontName) to avoid a type clash



    21.5.2014 - WPTools 7.13
    + It is possible to select a column by moving cursor to top line of table and click (+ new mouse cursor)
    + select row by click on left side of table (+ new mouse cursor)
    + TextCursor.SelectThisRow and TextCursor.SelectThisColumn now accept optional cell parameter
    + new GetLineFromXY with added var parameters to react on click on table lines.
    + the old V4 function TWPCustomRichText.FastAddTable has new optional parameter ReplaceCurrentPar to create or work (extend)
    with a table at current position.
    + StartNewSection can optionally allow Undo Opertion. (= Default for InputSection )
    + TWPOCustomImage.CompressEx can now resample images.
    - headerfooter dialog does not disable the section button
    - InputSection has an new optional property InputSectionMode
    - updated TManageHeaderFooter
    - fixed: par.IsEmpty
    - fix problem with red section marker after Undo
    - in case BrushStart is used with flag wpBrushParProp and text is selected, the paragraph properties
    (and tabs) will be red from the start of the selection, not the active paragraph
    - TWPOCustomImage.COntentsWidth and -height now uses stored DPI values for GDI+ managed images, i.e. PNG
    * updated code for border selection
    * updated RTF reader to ignore wrong codepage setting



    5.5.2014 - WPTools 7.12
    - WPT reader had problem with TH tag
    + This utility function replaces the font of characters which are not defined in the fontfile
    selected for the character:
    function FixFontsOfText( RelacementFonts : array of String; Charset : Integer = 0 ) : Integer;
    + added support for Delphi XE6



    4.4.2014 - WPTools 7.11'
    - Ignore empty formula fields in WPTblCalc unit
    - fix problem with footnotes and margin mirror
    * HTML writer will not save span and font tags around <a> tags anymore
    + ViewOptions: wpShowParNames - this will paint the name on the left side of a paragraph
    (flag was there since wptools 4 but not used in V5 and V6)


    25.3.2014 - WPTools 7.10'
    + FormatOptionesEx2: wpfIgnorePropertyNumberStart
    * optimized JPEG export to PDF


    13.3.2014 - WPTools 7.10
    - DeleteTrailingSpace ignored the EmptyFieldsToo parameter. (was always expected to be true)
    - fixed 3 possible issues with compatibility to 64 bit
    * added some code to RTF reader to recover after inserted (garbage) RTF header codes
    - certain paragraph attributes were not read correctly from RTF after a table
    - Lines between cells were missing under certain circumstances
    - hyphenated words were sometimes printed with character overlap
    - fix problem in TWPToolbar and zoom combobox


    17.1.2014 - WPTools 7.09
    * improve compatibility with Delphi XE5
    - fix problem with fonsize combo in TWPToolbar when property ButtonHeight is 0
    - when GPP support was active BMPOs were not saved to RTF
    - if ViewOptions wpCenterPaintPages was used, the horizontal scrollbar was always visible
    - assigning a style did not reset the numberstyle of a paragraph or style



    13.12.2013 - WPTools 7.08.01'
    - wpOnlySelectInSameCell Code broke use with "CreateDynamic"


    10.12.2013 - WPTools 7.08.01
    + use format string "RTF-ParAsNewLine" to let the RTF reader convert \par to \line. This is useful when using TParagraph.LoadFromFile.
    - in seldom cases Reformat was not called after deleting a selection which caused an AV in the paint procedure
    - When WPBRD_DRAW_Finish was used, the top padding was even applied when the previous cell was also bordered.


    3.12.2013 - WPTools 7.08
    + EditOptionsEx2 wpOnlySelectInSameCell allows only selection inside same cell or whole table
    + added PrintParameter.PrintHeaderFooter settings: wprOnlyOnOddPages, wprOnlyOnEvenPages
    + TParagraph.CreateCopyList has new mode flag: wpParCopyStyles
    * improved selection code for cell selection.
    Works better when merged cells are used.
    - when deleting a column the next column was not always resized correctly.
    - Undo for DeleteColumn did not preserve style
    - in WPTools Premium Edition Report templates were displayed incorrectly



    17.11.2013 - WPTools 7.07.1
    + usually otline numbering works on a complete section. With FormatOptionsEx2 wpfRestartOutlineNumbersAfterRegularText it
    will now be restarted after text which was not numbered. (Compatibility to HTML browser)
    * HTML writer will not write margins in <li> elements due to compile symbol NOMARGINS_IN_LIST
    - HTML reader created wrong paragraph nesting with some HTML files
    - WPPremium: Footnotes were moved in X direction
    + WPPremium: added function InputTextbox to simplify Textbox creation
    - WPPreviewDlg property ZoomMode was ignored
    - RTF reader added the name "HYPERLINK" to hyperlink start objects
    - if a moveable image does not fit on the page a new paragraph will be created
    - when colored text was selected the first non selected character will be painted in paragraph color



    1.11.2013 - WPTools 7.07'
    - when exporting images to PDF they anti alias was applied. That has been changed.
    * improvement to HTML reader



    17.10.2013 - WPTools 7.07
    * The Inc/Dec Indent actions will now, if applied to outline paragraphs, only change their
    numbering level and not the indent (like MS Word)
    Add compiler symbol INDENT_FOR_NUMS to WPINC.INC to get back the old behaviour
    + new event AfterExecuteAction is triggered after a toolbar button click or action was processed.
    - WPT writer sometimes saved incorrect numbering style when only parts of an outline was used.
    - fix problem with background of repeated header cells
    - 2 fixes in CSS reader
    - fixes one lost TBitmap in WPRTEPaint
    - improvement to HTML reader
    - hyphenation marker caused sometimes a space to appear
    + added support for Delphi XE5
    - the property editor "Change Pagesize" did not show the current size but the default.
    * at 100% zoom unscaled images are no longer interpolated when painted with GDI+ to avoid blurring
    + added chapter "Database, TDBWPRichText" to PDF manual



    27.9.2013 - WPTools 7.06
    - improvement to lists loading and saving in HTML mode
    * TParagraph.IsLastPar now checks parent paragraphs as well.
    + ButtonDistance property in TWPToolbar
    + WPToolbarConfigurate now uses as initial button selection the old style "Sel_..." properties
    if no ConfigString was specified. (BTW - ConfigString =";" shows an empty toolbar)
    + WPToolbarConfigurate can now add separators after selected elements. The width of the separator
    is controlled by property WidthBetweenGroups



    20.9.2013 - WPTools 7.05
    - page area was painted incorrectly when layout mode was Normal in ruler
    - zoom menu of default actions did not work
    + ClearSelection can now delete texts which use multiple, differently structured tables




    30.8.2013 - WPTools 7.04''
    * the "heal table" produced an exception
    * autoscrolling did not always update the screen (depending on theme)
    + EditOptionsEx2: wpNoMiddleMouseBtnScroll to disable scrolling after pressing the middle mouse
    - DecSize did not work correctly when text had no attribute (used feault size)
    * (internal change) formatter now implemented as class instead of procedure



    26.8.2013 - WPTools 7.04
    * The wptools caret will blink in default system frequency. Add compiler define
    NODEFAULTBLINK to WPINC.INC if you need the old non-blink behaviour
    + wpAlwaysLockTextHeight in EditOpionEx2 to lock all text box heights
    + OnTextObjGetTextEx will now also work for fields when ShowMergefiledNames = true
    - fix in XA_FInsPageExecute in default actions
    + Clear of the completed body text (SelectAll, ClearSelection) also resets the
    paragraph style and attributes (like MSWord)
    This can now be disabled using the EditOpionEx2 flag wpClearSelectionDontRemoveParAttr
    * clearing the complete text of a textbox preserves the attributes and style of first par
    - save printed file caused underlying editor to be wrongly repainted
    * minor changes to TWPImageList to detect programmer errors
    - DecSize allowed font sizes as small as 0, this has been changed to 1
    - fix problem with moving of TextBoxes with anchors being in table cells



    27.7.2013 - WPTools 7.03
    + improvement to image compression code. Create event OnPrepareImageforSaving to use:
    if TextObject.IsImage then TextObject.ObjRef.Compress;
    + toolbar style icons are disabled when editr is switched to readonly
    + SpellAsYouGo icon is initialized to current state
    - missing DelayedReformat in method ReplaceTextMethod
    - some untis were missing from the demo
    * some improvements to editor



    17.7.2013 - WPTools 7.02'
    - WPTools Premium: Fix the problem that text boxes which were placed in header and footer were
    not displayed and the frame was drawn at wrong position



    12.7.2013 - WPTools 7.02
    - images were not saved correctly when InsertGraphicDialog was used
    + the setup now installs the PNG images for the toolbar gylphs (full version only)
    - fix problem when loading sections from RTF
    - changed the resource string to remove the under scores.
    String_meDefaultUnitINCHorCM --> wpSTmeDefaultUnitINCHorCM
    - OPEN und NEW action will now set the modified flag in case they are used with the
    data sensitive TDBWPRichText
    * when copying a row which used span styles it was notz possible to insert it agaian
    without creating a nested table.



    4.6.2013 - WPTools 7.01"
    - fix in GetXYPositionAtRTFTW to sometimes report 0 for position 1 in line of length 1
    - some methodes in TWPRTFDataCollection had been marked protected instead of public
    - change in WPIOWriteRTF to ignore colors with illegal index values
    - some small changes to improve compatibility with C++Builder
    - fix in CSS reader to improve "margin" propery



    23.5.2013 - WPTools 7.01'
    - fix some minor issues in installation script
    * ConvertTableToText now handles nested tables



    18.5.2013 - WPTools 7.01
    + ConvertTablesToText, convert all tables to text.
    - the new GDI+ based image drawing code was not supported by printers
    - fix minor drawing problem in Toolbar configuration
    + new component TWPCreatePDFDlg (can be used with wPDF V3 or later)
    + Toolbarbuttons to display color drop down: (property WPToolbar.StandardColorDropdowns=false)
    + Style and Paragraph Border dialog now used the new color selector
    - paragraph colors was not working in footnotes



    13.5.2013 - WPTools 7.00.1
    + TWPCustomRtfEdit.SaveToFile renames file before overwriting
    + EditOptionsEx2 wpSaveToFileCreatesBackupfile - create and keep ~N~ backup file
    + SaveToFile triggers the EWPNoWriterClassFound exception when no writer class was found
    - rowmerge caused cells tu use wrong width in next column
    * for consistency with Word the row padding is passed as value div 2 to the cells.



    8.5.2013 - WPTools 7.00
    + Using the global variable WPDrawRectWithBitmap_bitmap the shading can be customized.
    * AInc now uses default font size
    - replaced OnTextNotFound with OnSearchReplaceMessage which not only
    by the find method but also
    bei the ReplaceMethod.
    * TWPRTFEnginePaint -> TWPRTFEngineEdit, requires unit WPRTEEdit
    * wpDefActions ---> wpDefActions7
    + CopyToClipboardAttr
    + BrushStart
    + CPMoveToItem
    + TWPParPopupObj
    + visual Style Picker component (tiles with stylename and preview)
    + TRTFProps now component. Can be assigned to WPRTFPropsComponent
    + PageMinCount
    + PageMaxCount
    + updated WPGutter to display style used by text
    * InsertGraphic with parameter AsLink=true will trigger
    the event OnRequestHTTPImage with Reader=nil
    + Paragraph.LoadFromString has new options
    + WPRichText1.FindTextBoxPar can create sub paragraphs
    + event: RTFData.AfterChangeTextBoxPar
    + Labelprinting: Caption and frame is not painted for empty labels. wpfLabelAllowSoftPagebreak
    + images can be embedded into HTML
    + ParStyles.SetCSS( ... )
    + Themed Gutter - use clNone as background color
    + CombineCellsVertically improved
    + Added API calls to TParagraph: ASetRecursive
    + save "variable" in WPIOWPtools
    + improved theme support (ruler, editor with scrollbars, toolbar, Gutter )
    + new Ruler Design and Symbols (Shaded)
    + internal FIND Dialog
    + internal Replace Dialog -- for better theming
    + WPLoremIpsum
    + ReplaceTextMethod
    + CopyAttr
    + PasteAttr



    formatting now done in
    WPRTEReformatA - WPTools 6 formatting (old logic but adapted to use new datastructures)
    WPRTEReformatB - WPTools 6 HTML formatting (old logic but adapted to use new datastructures)


    - RTFDataCollection does not implement TextObjects anymore. It is implemented in
    WPRTEEditor


    - TWPRTFDataCollectionBase is now the basis RTFDataCollection.
    We moved edit parts to WPRTEEdit. There is also the merge code.
    TWPRTFDataBlockEd


    - new unit: WPRTEDefsConsts
    - new unit: WPRTEPlatform
    - new unit: WPRTEEdit



    *** Changes to the Engine types and logic ***


    a)


    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.



    b)


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


    ButtonHeight in Toolbar must be set. Default 22.



    RTFDataBlock.InsertPar was replaced by InsertParEx.

    A new WPTools 8 is in the making, it will include 10.2 support from the start.


    For customers who have WPTools 7 PRO or PREMIUM - it will compile with Delphi 10.2 with minimal changes.


    Copy the source in a subdirectory named DX12 and
    add this lines to WPINC.INC:


    {$IFDEF VER320} // Delphi 10.2 Tokyo
    {$WARNINGS OFF}
    {$DEFINE UNICHAR}
    {$DEFINE DELPHIXE}
    {$DEFINE DELPHIXE3}
    {$DEFINE DELPHIXE5}
    {$ENDIF}


    Then rebuild the package.

    Hello,


    the size of the PDF file usually does not say much how "big" a PDF is. I assume in your case it is a CAD drawing which can be very big paper size.


    The ImageEn plugin will create a bitmap and render at 300dpi to ist.


    The "MakeImage" call used by the plugin would also work at reduced resolution or you can provide a fixed width / height value for the bitmap. This will increase the speed. For example the thumbnails are rendered this method.

    Hello,


    I assume the image becomes loaded but the width and height is not being assigned.


    The problem is that this code enumerates the TWPOImage instances while that class is just the container for an image, not the object which is actually displaying it. (That would be TWPTextObj)


    I would use the method
    procedure ImageGetList(list: TWPTextObjList; FromAllBlock: Boolean = FALSE);


    Then you could use the TWPTextObj referenced in that list and call LoadFromFile there. The advantage is, that here also a new TWPOImage can be created by the TWPOImage.


    Regards,


    Julian

    From your mail I learned that you are using WPTools format.


    I don't understand why StringReplace could not work since the insertion of &#171 is consistent.


    In my mail I recommended to modify WPIOWPTools.pas:


    function TWPTOOLSWriter.WriteChar(aChar: Word): Boolean;
    begin
    if (aChar<>171) and (aChar<>172) then
    Result := WriteHTMLChar(WideChar(aChar))
    else Result := inherited WriteChar(aChar);
    end;


    This makes sure those special characters are not written as HTML entity.