LCOV - code coverage report
Current view: top level - solver/unxlngi6.pro/inc/editeng - unoipset.hxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 2 2 100.0 %
Date: 2012-08-25 Functions: 2 2 100.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 2 2 100.0 %

           Branch data     Line data    Source code
       1                 :            : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2                 :            : /*************************************************************************
       3                 :            :  *
       4                 :            :  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
       5                 :            :  *
       6                 :            :  * Copyright 2000, 2010 Oracle and/or its affiliates.
       7                 :            :  *
       8                 :            :  * OpenOffice.org - a multi-platform office productivity suite
       9                 :            :  *
      10                 :            :  * This file is part of OpenOffice.org.
      11                 :            :  *
      12                 :            :  * OpenOffice.org is free software: you can redistribute it and/or modify
      13                 :            :  * it under the terms of the GNU Lesser General Public License version 3
      14                 :            :  * only, as published by the Free Software Foundation.
      15                 :            :  *
      16                 :            :  * OpenOffice.org is distributed in the hope that it will be useful,
      17                 :            :  * but WITHOUT ANY WARRANTY; without even the implied warranty of
      18                 :            :  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      19                 :            :  * GNU Lesser General Public License version 3 for more details
      20                 :            :  * (a copy is included in the LICENSE file that accompanied this code).
      21                 :            :  *
      22                 :            :  * You should have received a copy of the GNU Lesser General Public License
      23                 :            :  * version 3 along with OpenOffice.org.  If not, see
      24                 :            :  * <http://www.openoffice.org/license.html>
      25                 :            :  * for a copy of the LGPLv3 License.
      26                 :            :  *
      27                 :            :  ************************************************************************/
      28                 :            : 
      29                 :            : #ifndef _SVX_UNOIPSET_HXX_
      30                 :            : #define _SVX_UNOIPSET_HXX_
      31                 :            : 
      32                 :            : #include <com/sun/star/beans/XPropertySetInfo.hpp>
      33                 :            : #include <com/sun/star/beans/XPropertySet.hpp>
      34                 :            : #include "editeng/editengdllapi.h"
      35                 :            : #include <svl/itemprop.hxx>
      36                 :            : #include <vector>
      37                 :            : 
      38                 :            : class SdrItemPool;
      39                 :            : class SfxItemSet;
      40                 :            : class SvxShape;
      41                 :            : struct SvxIDPropertyCombine;
      42                 :            : 
      43                 :            : #define SFX_METRIC_ITEM                         (0x40)
      44                 :            : 
      45                 :            : class EDITENG_DLLPUBLIC SvxItemPropertySet
      46                 :            : {
      47                 :            :     SfxItemPropertyMap          m_aPropertyMap;
      48                 :            :     mutable com::sun::star::uno::Reference<com::sun::star::beans::XPropertySetInfo> m_xInfo;
      49                 :            :     const SfxItemPropertyMapEntry*  _pMap;
      50                 :            :     ::std::vector< SvxIDPropertyCombine* > aCombineList;
      51                 :            :     sal_Bool                        mbConvertTwips;
      52                 :            :     SfxItemPool&                    mrItemPool;
      53                 :            : 
      54                 :            : public:
      55                 :            :     SvxItemPropertySet( const SfxItemPropertyMapEntry *pMap, SfxItemPool& rPool, sal_Bool bConvertTwips = sal_False );
      56                 :            :     ~SvxItemPropertySet();
      57                 :            : 
      58                 :            :     // Methods, which work directly with the ItemSet
      59                 :            :     ::com::sun::star::uno::Any getPropertyValue( const SfxItemPropertySimpleEntry* pMap, const SfxItemSet& rSet, bool bSearchInParent, bool bDontConvertNegativeValues ) const;
      60                 :            :     void setPropertyValue( const SfxItemPropertySimpleEntry* pMap, const ::com::sun::star::uno::Any& rVal, SfxItemSet& rSet, bool bDontConvertNegativeValues ) const;
      61                 :            : 
      62                 :            :     // Methods that use Any instead
      63                 :            :     ::com::sun::star::uno::Any getPropertyValue( const SfxItemPropertySimpleEntry* pMap ) const;
      64                 :            :     void setPropertyValue( const SfxItemPropertySimpleEntry* pMap, const ::com::sun::star::uno::Any& rVal ) const;
      65                 :            : 
      66         [ +  + ]:      89897 :     sal_Bool AreThereOwnUsrAnys() const { return ( aCombineList.empty() ? sal_False : sal_True ); }
      67                 :            :     ::com::sun::star::uno::Any* GetUsrAnyForID(sal_uInt16 nWID) const;
      68                 :            :     void AddUsrAnyForID(const ::com::sun::star::uno::Any& rAny, sal_uInt16 nWID);
      69                 :            :     void ClearAllUsrAny();
      70                 :            : 
      71                 :            :     com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > getPropertySetInfo() const;
      72                 :            :     const SfxItemPropertyMapEntry* getPropertyMapEntries() const {return _pMap;}
      73                 :        674 :     const SfxItemPropertyMap* getPropertyMap()const { return &m_aPropertyMap;}
      74                 :            :     const SfxItemPropertySimpleEntry* getPropertyMapEntry(const ::rtl::OUString &rName) const;
      75                 :            : 
      76                 :            :     static com::sun::star::uno::Reference< com::sun::star::beans::XPropertySetInfo > getPropertySetInfo( const SfxItemPropertyMapEntry* pMap );
      77                 :            : };
      78                 :            : 
      79                 :            : /** converts the given any with a metric to 100th/mm if needed */
      80                 :            : EDITENG_DLLPUBLIC void SvxUnoConvertToMM( const SfxMapUnit eSourceMapUnit, com::sun::star::uno::Any & rMetric ) throw();
      81                 :            : 
      82                 :            : /** converts the given any with a metric from 100th/mm to the given metric if needed */
      83                 :            : EDITENG_DLLPUBLIC void SvxUnoConvertFromMM( const SfxMapUnit eDestinationMapUnit, com::sun::star::uno::Any & rMetric ) throw();
      84                 :            : 
      85                 :            : #endif // _SVX_UNOIPSET_HXX_
      86                 :            : 
      87                 :            : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10