Quantcast
Channel: DevExpress Support Center (Examples)
Viewing all articles
Browse latest Browse all 7205

How to use Document Iterator to obtain a list of fonts that are used in a document

$
0
0

This example creates a DocumentIterator instance for the current document and calls its MoveNext method to iterate through document elements. The Visitor pattern is implemented to process a document element. 

MyVisitor is a custom class, which implements the IDocumentVisitor interface. This class provides a method that processes DocumentText elements, obtains a name of the font applied to the text element, and writes the font name in a list. 

See also: How to use the Document Iterator object to iterate over document elements.


Viewing all articles
Browse latest Browse all 7205

Trending Articles