LCOV - code coverage report
Current view: top level - include/svx - paraprev.hxx (source / functions) Hit Total Coverage
Test: commit 10e77ab3ff6f4314137acd6e2702a6e5c1ce1fae Lines: 0 14 0.0 %
Date: 2014-11-03 Functions: 0 14 0.0 %
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             : #ifndef INCLUDED_SVX_PARAPREV_HXX
      20             : #define INCLUDED_SVX_PARAPREV_HXX
      21             : 
      22             : #include <vcl/window.hxx>
      23             : #include <editeng/svxenum.hxx>
      24             : #include <svx/svxdllapi.h>
      25             : 
      26             : // enum ------------------------------------------------------------------
      27             : 
      28             : enum SvxPrevLineSpace
      29             : {
      30             :     SVX_PREV_LINESPACE_1 = 0,
      31             :     SVX_PREV_LINESPACE_15,
      32             :     SVX_PREV_LINESPACE_2,
      33             :     SVX_PREV_LINESPACE_PROP,
      34             :     SVX_PREV_LINESPACE_MIN,
      35             :     SVX_PREV_LINESPACE_DURCH
      36             : };
      37             : 
      38             : // class SvxParaPrevWindow -----------------------------------------------
      39             : 
      40           0 : class SVX_DLLPUBLIC SvxParaPrevWindow : public vcl::Window
      41             : {
      42             :     using Window::Draw;
      43             : private:
      44             :     Size                aSize;
      45             : 
      46             :     // indentation
      47             :     long                nLeftMargin;
      48             :     long                nRightMargin;
      49             :     short               nFirstLineOfst;
      50             :     // distances
      51             :     sal_uInt16          nUpper;
      52             :     sal_uInt16          nLower;
      53             :     // adjustment
      54             :     SvxAdjust           eAdjust;
      55             :     // last line in justification
      56             :     SvxAdjust           eLastLine;
      57             :     // line distance
      58             :     SvxPrevLineSpace    eLine;
      59             :     sal_uInt16          nLineVal;
      60             : 
      61             :     OUString            aText;
      62             :     Rectangle           Lines[9];
      63             : 
      64             : protected:
      65             :     virtual void Paint( const Rectangle& rRect ) SAL_OVERRIDE;
      66             :     virtual Size GetOptimalSize() const SAL_OVERRIDE;
      67             : 
      68             :     void DrawParagraph( bool bAll );
      69             : 
      70             : public:
      71             :     SvxParaPrevWindow( vcl::Window* pParent, WinBits nBits);
      72             : 
      73           0 :     void        SetFirstLineOfst( short nNew )  { nFirstLineOfst = nNew; }
      74           0 :     void        SetLeftMargin( long nNew )      { nLeftMargin = nNew; }
      75           0 :     void        SetRightMargin( long nNew )     { nRightMargin = nNew; }
      76           0 :     void        SetUpper( sal_uInt16 nNew )     { nUpper = nNew; }
      77           0 :     void        SetLower( sal_uInt16 nNew )     { nLower = nNew; }
      78           0 :     void        SetAdjust( SvxAdjust eNew )     { eAdjust = eNew; }
      79           0 :     void        SetLastLine( SvxAdjust eNew )   { eLastLine = eNew; }
      80           0 :     void        SetLineSpace( SvxPrevLineSpace eNew, sal_uInt16 nNew = 0 )
      81           0 :                     {   eLine = eNew; nLineVal = nNew; }
      82           0 :     void        SetText( const OUString& rStr ) SAL_OVERRIDE { aText = rStr; }
      83           0 :     void        SetSize( Size aNew )            { aSize = aNew; }
      84             : 
      85             :     short       GetFirstLineOfst() const        { return nFirstLineOfst; }
      86             :     long        GetLeftMargin() const           { return nLeftMargin; }
      87             :     long        GetRightMargin() const          { return nRightMargin; }
      88             :     sal_uInt16  GetUpper() const                { return nUpper; }
      89             :     sal_uInt16  GetLower() const                { return nLower; }
      90             :     SvxAdjust   GetAdjust() const               { return eAdjust; }
      91             : 
      92             :     SvxPrevLineSpace    GetLineEnum() const     { return eLine; }
      93             :     sal_uInt16          GetLineValue() const    { return nLineVal; }
      94           0 :     OUString            GetText() const SAL_OVERRIDE         { return aText; }
      95             :     Size                GetSize() const         { return aSize; }
      96             : 
      97           0 :     void        Draw( bool bAll )               { DrawParagraph( bAll ); }
      98             : };
      99             : 
     100             : #endif
     101             : 
     102             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10