Mercurial > hg > svgui
diff widgets/WindowShapePreview.cpp @ 1478:d39db4673676 by-id
Fix a number of Qt deprecation warnings
author | Chris Cannam |
---|---|
date | Wed, 03 Jul 2019 08:55:02 +0100 |
parents | 6796afa25c88 |
children |
line wrap: on
line diff
--- a/widgets/WindowShapePreview.cpp Tue Jul 02 19:05:45 2019 +0100 +++ b/widgets/WindowShapePreview.cpp Wed Jul 03 08:55:02 2019 +0100 @@ -113,6 +113,11 @@ path.addRect(0, 0, w, h + 1); timePainter.drawPath(path); + // Qt 5.13 deprecates QFontMetrics::width(), but its suggested + // replacement (horizontalAdvance) was only added in Qt 5.11 + // which is too new for us +#pragma GCC diagnostic ignored "-Wdeprecated-declarations" + QFont font; font.setPixelSize(int(10 * scaleRatio)); font.setItalic(true);