Whether drafting business memos in a word processor, writing a blog entry, or generating reports, much of the world's computing involves the creation of text documents. Most of these applications require the ability to produce not just plain alphanumeric strings, but rich text as well. Rich text (as opposed to plain text) means text that includes styles and formatting features such as font faces, colors, lists, tables, and images.
In this chapter, we're going to learn how PyQt allows us to work with rich text by covering the following topics:
- Creating rich text using markup
- Manipulating rich text using QTextDocument
- Printing rich text