Version 6.1.0.2, tag libreoffice-6.1.0.2
[LibreOffice.git] / sc / inc / rowheightcontext.hxx
blobd1a8f8ff68e42e904590c54b31753e9c8f50d831
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
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 */
10 #ifndef INCLUDED_SC_INC_ROWHEIGHTCONTEXT_HXX
11 #define INCLUDED_SC_INC_ROWHEIGHTCONTEXT_HXX
13 #include "scdllapi.h"
15 #include <tools/fract.hxx>
16 #include <vcl/vclptr.hxx>
17 #include <vcl/outdev.hxx>
19 #include <vector>
21 #include "segmenttree.hxx"
23 namespace sc {
25 class SC_DLLPUBLIC RowHeightContext
27 ScFlatUInt16RowSegments maHeights;
29 double mfPPTX;
30 double mfPPTY;
31 Fraction maZoomX;
32 Fraction maZoomY;
33 VclPtr<OutputDevice> mpOutDev;
35 sal_uInt16 mnExtraHeight;
36 bool mbForceAutoSize; /// whether to set height to optimal even when the manual height flag is set.
38 public:
39 RowHeightContext(
40 double fPPTX, double fPPTY, const Fraction& rZoomX, const Fraction& rZoomY,
41 OutputDevice* pOutDev );
43 ~RowHeightContext();
45 double getPPTX() const { return mfPPTX;}
46 double getPPTY() const { return mfPPTY;}
47 const Fraction& getZoomX() const { return maZoomX;}
48 const Fraction& getZoomY() const { return maZoomY;}
50 OutputDevice* getOutputDevice() { return mpOutDev;}
52 void setExtraHeight( sal_uInt16 nH );
53 sal_uInt16 getExtraHeight() const { return mnExtraHeight;}
55 void setForceAutoSize( bool b );
56 bool isForceAutoSize() const { return mbForceAutoSize;}
58 ScFlatUInt16RowSegments& getHeightArray();
63 #endif
65 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */