- Main Page
- Related Pages
- Namespaces
- Classes
- Files

- File List
- File Members

IWORKTableRecorder.h
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /*
3 * This file is part of the libetonyek 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
10 #ifndef IWORKTABLERECORDER_H_INCLUDED
11 #define IWORKTABLERECORDER_H_INCLUDED
12
13 #include <boost/optional.hpp>
14 #include <boost/shared_ptr.hpp>
15
16 #include "IWORKStyle_fwd.h"
17 #include "IWORKTable.h"
18 #include "IWORKTypes.h"
19
20 namespace libetonyek
21 {
22
23 class IWORKText;
24
25 class IWORKTableRecorder
26 {
27 public:
28 IWORKTableRecorder();
29
30 void replay(IWORKTable &table) const;
31
32 void setSize(unsigned columns, unsigned rows);
33 void setHeaders(unsigned headerColumns, unsigned headerRows, unsigned footerRows);
34 void setBandedRows(bool banded);
35 void setRepeated(bool columns, bool rows);
36
37 void setStyle(const IWORKStylePtr_t &style);
38 void setSizes(const IWORKColumnSizes_t &columnSizes, const IWORKRowSizes_t &rowSizes);
39 void setBorders(const IWORKGridLineList_t &verticalLines, const IWORKGridLineList_t &horizontalLines);
40 void insertCell(unsigned column, unsigned row, const boost::optional<std::string> &value, const boost::shared_ptr<IWORKText> &content, unsigned columnSpan, unsigned rowSpan, const boost::optional<IWORKFormula> &formula, const IWORKStylePtr_t &style, IWORKCellType type);
41 void insertCoveredCell(unsigned column, unsigned row);
42
43 void setDefaultCellStyle(IWORKTable::CellType type, const IWORKStylePtr_t &style);
44 void setDefaultLayoutStyle(IWORKTable::CellType type, const IWORKStylePtr_t &style);
45 void setDefaultParagraphStyle(IWORKTable::CellType type, const IWORKStylePtr_t &style);
46
47 private:
48 struct Impl;
49
50 private:
51 boost::shared_ptr<Impl> m_impl;
52 };
53
54 }
55
56 #endif // IWORKTABLERECORDER_H_INCLUDED
57
58 /* vim:set shiftwidth=2 softtabstop=2 expandtab: */
libetonyek::IWORKTable::CellType
CellType
Definition: IWORKTable.h:48
IWORKStyle_fwd.h
libetonyek
Definition: IWORKBezierElement.cpp:18
libetonyek::IWORKTableRecorder::Impl
Definition: IWORKTableRecorder.cpp:281
libetonyek::IWORKTableRecorder::setSize
void setSize(unsigned columns, unsigned rows)
Definition: IWORKTableRecorder.cpp:305
libetonyek::IWORKTableRecorder::setRepeated
void setRepeated(bool columns, bool rows)
Definition: IWORKTableRecorder.cpp:320
libetonyek::IWORKTableRecorder::setBandedRows
void setBandedRows(bool banded)
Definition: IWORKTableRecorder.cpp:315
libetonyek::IWORKStylePtr_t
boost::shared_ptr< IWORKStyle > IWORKStylePtr_t
Definition: IWORKStyle_fwd.h:21
libetonyek::IWORKToken::content
Definition: IWORKToken.h:88
libetonyek::IWORKTableRecorder::m_impl
boost::shared_ptr< Impl > m_impl
Definition: IWORKTableRecorder.h:48
libetonyek::IWORKTableRecorder::setStyle
void setStyle(const IWORKStylePtr_t &style)
Definition: IWORKTableRecorder.cpp:325
libetonyek::IWORKTableRecorder::insertCell
void insertCell(unsigned column, unsigned row, const boost::optional< std::string > &value, const boost::shared_ptr< IWORKText > &content, unsigned columnSpan, unsigned rowSpan, const boost::optional< IWORKFormula > &formula, const IWORKStylePtr_t &style, IWORKCellType type)
Definition: IWORKTableRecorder.cpp:340
libetonyek::IWORKTableRecorder::setDefaultCellStyle
void setDefaultCellStyle(IWORKTable::CellType type, const IWORKStylePtr_t &style)
Definition: IWORKTableRecorder.cpp:350
libetonyek::IWORKTableRecorder::IWORKTableRecorder
IWORKTableRecorder()
Definition: IWORKTableRecorder.cpp:293
libetonyek::IWORKToken::style
Definition: IWORKToken.h:254
libetonyek::IWORKGridLineList_t
std::vector< IWORKGridLine_t > IWORKGridLineList_t
Definition: IWORKTypes.h:102
libetonyek::IWORKToken::rows
Definition: IWORKToken.h:231
libetonyek::IWORKTableRecorder::setBorders
void setBorders(const IWORKGridLineList_t &verticalLines, const IWORKGridLineList_t &horizontalLines)
Definition: IWORKTableRecorder.cpp:335
libetonyek::IWORKTableRecorder::setDefaultLayoutStyle
void setDefaultLayoutStyle(IWORKTable::CellType type, const IWORKStylePtr_t &style)
Definition: IWORKTableRecorder.cpp:355
libetonyek::IWORKTableRecorder
Definition: IWORKTableRecorder.h:25
libetonyek::IWORKColumnSizes_t
std::deque< double > IWORKColumnSizes_t
Definition: IWORKTypes_fwd.h:23
libetonyek::IWORKRowSizes_t
std::deque< double > IWORKRowSizes_t
Definition: IWORKTypes_fwd.h:25
libetonyek::IWORKToken::columns
Definition: IWORKToken.h:82
libetonyek::IWORKTableRecorder::setHeaders
void setHeaders(unsigned headerColumns, unsigned headerRows, unsigned footerRows)
Definition: IWORKTableRecorder.cpp:310
libetonyek::IWORKTableRecorder::setSizes
void setSizes(const IWORKColumnSizes_t &columnSizes, const IWORKRowSizes_t &rowSizes)
Definition: IWORKTableRecorder.cpp:330
IWORKTable.h
libetonyek::IWORKToken::column
Definition: IWORKToken.h:80
IWORKTypes.h
libetonyek::IWORKTable
Definition: IWORKTable.h:28
libetonyek::IWORKTableRecorder::insertCoveredCell
void insertCoveredCell(unsigned column, unsigned row)
Definition: IWORKTableRecorder.cpp:345
libetonyek::IWORKToken::type
Definition: IWORKToken.h:281
libetonyek::IWORKTableRecorder::setDefaultParagraphStyle
void setDefaultParagraphStyle(IWORKTable::CellType type, const IWORKStylePtr_t &style)
Definition: IWORKTableRecorder.cpp:360
libetonyek::IWORKCellType
IWORKCellType
Definition: IWORKEnum.h:70
libetonyek::IWORKTableRecorder::replay
void replay(IWORKTable &table) const
Definition: IWORKTableRecorder.cpp:298