LCOV - code coverage report
Current view: top level - libreoffice/sw/source/core/bastyp - swtypes.cxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 44 48 91.7 %
Date: 2012-12-27 Functions: 5 7 71.4 %
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             : #include "swtypes.hxx"
      21             : #include "tools/string.hxx"
      22             : 
      23             : #include <bodyfrm.hxx>
      24             : #include <cellfrm.hxx>
      25             : #include <colfrm.hxx>
      26             : #include <editeng/unolingu.hxx>
      27             : #include <fntcache.hxx>
      28             : #include <frmfmt.hxx>
      29             : #include <frmtool.hxx>
      30             : #include <hffrm.hxx>
      31             : #include <ndtxt.hxx>
      32             : #include <pagefrm.hxx>
      33             : #include <rowfrm.hxx>
      34             : #include <sectfrm.hxx>
      35             : #include <swatrset.hxx>
      36             : #include <swfntcch.hxx>
      37             : #include <swtable.hxx>
      38             : #include <swtblfmt.hxx>
      39             : #include <tabfrm.hxx>
      40             : #include <txtfrm.hxx>
      41             : #include <UndoDelete.hxx>
      42             : #include <UndoInsert.hxx>
      43             : #include <vcl/svapp.hxx>
      44             : #include <vcl/window.hxx>
      45             : #include <vcl/graph.hxx>
      46             : #include <viscrs.hxx>
      47             : 
      48             : using namespace com::sun::star;
      49             : 
      50          10 : UniString aEmptyStr;    // constant string
      51          10 : rtl::OUString aDotStr('.'); // constant string
      52             : 
      53          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwAttrSet )
      54          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwStartNode )
      55          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwEndNode )
      56          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwTableBox )
      57          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwUndoDelete )
      58          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwUndoInsert )
      59          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwPaM )
      60          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwCursor )
      61          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwShellCrsr )
      62          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwTxtNode )
      63          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwpHints )
      64          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwFntObj )
      65          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwFontObj )
      66          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwBorderAttrs )
      67          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwCellFrm )
      68          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwRowFrm )
      69          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwColumnFrm )
      70          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwSectionFrm )
      71          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwTabFrm )
      72          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwPageFrm )
      73          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwBodyFrm )
      74          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwHeaderFrm )
      75          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwFooterFrm )
      76          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwTxtFrm )
      77          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwTableFmt )
      78          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwTableLineFmt )
      79          10 : IMPL_FIXEDMEMPOOL_NEWDEL( SwTableBoxFmt )
      80          10 : IMPL_FIXEDMEMPOOL_NEWDEL( _SwCursor_SavePos )
      81             : 
      82          41 : Size GetGraphicSizeTwip( const Graphic& rGraphic, OutputDevice* pOutDev )
      83             : {
      84          41 :     const MapMode aMapTwip( MAP_TWIP );
      85          41 :     Size aSize( rGraphic.GetPrefSize() );
      86          41 :     if( MAP_PIXEL == rGraphic.GetPrefMapMode().GetMapUnit() )
      87             :     {
      88          34 :         if( !pOutDev )
      89          34 :             pOutDev = Application::GetDefaultDevice();
      90          34 :         aSize = pOutDev->PixelToLogic( aSize, aMapTwip );
      91             :     }
      92             :     else
      93             :     {
      94             :         aSize = OutputDevice::LogicToLogic( aSize,
      95             :                                             rGraphic.GetPrefMapMode(),
      96           7 :                                             aMapTwip );
      97             :     }
      98          41 :     return aSize;
      99             : }
     100             : 
     101         563 : uno::Reference< linguistic2::XSpellChecker1 >  GetSpellChecker()
     102             : {
     103         563 :     return LinguMgr::GetSpellChecker();
     104             : }
     105             : 
     106         311 : uno::Reference< linguistic2::XHyphenator >  GetHyphenator()
     107             : {
     108         311 :     return LinguMgr::GetHyphenator();
     109             : }
     110             : 
     111           0 : uno::Reference< linguistic2::XThesaurus >  GetThesaurus()
     112             : {
     113           0 :     return LinguMgr::GetThesaurus();
     114             : }
     115             : 
     116           0 : uno::Reference< beans::XPropertySet >  GetLinguPropertySet()
     117             : {
     118           0 :     return LinguMgr::GetLinguPropertySet();
     119          30 : }
     120             : 
     121             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10