fdo#72125: GetTextWidth() can get very expensive.

Let's just count an approximate width using a cached value when we have too
many entries.

Change-Id: I2113887c477bc774dd00df538ec1a01f102f4726