LCOV - code coverage report
Current view: top level - drawinglayer/source/primitive2d - texthierarchyprimitive2d.cxx (source / functions) Hit Total Coverage
Test: commit c8344322a7af75b84dd3ca8f78b05543a976dfd5 Lines: 24 30 80.0 %
Date: 2015-06-13 12:38:46 Functions: 12 13 92.3 %
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 <drawinglayer/primitive2d/texthierarchyprimitive2d.hxx>
      21             : #include <drawinglayer/primitive2d/drawinglayer_primitivetypes2d.hxx>
      22             : 
      23             : 
      24             : 
      25             : using namespace com::sun::star;
      26             : 
      27             : 
      28             : 
      29             : namespace drawinglayer
      30             : {
      31             :     namespace primitive2d
      32             :     {
      33       21926 :         TextHierarchyLinePrimitive2D::TextHierarchyLinePrimitive2D(const Primitive2DSequence& rChildren)
      34       21926 :         :   GroupPrimitive2D(rChildren)
      35             :         {
      36       21926 :         }
      37             : 
      38             :         // provide unique ID
      39       14745 :         ImplPrimitive2DIDBlock(TextHierarchyLinePrimitive2D, PRIMITIVE2D_ID_TEXTHIERARCHYLINEPRIMITIVE2D)
      40             : 
      41             :     } // end of namespace primitive2d
      42             : } // end of namespace drawinglayer
      43             : 
      44             : 
      45             : 
      46             : namespace drawinglayer
      47             : {
      48             :     namespace primitive2d
      49             :     {
      50       19827 :         TextHierarchyParagraphPrimitive2D::TextHierarchyParagraphPrimitive2D(const Primitive2DSequence& rChildren)
      51       19827 :         :   GroupPrimitive2D(rChildren)
      52             :         {
      53       19827 :         }
      54             : 
      55             :         // provide unique ID
      56       12664 :         ImplPrimitive2DIDBlock(TextHierarchyParagraphPrimitive2D, PRIMITIVE2D_ID_TEXTHIERARCHYPARAGRAPHPRIMITIVE2D)
      57             : 
      58             :     } // end of namespace primitive2d
      59             : } // end of namespace drawinglayer
      60             : 
      61             : 
      62             : 
      63             : namespace drawinglayer
      64             : {
      65             :     namespace primitive2d
      66             :     {
      67         941 :         TextHierarchyBulletPrimitive2D::TextHierarchyBulletPrimitive2D(const Primitive2DSequence& rChildren)
      68         941 :         :   GroupPrimitive2D(rChildren)
      69             :         {
      70         941 :         }
      71             : 
      72             :         // provide unique ID
      73          23 :         ImplPrimitive2DIDBlock(TextHierarchyBulletPrimitive2D, PRIMITIVE2D_ID_TEXTHIERARCHYBULLETPRIMITIVE2D)
      74             : 
      75             :     } // end of namespace primitive2d
      76             : } // end of namespace drawinglayer
      77             : 
      78             : 
      79             : 
      80             : namespace drawinglayer
      81             : {
      82             :     namespace primitive2d
      83             :     {
      84       17483 :         TextHierarchyBlockPrimitive2D::TextHierarchyBlockPrimitive2D(const Primitive2DSequence& rChildren)
      85       17483 :         :   GroupPrimitive2D(rChildren)
      86             :         {
      87       17483 :         }
      88             : 
      89             :         // provide unique ID
      90       11094 :         ImplPrimitive2DIDBlock(TextHierarchyBlockPrimitive2D, PRIMITIVE2D_ID_TEXTHIERARCHYBLOCKPRIMITIVE2D)
      91             : 
      92             :     } // end of namespace primitive2d
      93             : } // end of namespace drawinglayer
      94             : 
      95             : 
      96             : 
      97             : namespace drawinglayer
      98             : {
      99             :     namespace primitive2d
     100             :     {
     101        1603 :         TextHierarchyFieldPrimitive2D::TextHierarchyFieldPrimitive2D(
     102             :             const Primitive2DSequence& rChildren,
     103             :             const FieldType& rFieldType,
     104             :             const OUString& rString)
     105             :         :   GroupPrimitive2D(rChildren),
     106             :             meType(rFieldType),
     107        1603 :             maString(rString)
     108             :         {
     109        1603 :         }
     110             : 
     111           0 :         bool TextHierarchyFieldPrimitive2D::operator==(const BasePrimitive2D& rPrimitive) const
     112             :         {
     113           0 :             if(GroupPrimitive2D::operator==(rPrimitive))
     114             :             {
     115           0 :                 const TextHierarchyFieldPrimitive2D& rCompare = static_cast<const TextHierarchyFieldPrimitive2D&>(rPrimitive);
     116             : 
     117           0 :                 return (getType() == rCompare.getType()
     118           0 :                     &&  getString() == rCompare.getString());
     119             :             }
     120             : 
     121           0 :             return false;
     122             :         }
     123             : 
     124             :         // provide unique ID
     125         123 :         ImplPrimitive2DIDBlock(TextHierarchyFieldPrimitive2D, PRIMITIVE2D_ID_TEXTHIERARCHYFIELDPRIMITIVE2D)
     126             :     } // end of namespace primitive2d
     127             : } // end of namespace drawinglayer
     128             : 
     129             : 
     130             : 
     131             : namespace drawinglayer
     132             : {
     133             :     namespace primitive2d
     134             :     {
     135           7 :         TextHierarchyEditPrimitive2D::TextHierarchyEditPrimitive2D(const Primitive2DSequence& rChildren)
     136           7 :         :   GroupPrimitive2D(rChildren)
     137             :         {
     138           7 :         }
     139             : 
     140             :         // provide unique ID
     141          42 :         ImplPrimitive2DIDBlock(TextHierarchyEditPrimitive2D, PRIMITIVE2D_ID_TEXTHIERARCHYEDITPRIMITIVE2D)
     142             : 
     143             :     } // end of namespace primitive2d
     144             : } // end of namespace drawinglayer
     145             : 
     146             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.11