Cache calculated style information when applying direct formatting

When direct formatting, often extremely similar (if not identical) style hierarchies are being continually retrieved. Allowing external consumers to provide a limited-life cache vastly speeds up the lookup for this data.

(Note, the impact of PR 321 dwarfs this at 1000 pages, but the extra 3s becomes more significant as more improvements are made)

### 1000page.odt - Bold the current selection
|   | Master (ms) | PR 321 (ms) | PR 321 + 326 (ms)|
|---|------------|------|---|
|Chrome|416651|42446|38806|