Don't rely on functions that are deprecated

Change-Id: I4150368e44b43e45f3604bf0fc7dab38a15e5ec9
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
This commit is contained in:
Lars Knoll 2019-05-02 09:23:52 +02:00
parent 5ced1ff9fc
commit 0b373c2e36

View File

@ -198,8 +198,8 @@ void tst_QFontDatabase::widthTwoTimes()
f.setPixelSize(pixelSize);
QFontMetrics fm(f);
int w1 = fm.charWidth(text, 0);
int w2 = fm.charWidth(text, 0);
int w1 = fm.horizontalAdvance(text, 0);
int w2 = fm.horizontalAdvance(text, 0);
QCOMPARE(w1, w2);
}