Data structures and dynamic programming background for editing highly structured texts

The interactive editing and formatting of texts structured by a hierarchy of non-standard layout features requires a thorough study of the data structures and algorithms used. It is well known that many text processing systems in this field suffer either from bad performance or reduced quality of outputs and screen representation. The aim of this note is to demonstrate how to overcome these difficulties using dynamic programming algorithms and suitably designed data structures controlling the layout of structured texts.