LCOV - code coverage report
Current view: top level - include/vcl - alpha.hxx (source / functions) Hit Total Coverage
Test: commit c8344322a7af75b84dd3ca8f78b05543a976dfd5 Lines: 5 8 62.5 %
Date: 2015-06-13 12:38:46 Functions: 5 8 62.5 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2             : /*
       3             :  * This file is part of the LibreOffice project.
       4             :  *
       5             :  * This Source Code Form is subject to the terms of the Mozilla Public
       6             :  * License, v. 2.0. If a copy of the MPL was not distributed with this
       7             :  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
       8             :  *
       9             :  * This file incorporates work covered by the following license notice:
      10             :  *
      11             :  *   Licensed to the Apache Software Foundation (ASF) under one or more
      12             :  *   contributor license agreements. See the NOTICE file distributed
      13             :  *   with this work for additional information regarding copyright
      14             :  *   ownership. The ASF licenses this file to you under the Apache
      15             :  *   License, Version 2.0 (the "License"); you may not use this file
      16             :  *   except in compliance with the License. You may obtain a copy of
      17             :  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
      18             :  */
      19             : 
      20             : #ifndef INCLUDED_VCL_ALPHA_HXX
      21             : #define INCLUDED_VCL_ALPHA_HXX
      22             : 
      23             : #include <vcl/dllapi.h>
      24             : #include <vcl/bitmap.hxx>
      25             : 
      26             : 
      27             : class ImageList;
      28             : class BitmapEx;
      29             : 
      30             : class VCL_DLLPUBLIC AlphaMask : private Bitmap
      31             : {
      32             : public:
      33             : 
      34             :                 AlphaMask();
      35             :                 AlphaMask( const Bitmap& rBitmap );
      36             :                 AlphaMask( const AlphaMask& rAlphaMask );
      37             :                 AlphaMask( const Size& rSizePixel, sal_uInt8* pEraseTransparency = NULL );
      38             :     virtual     ~AlphaMask();
      39             : 
      40             :     AlphaMask&  operator=( const Bitmap& rBitmap );
      41         382 :     AlphaMask&  operator=( const AlphaMask& rAlphaMask ) { return static_cast<AlphaMask&>( Bitmap::operator=( rAlphaMask ) ); }
      42       47348 :     bool        operator!() const { return Bitmap::operator!(); }
      43             :     bool        operator==( const AlphaMask& rAlphaMask ) const { return Bitmap::operator==( rAlphaMask ); }
      44             :     bool        operator!=( const AlphaMask& rAlphaMask ) const { return Bitmap::operator!=( rAlphaMask ); }
      45             : 
      46             :     const       MapMode&  GetPrefMapMode() const { return Bitmap::GetPrefMapMode(); }
      47           0 :     void        SetPrefMapMode( const MapMode& rMapMode ) { Bitmap::SetPrefMapMode( rMapMode ); }
      48             : 
      49             :     const       Size& GetPrefSize() const { return Bitmap::GetPrefSize(); }
      50           0 :     void        SetPrefSize( const Size& rSize ) { Bitmap::SetPrefSize( rSize ); }
      51             : 
      52         400 :     Size        GetSizePixel() const { return Bitmap::GetSizePixel(); }
      53             :     sal_uLong   GetSizeBytes() const { return Bitmap::GetSizeBytes(); }
      54             : 
      55           0 :     sal_uLong   GetChecksum() const { return Bitmap::GetChecksum(); }
      56             : 
      57             :     Bitmap      GetBitmap() const;
      58             : 
      59             :     bool        Erase( sal_uInt8 cTransparency );
      60             :     bool        Replace( const Bitmap& rMask, sal_uInt8 rReplaceTransparency );
      61             :     bool        Replace( sal_uInt8 cSearchTransparency, sal_uInt8 cReplaceTransparency, sal_uLong nTol = 0UL );
      62             : 
      63      139788 :     BitmapReadAccess*  AcquireReadAccess() { return Bitmap::AcquireReadAccess(); }
      64       18682 :     BitmapWriteAccess* AcquireWriteAccess() { return Bitmap::AcquireWriteAccess(); }
      65             : 
      66             :     void        ReleaseAccess( BitmapReadAccess* pAccess );
      67             : 
      68             :     typedef vcl::ScopedBitmapAccess< BitmapReadAccess, AlphaMask, &AlphaMask::AcquireReadAccess >
      69             :         ScopedReadAccess;
      70             :     typedef vcl::ScopedBitmapAccess< BitmapWriteAccess, AlphaMask, &AlphaMask::AcquireWriteAccess >
      71             :         ScopedWriteAccess;
      72             : 
      73             : private:
      74             :     friend class BitmapEx;
      75             :     friend class ::OutputDevice;
      76             :     friend bool VCL_DLLPUBLIC ReadDIBBitmapEx(BitmapEx& rTarget, SvStream& rIStm);
      77             : 
      78             :     SAL_DLLPRIVATE const Bitmap&    ImplGetBitmap() const;
      79             :     SAL_DLLPRIVATE void             ImplSetBitmap( const Bitmap& rBitmap );
      80             : 
      81             : };
      82             : 
      83             : #endif // INCLUDED_VCL_ALPHA_HXX
      84             : 
      85             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.11