summaryrefslogtreecommitdiff
path: root/canvas
diff options
context:
space:
mode:
authorThorsten Behrens <tbehrens@suse.com>2012-03-07 00:31:56 +0100
committerThorsten Behrens <tbehrens@suse.com>2012-03-16 17:02:22 +0100
commit4b475f31eb9b290b477bb6992ff28e52248cee5d (patch)
tree932960f6e9904741413e4abd068ed06295957d25 /canvas
parentac2eaaab7af7100b527b76adb35718317f33c49c (diff)
Return proper transparency value even for ignore_color.
Rather unexpectedly, calling setupOutDevState() with IGNORE_COLOR does not return a proper transparency, but null. Fixed now.
Diffstat (limited to 'canvas')
-rw-r--r--canvas/source/vcl/canvashelper.cxx24
1 files changed, 12 insertions, 12 deletions
diff --git a/canvas/source/vcl/canvashelper.cxx b/canvas/source/vcl/canvashelper.cxx
index cc0640bc508d..96f5979de567 100644
--- a/canvas/source/vcl/canvashelper.cxx
+++ b/canvas/source/vcl/canvashelper.cxx
@@ -1270,21 +1270,21 @@ namespace vclcanvas
p2ndOutDev->SetClipRegion( aClipRegion );
}
- if( eColorType != IGNORE_COLOR )
- {
- Color aColor( COL_WHITE );
+ Color aColor( COL_WHITE );
- if( renderState.DeviceColor.getLength() > 2 )
- {
- aColor = ::vcl::unotools::stdColorSpaceSequenceToColor(
- renderState.DeviceColor );
- }
+ if( renderState.DeviceColor.getLength() > 2 )
+ {
+ aColor = ::vcl::unotools::stdColorSpaceSequenceToColor(
+ renderState.DeviceColor );
+ }
- // extract alpha, and make color opaque
- // afterwards. Otherwise, OutputDevice won't draw anything
- nTransparency = aColor.GetTransparency();
- aColor.SetTransparency(0);
+ // extract alpha, and make color opaque
+ // afterwards. Otherwise, OutputDevice won't draw anything
+ nTransparency = aColor.GetTransparency();
+ aColor.SetTransparency(0);
+ if( eColorType != IGNORE_COLOR )
+ {
switch( eColorType )
{
case LINE_COLOR: