If the method of filling a QTextDocument by HTML import doesn't provide all the necessary features, it might still be possible using QTextDocument's own API.
Alternatively you could look at using a report generator library, e.g KDReports https://github.com/KDAB/KDReports
Cheers,
_
Bookmarks