summaryrefslogtreecommitdiff
path: root/cui
diff options
context:
space:
mode:
Diffstat (limited to 'cui')
-rw-r--r--cui/source/dialogs/colorpicker.cxx18
1 files changed, 12 insertions, 6 deletions
diff --git a/cui/source/dialogs/colorpicker.cxx b/cui/source/dialogs/colorpicker.cxx
index 6492ad558a3e..d6e0269b39b4 100644
--- a/cui/source/dialogs/colorpicker.cxx
+++ b/cui/source/dialogs/colorpicker.cxx
@@ -334,72 +334,78 @@ void ColorFieldControl::UpdateBitmap()
case HUE:
while (y--)
{
+ Scanline pScanline = pWriteAccess->GetScanline( y );
nBri = pPercent_Vert[y];
x = nWidth;
while (x--)
{
nSat = pPercent_Horiz[x];
- pWriteAccess->SetPixel(y, x, BitmapColor(Color(Color::HSBtoRGB(nHue, nSat, nBri))));
+ pWriteAccess->SetPixelOnData(pScanline, x, BitmapColor(Color(Color::HSBtoRGB(nHue, nSat, nBri))));
}
}
break;
case SATURATION:
while (y--)
{
+ Scanline pScanline = pWriteAccess->GetScanline( y );
nBri = pPercent_Vert[y];
x = nWidth;
while (x--)
{
nHue = pGrad_Horiz[x];
- pWriteAccess->SetPixel(y, x, BitmapColor(Color(Color::HSBtoRGB(nHue, nSat, nBri))));
+ pWriteAccess->SetPixelOnData(pScanline, x, BitmapColor(Color(Color::HSBtoRGB(nHue, nSat, nBri))));
}
}
break;
case BRIGHTNESS:
while (y--)
{
+ Scanline pScanline = pWriteAccess->GetScanline( y );
nSat = pPercent_Vert[y];
x = nWidth;
while (x--)
{
nHue = pGrad_Horiz[x];
- pWriteAccess->SetPixel(y, x, BitmapColor(Color(Color::HSBtoRGB(nHue, nSat, nBri))));
+ pWriteAccess->SetPixelOnData(pScanline, x, BitmapColor(Color(Color::HSBtoRGB(nHue, nSat, nBri))));
}
}
break;
case RED:
while (y--)
{
+ Scanline pScanline = pWriteAccess->GetScanline( y );
aBitmapColor.SetGreen(pRGB_Vert[y]);
x = nWidth;
while (x--)
{
aBitmapColor.SetBlue(pRGB_Horiz[x]);
- pWriteAccess->SetPixel(y, x, aBitmapColor);
+ pWriteAccess->SetPixelOnData(pScanline, x, aBitmapColor);
}
}
break;
case GREEN:
while (y--)
{
+ Scanline pScanline = pWriteAccess->GetScanline( y );
aBitmapColor.SetRed(pRGB_Vert[y]);
x = nWidth;
while (x--)
{
aBitmapColor.SetBlue(pRGB_Horiz[x]);
- pWriteAccess->SetPixel(y, x, aBitmapColor);
+ pWriteAccess->SetPixelOnData(pScanline, x, aBitmapColor);
}
}
break;
case BLUE:
while (y--)
{
+ Scanline pScanline = pWriteAccess->GetScanline( y );
aBitmapColor.SetGreen(pRGB_Vert[y]);
x = nWidth;
while (x--)
{
aBitmapColor.SetRed(pRGB_Horiz[x]);
- pWriteAccess->SetPixel(y, x, aBitmapColor);
+ pWriteAccess->SetPixelOnData(pScanline, x, aBitmapColor);
}
}
break;