LibreOffice Module sw (master)  1
swtablerep.hxx
Go to the documentation of this file.
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_SW_SOURCE_UIBASE_INC_SWTABLEREP_HXX
20 #define INCLUDED_SW_SOURCE_UIBASE_INC_SWTABLEREP_HXX
21 
22 #include <memory>
23 #include <sfx2/tabdlg.hxx>
24 #include <swdllapi.h>
25 #include <swtypes.hxx>
26 
27 class SwTabCols;
28 struct TColumn;
30 {
31  std::unique_ptr<TColumn[]> m_pTColumns;
32 
37  sal_uInt16 m_nAlign;
38  sal_uInt16 m_nColCount;
39  sal_uInt16 m_nAllCols;
40  sal_uInt16 m_nWidthPercent;
41  bool m_bLineSelected : 1;
42  bool m_bWidthChanged : 1;
43  bool m_bColsChanged : 1;
44 
45 public:
46  SwTableRep( const SwTabCols& rTabCol );
47  ~SwTableRep();
48 
49  bool FillTabCols( SwTabCols& rTabCol ) const;
50 
51  SwTwips GetLeftSpace() const {return m_nLeftSpace;}
52  void SetLeftSpace(SwTwips nSet) {m_nLeftSpace = nSet;}
53 
54  SwTwips GetRightSpace() const {return m_nRightSpace;}
55  void SetRightSpace(SwTwips nSet) {m_nRightSpace = nSet;}
56 
57  SwTwips GetWidth() const {return m_nTableWidth;}
58  void SetWidth(SwTwips nSet) {m_nTableWidth = nSet;}
59 
60  sal_uInt16 GetWidthPercent() const {return m_nWidthPercent;}
61  void SetWidthPercent(sal_uInt16 nSet) {m_nWidthPercent = nSet;}
62 
63  sal_uInt16 GetAlign() const {return m_nAlign;}
64  void SetAlign(sal_uInt16 nSet) {m_nAlign = nSet;}
65 
66  sal_uInt16 GetColCount() const {return m_nColCount;}
67  sal_uInt16 GetAllColCount() const {return m_nAllCols;}
68 
69  bool HasColsChanged() const {return m_bColsChanged;}
70  void SetColsChanged() {m_bColsChanged = true;}
71 
72  bool HasWidthChanged() const {return m_bWidthChanged;}
73  void SetWidthChanged() {m_bWidthChanged = true;}
74 
75  bool IsLineSelected() const {return m_bLineSelected;}
76  void SetLineSelected(bool bSet) {m_bLineSelected = bSet;}
77 
78  SwTwips GetSpace() const { return m_nSpace;}
79  void SetSpace(SwTwips nSet) {m_nSpace = nSet;}
80 
81  TColumn* GetColumns() const {return m_pTColumns.get();}
82 };
83 #endif
84 
85 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
sal_uInt16 m_nColCount
Definition: swtablerep.hxx:38
void SetLeftSpace(SwTwips nSet)
Definition: swtablerep.hxx:52
SwTwips GetLeftSpace() const
Definition: swtablerep.hxx:51
bool HasWidthChanged() const
Definition: swtablerep.hxx:72
void SetAlign(sal_uInt16 nSet)
Definition: swtablerep.hxx:64
std::unique_ptr< TColumn[]> m_pTColumns
Definition: swtablerep.hxx:31
void SetSpace(SwTwips nSet)
Definition: swtablerep.hxx:79
sal_uInt16 m_nAlign
Definition: swtablerep.hxx:37
sal_uInt16 m_nAllCols
Definition: swtablerep.hxx:39
void SetColsChanged()
Definition: swtablerep.hxx:70
long SwTwips
Definition: swtypes.hxx:49
SwTwips GetRightSpace() const
Definition: swtablerep.hxx:54
bool HasColsChanged() const
Definition: swtablerep.hxx:69
SwTwips GetWidth() const
Definition: swtablerep.hxx:57
void SetRightSpace(SwTwips nSet)
Definition: swtablerep.hxx:55
void SetLineSelected(bool bSet)
Definition: swtablerep.hxx:76
sal_uInt16 GetAlign() const
Definition: swtablerep.hxx:63
SwTwips m_nLeftSpace
Definition: swtablerep.hxx:35
SwTwips m_nRightSpace
Definition: swtablerep.hxx:36
sal_uInt16 GetAllColCount() const
Definition: swtablerep.hxx:67
sal_uInt16 GetColCount() const
Definition: swtablerep.hxx:66
void SetWidth(SwTwips nSet)
Definition: swtablerep.hxx:58
sal_uInt16 GetWidthPercent() const
Definition: swtablerep.hxx:60
SwTwips GetSpace() const
Definition: swtablerep.hxx:78
void SetWidthChanged()
Definition: swtablerep.hxx:73
#define SW_DLLPUBLIC
Definition: swdllapi.h:28
SwTwips m_nTableWidth
Definition: swtablerep.hxx:33
sal_uInt16 m_nWidthPercent
Definition: swtablerep.hxx:40
void SetWidthPercent(sal_uInt16 nSet)
Definition: swtablerep.hxx:61
SwTwips m_nSpace
Definition: swtablerep.hxx:34
TColumn * GetColumns() const
Definition: swtablerep.hxx:81
bool IsLineSelected() const
Definition: swtablerep.hxx:75