wpt format vs XML

    • Offizieller Beitrag

    Hello,

    The reasons are:
    a) The WPTools component and RTF supports fields and links (..)w which span paragraphs. This is the reason we did not use XML directly.

    b) WPT format has been designed to be concatenable. This means you can append to a document and it still stays valid. This is why it does not have a header like RTF and does not use nesting like XML.

    WPT has been designed to "look" like HTML. The reason was to make it possible to scan it using code which is expecting HTML (mainly full text search). All other properties were meant to be ignored by the scan.

    It is, on the other hand a very simple format. The most complicated part is the WPCSS which is written by the textstyles directly. Other than that it reproduces the structure of the document as it was in memory. This makes it a good option to debug text, for example to find faults like table objects without rows.

    WPT format supports property inheritance. This makes it more versatile than RTF which requires complicated tasks for aceptable style handling. In contrast to XML it can do numbered list without needing to add nested tags (ol, ul).

    WPTools 6 comes with a unit WPXMLIO1.pas. This unit implements a rudimentary XML format. The unit was specially designed to make it eays to adapt the format to the needs of the specific product.

    Regards,
    Julian

  • Thank you for your answer

    the reason for my question was:

    Some printshops use the output of our programm (produced with wptools) to
    import the text into quark or programs like that.

    Up to this winter for a couple of years we used V3/4 and some home made merging.

    The printshops (stupid) had made little programs to extract what they needed. Certainly we never stated that the RFT would stay constant (as you might now, it is not easy to parse securely:))

    We changed to standard merging with V6 (which had some detail problems...), but now we don't have to bother about RTF details any more.

    But the printshops have a problem, certainly the produced RTF looks different. Because they where looking for a format to parse more securely, i looked and ask about wpt.

    I will have a look at the xml-format

    Thank you, Chuck