From 3fc8179c7ac33616008513e4182f86cd77743151 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 6 Jul 2018 13:12:05 +0200 Subject: various loplugin in qt5 loplugin:includeform loplugin:staticaccess loplugin:loopvartoosmall loplugin:redundantcast Change-Id: Ibd4848f0c6076d5ae95fff2853e1f6e0ba1c083b --- vcl/inc/qt5/Qt5Font.hxx | 2 +- vcl/qt5/Qt5Bitmap.cxx | 2 +- vcl/qt5/Qt5Graphics.cxx | 2 +- vcl/qt5/Qt5Graphics_GDI.cxx | 2 +- vcl/qt5/Qt5Graphics_Text.cxx | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/vcl/inc/qt5/Qt5Font.hxx b/vcl/inc/qt5/Qt5Font.hxx index 81bd723c1ab6..034cda35c2d4 100644 --- a/vcl/inc/qt5/Qt5Font.hxx +++ b/vcl/inc/qt5/Qt5Font.hxx @@ -23,7 +23,7 @@ #include -#include +#include "Qt5FontFace.hxx" class Qt5Font final : public QFont, public LogicalFontInstance { diff --git a/vcl/qt5/Qt5Bitmap.cxx b/vcl/qt5/Qt5Bitmap.cxx index adc46651fe41..6e22ad187b39 100644 --- a/vcl/qt5/Qt5Bitmap.cxx +++ b/vcl/qt5/Qt5Bitmap.cxx @@ -146,7 +146,7 @@ bool Qt5Bitmap::Create(const SalBitmap& rSalBmp, sal_uInt16 nNewBitCount) sal_uInt32 nWidth = pBitmap->m_aSize.Height() / 2; bool isOdd(0 != pBitmap->m_aSize.Height() % 2); - for (sal_uInt32 h = 0; h < pBitmap->m_aSize.Height(); ++h) + for (long h = 0; h < pBitmap->m_aSize.Height(); ++h) { sal_uInt8* buffer_data = buffer_data_pos; buffer_data_pos += pBitmap->m_nScanline; diff --git a/vcl/qt5/Qt5Graphics.cxx b/vcl/qt5/Qt5Graphics.cxx index 7257b8059926..c356ed9f1936 100644 --- a/vcl/qt5/Qt5Graphics.cxx +++ b/vcl/qt5/Qt5Graphics.cxx @@ -19,7 +19,7 @@ #include -#include "Qt5Font.hxx" +#include #include #include diff --git a/vcl/qt5/Qt5Graphics_GDI.cxx b/vcl/qt5/Qt5Graphics_GDI.cxx index c45b678d88a5..8070b7e2d6c0 100644 --- a/vcl/qt5/Qt5Graphics_GDI.cxx +++ b/vcl/qt5/Qt5Graphics_GDI.cxx @@ -407,7 +407,7 @@ void Qt5Graphics::copyBits(const SalTwoRect& rPosAry, SalGraphics* pSrcGraphics) SalTwoRect aPosAry = rPosAry; if (!pSrcGraphics || this == pSrcGraphics) { - pImage = static_cast(this)->m_pQImage; + pImage = m_pQImage; aImage = pImage->copy(rPosAry.mnSrcX, rPosAry.mnSrcY, rPosAry.mnSrcWidth, rPosAry.mnSrcHeight); pImage = &aImage; diff --git a/vcl/qt5/Qt5Graphics_Text.cxx b/vcl/qt5/Qt5Graphics_Text.cxx index 92e9a416d74a..37a0879b0044 100644 --- a/vcl/qt5/Qt5Graphics_Text.cxx +++ b/vcl/qt5/Qt5Graphics_Text.cxx @@ -112,7 +112,7 @@ void Qt5Graphics::GetDevFontList(PhysicalFontCollection* pPFC) continue; QString aFilename = toQString( OStringToOUString(rMgr.getFontFileSysPath(aInfo.m_nID), RTL_TEXTENCODING_UTF8)); - aFDB.addApplicationFont(aFilename); + QFontDatabase::addApplicationFont(aFilename); } SalGenericInstance::RegisterFontSubstitutors(pPFC); -- cgit