summaryrefslogtreecommitdiff
path: root/vcl/source/gdi
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2015-11-19 11:51:47 +0000
committerCaolán McNamara <caolanm@redhat.com>2015-11-23 14:25:59 +0000
commitb639fe60eab2a221e23dc9d509f9281857d656a3 (patch)
treedf756046e58d3b36891676b8c45449a3ff6a2223 /vcl/source/gdi
parentc43a3a58677b467274ce6c21d7db1a6c0cc65cb4 (diff)
VirtualDevices either match another device depth, or are 1 bit
cairo can therefore always render to a svp virtual device with need for a fallback Change-Id: I5d03ae541820389e26f7448444444be009fb28a4
Diffstat (limited to 'vcl/source/gdi')
-rw-r--r--vcl/source/gdi/bitmapex.cxx2
-rw-r--r--vcl/source/gdi/gdimtf.cxx2
-rw-r--r--vcl/source/gdi/pdfwriter_impl.cxx2
-rw-r--r--vcl/source/gdi/virdev.cxx4
4 files changed, 4 insertions, 6 deletions
diff --git a/vcl/source/gdi/bitmapex.cxx b/vcl/source/gdi/bitmapex.cxx
index a75afd6afbf0..f390855e7d7b 100644
--- a/vcl/source/gdi/bitmapex.cxx
+++ b/vcl/source/gdi/bitmapex.cxx
@@ -698,7 +698,7 @@ BitmapEx BitmapEx:: AutoScaleBitmap(BitmapEx & aBitmap, const long aStandardSize
Rectangle aRect(aEmptyPoint, aStdSize );
ScopedVclPtrInstance< VirtualDevice > aVirDevice(*Application::GetDefaultDevice(),
- DeviceFormat::FULLCOLOR, DeviceFormat::BITMASK);
+ DeviceFormat::DEFAULT, DeviceFormat::BITMASK);
aVirDevice->SetOutputSizePixel( aStdSize );
aVirDevice->SetFillColor( COL_TRANSPARENT );
aVirDevice->SetLineColor( COL_TRANSPARENT );
diff --git a/vcl/source/gdi/gdimtf.cxx b/vcl/source/gdi/gdimtf.cxx
index b7be53beb206..21d1f112a641 100644
--- a/vcl/source/gdi/gdimtf.cxx
+++ b/vcl/source/gdi/gdimtf.cxx
@@ -886,7 +886,7 @@ void GDIMetaFile::ImplAddGradientEx( GDIMetaFile& rMtf,
const Gradient& rGrad )
{
// Generate comment, GradientEx and Gradient actions (within DrawGradient)
- ScopedVclPtrInstance< VirtualDevice > aVDev(rMapDev, DeviceFormat::FULLCOLOR);
+ ScopedVclPtrInstance< VirtualDevice > aVDev(rMapDev, DeviceFormat::DEFAULT);
aVDev->EnableOutput( false );
GDIMetaFile aGradMtf;
diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx
index a454704cfb3c..13906b435b01 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -2222,7 +2222,7 @@ OutputDevice* PDFWriterImpl::getReferenceDevice()
{
if( ! m_pReferenceDevice )
{
- VclPtrInstance<VirtualDevice> pVDev(DeviceFormat::FULLCOLOR);
+ VclPtrInstance<VirtualDevice> pVDev(DeviceFormat::DEFAULT);
m_pReferenceDevice = pVDev;
diff --git a/vcl/source/gdi/virdev.cxx b/vcl/source/gdi/virdev.cxx
index 4557dc232c94..cab8fa3953f3 100644
--- a/vcl/source/gdi/virdev.cxx
+++ b/vcl/source/gdi/virdev.cxx
@@ -165,8 +165,6 @@ void VirtualDevice::ImplInitVirDev( const OutputDevice* pOutDev,
{
case DeviceFormat::BITMASK:
mnBitCount = 1;
- case DeviceFormat::GRAYSCALE:
- mnBitCount = 8;
default:
mnBitCount = pOutDev->GetBitCount();
break;
@@ -453,7 +451,7 @@ bool VirtualDevice::SetOutputSizePixelScaleOffsetAndBuffer(
const basebmp::RawMemorySharedArray &pBuffer, const basebmp::RawMemorySharedArray &pAlphaBuffer )
{
if (pAlphaBuffer)
- meAlphaFormat = DeviceFormat::GRAYSCALE;
+ meAlphaFormat = DeviceFormat::DEFAULT;
if (pBuffer) {
MapMode mm = GetMapMode();