summaryrefslogtreecommitdiffstats
path: root/tests/auto/qmenu/tst_qmenu.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/qmenu/tst_qmenu.cpp')
-rw-r--r--tests/auto/qmenu/tst_qmenu.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/auto/qmenu/tst_qmenu.cpp b/tests/auto/qmenu/tst_qmenu.cpp
index 174d1d7..abf8246 100644
--- a/tests/auto/qmenu/tst_qmenu.cpp
+++ b/tests/auto/qmenu/tst_qmenu.cpp
@@ -658,7 +658,7 @@ void tst_QMenu::task242454_sizeHint()
QMenu menu;
QString s = QLatin1String("foo\nfoo\nfoo\nfoo");
menu.addAction(s);
- QVERIFY(menu.sizeHint().width() > menu.fontMetrics().width(s));
+ QVERIFY(menu.sizeHint().width() > menu.fontMetrics().boundingRect(QRect(), Qt::TextSingleLine, s).width());
}