summaryrefslogtreecommitdiff
path: root/vcl/qt5
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-03-14 11:11:02 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-03-26 08:44:50 +0200
commitbea081b5099786e5fcadddd72c247b9a9488286a (patch)
treedd165f81e850cb9bcfa23b713bd60e3fb26d21ee /vcl/qt5
parenta488c7ad2763b944713997911c1ddb0315d8c93f (diff)
replace SalColor with Color
Change-Id: I615640a378a61cf6e44e84a647ce06bdd8a52807 Reviewed-on: https://gerrit.libreoffice.org/51239 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/qt5')
-rw-r--r--vcl/qt5/Qt5Graphics.cxx6
-rw-r--r--vcl/qt5/Qt5Graphics.hxx18
-rw-r--r--vcl/qt5/Qt5Graphics_GDI.cxx12
-rw-r--r--vcl/qt5/Qt5Graphics_Text.cxx2
4 files changed, 19 insertions, 19 deletions
diff --git a/vcl/qt5/Qt5Graphics.cxx b/vcl/qt5/Qt5Graphics.cxx
index 23249c5799c6..6ec6c341913a 100644
--- a/vcl/qt5/Qt5Graphics.cxx
+++ b/vcl/qt5/Qt5Graphics.cxx
@@ -33,13 +33,13 @@
Qt5Graphics::Qt5Graphics( Qt5Frame *pFrame, QImage *pQImage )
: m_pFrame( pFrame )
, m_pQImage( pQImage )
- , m_aLineColor( MAKE_SALCOLOR(0x00, 0x00, 0x00) )
- , m_aFillColor( MAKE_SALCOLOR(0xFF, 0xFF, 0XFF) )
+ , m_aLineColor( 0x00, 0x00, 0x00 )
+ , m_aFillColor( 0xFF, 0xFF, 0XFF )
, m_eCompositionMode( QPainter::CompositionMode_SourceOver )
, m_pFontCollection( nullptr )
, m_pFontData{ nullptr, }
, m_pTextStyle{ nullptr, }
- , m_aTextColor( MAKE_SALCOLOR(0x00, 0x00, 0x00) )
+ , m_aTextColor( 0x00, 0x00, 0x00 )
{
ResetClipRegion();
}
diff --git a/vcl/qt5/Qt5Graphics.hxx b/vcl/qt5/Qt5Graphics.hxx
index a9a71c64b5e2..0ece5ec5f036 100644
--- a/vcl/qt5/Qt5Graphics.hxx
+++ b/vcl/qt5/Qt5Graphics.hxx
@@ -43,14 +43,14 @@ class Qt5Graphics : public SalGraphics
QImage* m_pQImage;
QRegion m_aClipRegion;
QPainterPath m_aClipPath;
- SalColor m_aLineColor;
- SalColor m_aFillColor;
+ Color m_aLineColor;
+ Color m_aFillColor;
QPainter::CompositionMode m_eCompositionMode;
PhysicalFontCollection* m_pFontCollection;
const Qt5FontFace* m_pFontData[MAX_FALLBACK];
std::unique_ptr<Qt5Font> m_pTextStyle[MAX_FALLBACK];
- SalColor m_aTextColor;
+ Color m_aTextColor;
Qt5Graphics(Qt5Frame* pFrame, QImage* pQImage);
@@ -91,7 +91,7 @@ public:
virtual void ResetClipRegion() override;
virtual void drawPixel(long nX, long nY) override;
- virtual void drawPixel(long nX, long nY, SalColor nSalColor) override;
+ virtual void drawPixel(long nX, long nY, Color nColor) override;
virtual void drawLine(long nX1, long nY1, long nX2, long nY2) override;
virtual void drawRect(long nX, long nY, long nWidth, long nHeight) override;
virtual void drawPolyLine(sal_uInt32 nPoints, const SalPoint* pPtAry) override;
@@ -119,10 +119,10 @@ public:
virtual void drawBitmap(const SalTwoRect& rPosAry, const SalBitmap& rSalBitmap,
const SalBitmap& rTransparentBitmap) override;
virtual void drawMask(const SalTwoRect& rPosAry, const SalBitmap& rSalBitmap,
- SalColor nMaskColor) override;
+ Color nMaskColor) override;
virtual SalBitmap* getBitmap(long nX, long nY, long nWidth, long nHeight) override;
- virtual SalColor getPixel(long nX, long nY) override;
+ virtual Color getPixel(long nX, long nY) override;
virtual void invert(long nX, long nY, long nWidth, long nHeight, SalInvert nFlags) override;
virtual void invert(sal_uInt32 nPoints, const SalPoint* pPtAry, SalInvert nFlags) override;
@@ -151,16 +151,16 @@ public:
virtual long GetGraphicsWidth() const override;
virtual void SetLineColor() override;
- virtual void SetLineColor(SalColor nSalColor) override;
+ virtual void SetLineColor(Color nColor) override;
virtual void SetFillColor() override;
- virtual void SetFillColor(SalColor nSalColor) override;
+ virtual void SetFillColor(Color nColor) override;
virtual void SetXORMode(bool bSet) override;
virtual void SetROPLineColor(SalROPColor nROPColor) override;
virtual void SetROPFillColor(SalROPColor nROPColor) override;
// Text rendering + font support
- virtual void SetTextColor(SalColor nSalColor) override;
+ virtual void SetTextColor(Color nColor) override;
virtual void SetFont(const FontSelectPattern*, int nFallbackLevel) override;
virtual void GetFontMetric(ImplFontMetricDataRef&, int nFallbackLevel) override;
virtual const FontCharMapRef GetFontCharMap() const override;
diff --git a/vcl/qt5/Qt5Graphics_GDI.cxx b/vcl/qt5/Qt5Graphics_GDI.cxx
index fe1b98112b33..7bed0a43aed6 100644
--- a/vcl/qt5/Qt5Graphics_GDI.cxx
+++ b/vcl/qt5/Qt5Graphics_GDI.cxx
@@ -169,10 +169,10 @@ void Qt5Graphics::drawPixel(long nX, long nY)
aPainter.update(nX, nY, 1, 1);
}
-void Qt5Graphics::drawPixel(long nX, long nY, SalColor nSalColor)
+void Qt5Graphics::drawPixel(long nX, long nY, Color nColor)
{
Qt5Painter aPainter(*this);
- aPainter.setPen(QColor(QRgb(nSalColor)));
+ aPainter.setPen(QColor(QRgb(nColor)));
aPainter.setPen(Qt::SolidLine);
aPainter.drawPoint(nX, nY);
aPainter.update(nX, nY, 1, 1);
@@ -425,7 +425,7 @@ void Qt5Graphics::drawBitmap(const SalTwoRect& rPosAry, const SalBitmap& /*rSalB
}
void Qt5Graphics::drawMask(const SalTwoRect& rPosAry, const SalBitmap& /*rSalBitmap*/,
- SalColor /*nMaskColor*/)
+ Color /*nMaskColor*/)
{
if (rPosAry.mnSrcWidth <= 0 || rPosAry.mnSrcHeight <= 0 || rPosAry.mnDestWidth <= 0
|| rPosAry.mnDestHeight <= 0)
@@ -440,7 +440,7 @@ SalBitmap* Qt5Graphics::getBitmap(long nX, long nY, long nWidth, long nHeight)
return new Qt5Bitmap(m_pQImage->copy(nX, nY, nWidth, nHeight));
}
-SalColor Qt5Graphics::getPixel(long nX, long nY) { return m_pQImage->pixel(nX, nY); }
+Color Qt5Graphics::getPixel(long nX, long nY) { return m_pQImage->pixel(nX, nY); }
void Qt5Graphics::invert(long /*nX*/, long /*nY*/, long /*nWidth*/, long /*nHeight*/,
SalInvert /*nFlags*/)
@@ -586,11 +586,11 @@ long Qt5Graphics::GetGraphicsWidth() const { return m_pQImage->width(); }
void Qt5Graphics::SetLineColor() { m_aLineColor = SALCOLOR_NONE; }
-void Qt5Graphics::SetLineColor(SalColor nSalColor) { m_aLineColor = nSalColor; }
+void Qt5Graphics::SetLineColor(Color nColor) { m_aLineColor = nColor; }
void Qt5Graphics::SetFillColor() { m_aFillColor = SALCOLOR_NONE; }
-void Qt5Graphics::SetFillColor(SalColor nSalColor) { m_aFillColor = nSalColor; }
+void Qt5Graphics::SetFillColor(Color nColor) { m_aFillColor = nColor; }
void Qt5Graphics::SetXORMode(bool bSet)
{
diff --git a/vcl/qt5/Qt5Graphics_Text.cxx b/vcl/qt5/Qt5Graphics_Text.cxx
index 8d25e97df786..2dbeaecfdf2c 100644
--- a/vcl/qt5/Qt5Graphics_Text.cxx
+++ b/vcl/qt5/Qt5Graphics_Text.cxx
@@ -30,7 +30,7 @@
#include <QtGui/QRawFont>
#include <QtCore/QStringList>
-void Qt5Graphics::SetTextColor(SalColor nSalColor) { m_aTextColor = nSalColor; }
+void Qt5Graphics::SetTextColor(Color nColor) { m_aTextColor = nColor; }
void Qt5Graphics::SetFont(const FontSelectPattern* pReqFont, int nFallbackLevel)
{