summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-02-26 10:32:20 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-02-26 16:11:58 +0100
commit97448039e1e63f3bd6b61ab3215ede721ca368e4 (patch)
treee2ea6d151df11160f2922e9e6c0c8b502a98c2fe /vcl
parente95618d754ee4e75632ed5f2bc29b8a021f45731 (diff)
use less RGB_COLORDATA
part of removing ColorData Change-Id: If31b5b88545529863377e9a178f45f4516bf6cbb Reviewed-on: https://gerrit.libreoffice.org/50345 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl')
-rw-r--r--vcl/qa/cppunit/pdfexport/pdfexport.cxx6
-rw-r--r--vcl/quartz/salbmp.cxx6
-rw-r--r--vcl/source/app/settings.cxx8
3 files changed, 10 insertions, 10 deletions
diff --git a/vcl/qa/cppunit/pdfexport/pdfexport.cxx b/vcl/qa/cppunit/pdfexport/pdfexport.cxx
index cb03680a4703..9ae6e19be328 100644
--- a/vcl/qa/cppunit/pdfexport/pdfexport.cxx
+++ b/vcl/qa/cppunit/pdfexport/pdfexport.cxx
@@ -260,7 +260,7 @@ void PdfExportTest::testTdf105461()
unsigned int nRed = 0, nGreen = 0, nBlue = 0, nAlpha = 0;
FPDFPath_GetFillColor(pPdfPageObject, &nRed, &nGreen, &nBlue, &nAlpha);
- if (RGB_COLORDATA(nRed, nGreen, nBlue) == COL_YELLOW)
+ if (Color(nRed, nGreen, nBlue) == COL_YELLOW)
++nYellowPathCount;
}
@@ -316,7 +316,7 @@ void PdfExportTest::testTdf107868()
unsigned int nRed = 0, nGreen = 0, nBlue = 0, nAlpha = 0;
FPDFPath_GetFillColor(pPdfPageObject, &nRed, &nGreen, &nBlue, &nAlpha);
- if (RGB_COLORDATA(nRed, nGreen, nBlue) == COL_WHITE)
+ if (Color(nRed, nGreen, nBlue) == COL_WHITE)
++nWhitePathCount;
}
@@ -713,7 +713,7 @@ void PdfExportTest::testTdf108963()
unsigned int nRed = 0, nGreen = 0, nBlue = 0, nAlpha = 0;
FPDFPath_GetFillColor(pPdfPageObject, &nRed, &nGreen, &nBlue, &nAlpha);
- if (RGB_COLORDATA(nRed, nGreen, nBlue) == COL_YELLOW)
+ if (Color(nRed, nGreen, nBlue) == COL_YELLOW)
{
++nYellowPathCount;
// The path described a yellow rectangle, but it was not rotated.
diff --git a/vcl/quartz/salbmp.cxx b/vcl/quartz/salbmp.cxx
index e7a614dbe50f..dde6470aeb08 100644
--- a/vcl/quartz/salbmp.cxx
+++ b/vcl/quartz/salbmp.cxx
@@ -381,7 +381,7 @@ public:
}
virtual Color ReadPixel() override
{
- const Color c = RGB_COLORDATA( pData[1], pData[2], pData[3] );
+ const Color c = Color( pData[1], pData[2], pData[3] );
pData += 4;
return c;
}
@@ -406,7 +406,7 @@ public:
}
virtual Color ReadPixel() override
{
- const Color c = RGB_COLORDATA( pData[2], pData[1], pData[0] );
+ const Color c = Color( pData[2], pData[1], pData[0] );
pData += 3;
return c;
}
@@ -434,7 +434,7 @@ public:
}
virtual Color ReadPixel() override
{
- const Color c = RGB_COLORDATA( (*pData & 0xf800) >> 8, (*pData & 0x07e0) >> 3 , (*pData & 0x001f) << 3 );
+ const Color c = Color( (*pData & 0xf800) >> 8, (*pData & 0x07e0) >> 3 , (*pData & 0x001f) << 3 );
pData++;
return c;
}
diff --git a/vcl/source/app/settings.cxx b/vcl/source/app/settings.cxx
index 1284abaf79a7..20fa2c749fe5 100644
--- a/vcl/source/app/settings.cxx
+++ b/vcl/source/app/settings.cxx
@@ -542,8 +542,8 @@ ImplStyleData::ImplStyleData() :
meUseImagesInMenus = TRISTATE_INDET;
meContextMenuShortcuts = TRISTATE_INDET;
mnEdgeBlending = 35;
- maEdgeBlendingTopLeftColor = RGB_COLORDATA(0xC0, 0xC0, 0xC0);
- maEdgeBlendingBottomRightColor = RGB_COLORDATA(0x40, 0x40, 0x40);
+ maEdgeBlendingTopLeftColor = Color(0xC0, 0xC0, 0xC0);
+ maEdgeBlendingBottomRightColor = Color(0x40, 0x40, 0x40);
mnListBoxMaximumLineCount = 25;
mnColorValueSetColumnCount = 12;
mnColorValueSetMaximumRowCount = 10;
@@ -2234,7 +2234,7 @@ Color StyleSettings::GetFaceGradientColor() const
GetFaceColor().RGBtoHSB( h, s, b );
if( s > 1) s=1;
if( b < 98) b=98;
- return Color( Color::HSBtoRGB( h, s, b ) );
+ return Color::HSBtoRGB( h, s, b );
}
Color StyleSettings::GetSeparatorColor() const
@@ -2244,7 +2244,7 @@ Color StyleSettings::GetSeparatorColor() const
GetShadowColor().RGBtoHSB( h, s, b );
b += b/4;
s -= s/4;
- return Color( Color::HSBtoRGB( h, s, b ) );
+ return Color::HSBtoRGB( h, s, b );
}
void StyleSettings::CopyData()