QCommonStyle: Reduce code duplication
authorKonstantin Ritt <ritt.ks@gmail.com>
Tue, 9 Oct 2012 13:18:49 +0000 (16:18 +0300)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Sun, 14 Oct 2012 14:48:18 +0000 (16:48 +0200)
commit289a8147784f830f214859e00367486587d9a027
tree4c218e8436a210ac7fa655a0b934bbd466519134
parent6cf322910556b8a9c907d4cc2c7716521e4ba704
QCommonStyle: Reduce code duplication

by re-using viewItemTextLayout() helper function.
Also use QTextLayout(QString, QFont) c-tor which is a bit faster than
using setText() + setFont() setters.

Change-Id: I0d09ba43bad2296e932f49fcb9cfd28f42c1f95d
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
src/widgets/styles/qcommonstyle.cpp