diff options
author | Thorsten Behrens <tbehrens@suse.com> | 2012-03-07 00:31:56 +0100 |
---|---|---|
committer | Tor Lillqvist <tlillqvist@suse.com> | 2012-03-19 08:28:14 +0200 |
commit | 0ad246127fe8f9d788793ceb8dc327e25ef4a699 (patch) | |
tree | b91ef9497f24342bda765c312c1e336ebabeed65 | |
parent | bed182f5f3059e30c3e53a163a031de1f0c2bc46 (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.
(cherry picked from commit 4b475f31eb9b290b477bb6992ff28e52248cee5d)
Signed-off-by: Tor Lillqvist <tlillqvist@suse.com>
-rw-r--r-- | canvas/source/vcl/canvashelper.cxx | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/canvas/source/vcl/canvashelper.cxx b/canvas/source/vcl/canvashelper.cxx index c5c5943683c7..5d4c40a31ceb 100644 --- a/canvas/source/vcl/canvashelper.cxx +++ b/canvas/source/vcl/canvashelper.cxx @@ -1269,21 +1269,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: |