40 #ifndef STOFF_SPREADSHEET_LISTENER_H
41 #define STOFF_SPREADSHEET_LISTENER_H
45 #include <librevenge/librevenge.h>
116 bool openHeader(librevenge::RVNGPropertyList
const &extras);
118 bool openFooter(librevenge::RVNGPropertyList
const &extras);
132 void openSheet(std::vector<float>
const &colWidth, librevenge::RVNGUnit unit,
133 std::vector<int>
const &repeatColWidthNumber=std::vector<int>(), librevenge::RVNGString
const &name=
"");
137 void openSheetRow(
float h, librevenge::RVNGUnit unit,
int numRepeated=1);
224 void openTableRow(
float h, librevenge::RVNGUnit unit,
bool headerRow=
false);
296 shared_ptr<STOFFSpreadsheetListenerInternal::DocumentState>
m_ds;
298 shared_ptr<STOFFSpreadsheetListenerInternal::State>
m_ps;
300 std::vector<shared_ptr<STOFFSpreadsheetListenerInternal::State> >
m_psStack;
void _flushDeferredTabs()
Definition: STOFFSpreadsheetListener.cxx:900
shared_ptr< STOFFSpreadsheetListenerInternal::DocumentState > m_ds
the main parse state
Definition: STOFFSpreadsheetListener.hxx:296
bool insertFooterRegion(STOFFSubDocumentPtr subDocument, librevenge::RVNGString const &which)
insert a footer
Definition: STOFFSpreadsheetListener.cxx:657
void insertComment(STOFFSubDocumentPtr &subDocument, librevenge::RVNGString const &creator="", librevenge::RVNGString const &date="")
adds comment
Definition: STOFFSpreadsheetListener.cxx:994
void insertEOL(bool softBreak=false)
adds an end of line ( by default an hard one)
Definition: STOFFSpreadsheetListener.cxx:320
void handleSubDocument(STOFFSubDocumentPtr subDocument, libstoff::SubDocumentType subDocumentType)
function called to add a subdocument
Definition: STOFFSpreadsheetListener.cxx:1218
virtual ~STOFFSpreadsheetListener()
destructor
Definition: STOFFSpreadsheetListener.cxx:223
bool isSubDocumentOpened(libstoff::SubDocumentType &subdocType) const
returns try if a subdocument is open
Definition: STOFFSpreadsheetListener.cxx:1280
void insertTable(STOFFPosition const &pos, STOFFTable &table, STOFFGraphicStyle const &style=STOFFGraphicStyle())
adds a table in given position
Definition: STOFFSpreadsheetListener.cxx:1510
bool closeSection()
close a section
Definition: STOFFSpreadsheetListener.cxx:701
void closeFrame()
tries to close a frame
Definition: STOFFSpreadsheetListener.cxx:1199
STOFFPageSpan const & getPageSpan()
returns the current page span
Definition: STOFFSpreadsheetListener.cxx:535
void _handleFrameParameters(librevenge::RVNGPropertyList &propList, STOFFPosition const &pos)
Definition: STOFFSpreadsheetListener.cxx:1210
STOFFSpreadsheetListener(STOFFListManagerPtr listManager, std::vector< STOFFPageSpan > const &pageList, librevenge::RVNGSpreadsheetInterface *documentInterface)
constructor
Definition: STOFFSpreadsheetListener.cxx:217
STOFFParagraph const & getParagraph() const
returns the actual paragraph
Definition: STOFFSpreadsheetListener.cxx:409
bool canOpenSectionAddBreak() const
returns true if we can add open a section, add page break, ...
Definition: STOFFSpreadsheetListener.hxx:236
void closeSheet()
closes this sheet
Definition: STOFFSpreadsheetListener.cxx:1347
Definition: STOFFListener.hxx:57
bool insertHeaderRegion(STOFFSubDocumentPtr subDocument, librevenge::RVNGString const &which)
insert a header
Definition: STOFFSpreadsheetListener.cxx:616
a structure used to define a cell and its format
Definition: STOFFCell.hxx:53
bool openFrame(STOFFPosition const &pos, STOFFGraphicStyle const &style=STOFFGraphicStyle())
tries to open a frame
Definition: STOFFSpreadsheetListener.cxx:1130
void openTableCell(STOFFCell const &cell)
open a cell
Definition: STOFFSpreadsheetListener.cxx:1654
bool isFontStyleDefined(librevenge::RVNGString const &name) const
check if a font style with a display name is already defined
Definition: STOFFSpreadsheetListener.cxx:248
Type
the listener type
Definition: STOFFListener.hxx:57
void openTableRow(float h, librevenge::RVNGUnit unit, bool headerRow=false)
open a row with given height ( if h < 0.0, set min-row-height = -h )
Definition: STOFFSpreadsheetListener.cxx:1604
small class use to define a sheet cell content
Definition: STOFFCell.hxx:226
void insertBreak(BreakType breakType)
inserts a break type: ColumBreak, PageBreak, ..
Definition: STOFFSpreadsheetListener.cxx:356
void insertUnicode(uint32_t character)
adds an unicode character.
Definition: STOFFSpreadsheetListener.cxx:286
STOFFSection const & getSection() const
returns the actual section
Definition: STOFFSpreadsheetListener.cxx:689
bool closeHeader()
close a header
Definition: STOFFSpreadsheetListener.cxx:634
a link
Definition: libstaroffice_internal.hxx:365
bool isSectionOpened() const
returns true if a section is opened
Definition: STOFFSpreadsheetListener.hxx:241
Internal and low level namespace to define the states of STOFFSpreadsheetListener.
Definition: STOFFSpreadsheetListener.cxx:73
void openSheet(std::vector< float > const &colWidth, librevenge::RVNGUnit unit, std::vector< int > const &repeatColWidthNumber=std::vector< int >(), librevenge::RVNGString const &name="")
open a sheet
Definition: STOFFSpreadsheetListener.cxx:1310
a class used to recreate the table structure using cell informations, ....
Definition: STOFFTable.hxx:51
void _closeListElement()
close a list level
Definition: STOFFSpreadsheetListener.cxx:781
void insertChar(uint8_t character)
adds a basic character, ..
Definition: STOFFSpreadsheetListener.cxx:271
void _changeList()
update the list so that it corresponds to the actual level
Definition: STOFFSpreadsheetListener.cxx:811
void setParagraph(STOFFParagraph const ¶graph)
sets the paragraph
Definition: STOFFSpreadsheetListener.cxx:398
void setDocumentMetaData(const librevenge::RVNGPropertyList &list)
sets the document meta data
Definition: STOFFSpreadsheetListener.cxx:472
void insertTab()
adds a tab
Definition: STOFFSpreadsheetListener.cxx:340
void _closeSpan()
Definition: STOFFSpreadsheetListener.cxx:886
int _getListId() const
low level: find a list id which corresponds to actual list and a change of level. ...
Definition: STOFFSpreadsheetListener.cxx:794
void endDocument(bool sendDelayedSubDoc=true)
ends the document
Definition: STOFFSpreadsheetListener.cxx:497
void closeSheetCell()
close a cell
Definition: STOFFSpreadsheetListener.cxx:1497
a note
Definition: libstaroffice_internal.hxx:379
bool canWriteText() const
returns true if we can add text data
Definition: STOFFSpreadsheetListener.cxx:266
void openSheetCell(STOFFCell const &cell, STOFFCellContent const &content, int numRepeated=1)
open a cell
Definition: STOFFSpreadsheetListener.cxx:1391
void insertUnicodeString(librevenge::RVNGString const &str)
adds a unicode string
Definition: STOFFSpreadsheetListener.cxx:308
bool isParagraphStyleDefined(librevenge::RVNGString const &name) const
check if a paragraph style with a display name is already defined
Definition: STOFFSpreadsheetListener.cxx:258
class to store the paragraph properties
Definition: STOFFParagraph.hxx:47
std::vector< shared_ptr< STOFFSpreadsheetListenerInternal::State > > m_psStack
stack of local state
Definition: STOFFSpreadsheetListener.hxx:300
void insertField(STOFFField const &field)
adds a field type
Definition: STOFFSpreadsheetListener.cxx:417
void insertPicture(STOFFPosition const &pos, STOFFEmbeddedObject const &picture, STOFFGraphicStyle const &style=STOFFGraphicStyle())
adds a picture with potential various representationin given position
Definition: STOFFSpreadsheetListener.cxx:1047
void _openPageSpan(bool sendHeaderFooters=true)
does open a new page (low level)
Definition: STOFFSpreadsheetListener.cxx:543
librevenge::RVNGSpreadsheetInterface * m_documentInterface
the document interface
Definition: STOFFSpreadsheetListener.hxx:302
void setFont(STOFFFont const &font)
sets the font
Definition: STOFFSpreadsheetListener.cxx:381
This class contents the main functions needed to create a spreadsheet processing Document.
Definition: STOFFSpreadsheetListener.hxx:64
void _openSpan()
Definition: STOFFSpreadsheetListener.cxx:865
shared_ptr< STOFFListManager > STOFFListManagerPtr
a smart pointer of STOFFListManager
Definition: libstaroffice_internal.hxx:478
a class used to store a chart associated to a spreadsheet ....
Definition: STOFFChart.hxx:56
bool isHeaderFooterOpened() const
returns true if the header/footer is open
Definition: STOFFSpreadsheetListener.cxx:599
void _openParagraph()
Definition: STOFFSpreadsheetListener.cxx:710
STOFFSpreadsheetListener & operator=(const STOFFSpreadsheetListener &)
operator= (unimplemented)
void _popParsingState()
resets the previous parsing state
Definition: STOFFSpreadsheetListener.cxx:1702
SubDocumentType
Definition: libstaroffice_internal.hxx:175
shared_ptr< STOFFSubDocument > STOFFSubDocumentPtr
a smart pointer of STOFFSubDocument
Definition: libstaroffice_internal.hxx:484
a class which stores section properties
Definition: STOFFSection.hxx:45
void closeGroup()
close a group (not implemented)
Definition: STOFFSpreadsheetListener.cxx:1126
a field
Definition: libstaroffice_internal.hxx:353
void closeSheetRow()
closes this row
Definition: STOFFSpreadsheetListener.cxx:1381
void closeTableCell()
close a cell
Definition: STOFFSpreadsheetListener.cxx:1671
shared_ptr< STOFFSpreadsheetListenerInternal::State > _pushParsingState()
creates a new parsing state (copy of the actual state)
Definition: STOFFSpreadsheetListener.cxx:1691
void _openListElement()
open a list level
Definition: STOFFSpreadsheetListener.cxx:759
a structure used to define a picture shape
Definition: STOFFGraphicShape.hxx:45
small class use to define a embedded object
Definition: libstaroffice_internal.hxx:398
void defineStyle(STOFFFont const &style)
defines a font styles
Definition: STOFFSpreadsheetListener.cxx:227
void openLink(STOFFLink const &link)
open a link
Definition: STOFFSpreadsheetListener.cxx:432
void _startSubDocument()
Definition: STOFFSpreadsheetListener.cxx:1288
void insertTextBox(STOFFPosition const &pos, STOFFSubDocumentPtr subDocument, STOFFGraphicStyle const &frameStyle=STOFFGraphicStyle())
adds a textbox in given position
Definition: STOFFSpreadsheetListener.cxx:1029
void closeLink()
close a link
Definition: STOFFSpreadsheetListener.cxx:452
STOFFVec2< int > STOFFVec2i
STOFFVec2 of int.
Definition: libstaroffice_internal.hxx:748
void insertChart(STOFFPosition const &pos, STOFFChart &chart, STOFFGraphicStyle const &style=STOFFGraphicStyle())
adds a chart in given position
Definition: STOFFSpreadsheetListener.cxx:1540
bool isParagraphOpened() const
returns true if a paragraph or a list is opened
Definition: STOFFSpreadsheetListener.cxx:393
void setDocumentLanguage(std::string locale)
sets the document language
Definition: STOFFSpreadsheetListener.cxx:466
void addEmptyTableCell(STOFFVec2i const &pos, STOFFVec2i span=STOFFVec2i(1, 1))
add empty cell
Definition: STOFFSpreadsheetListener.cxx:1635
void closeTable()
closes this table
Definition: STOFFSpreadsheetListener.cxx:1590
Class to store font.
Definition: STOFFFont.hxx:43
bool openGroup(STOFFPosition const &pos)
open a group (not implemented)
Definition: STOFFSpreadsheetListener.cxx:1120
void startDocument()
starts the document
Definition: STOFFSpreadsheetListener.cxx:484
bool isPageSpanOpened() const
returns true if a page is opened
Definition: STOFFSpreadsheetListener.cxx:530
void openSheetRow(float h, librevenge::RVNGUnit unit, int numRepeated=1)
open a row with given height ( if h < 0.0, set min-row-height = -h )
Definition: STOFFSpreadsheetListener.cxx:1360
shared_ptr< STOFFSpreadsheetListenerInternal::State > m_ps
the actual local parse state
Definition: STOFFSpreadsheetListener.hxx:298
bool openSection(STOFFSection const §ion)
open a section if possible
Definition: STOFFSpreadsheetListener.cxx:695
bool isDocumentStarted() const
returns true if a document is opened
Definition: STOFFSpreadsheetListener.cxx:479
bool isGraphicStyleDefined(librevenge::RVNGString const &name) const
check if a graphic style with a display name is already defined
Definition: STOFFSpreadsheetListener.cxx:253
void _closeParagraph()
Definition: STOFFSpreadsheetListener.cxx:728
bool openHeader(librevenge::RVNGPropertyList const &extras)
open a header (interaction with STOFFPageSpan which fills the parameters for openHeader) ...
Definition: STOFFSpreadsheetListener.cxx:604
A class which defines the page properties.
Definition: STOFFPageSpan.hxx:75
BreakType
the different break type
Definition: STOFFListener.hxx:59
STOFFFont const & getFont() const
returns the actual font
Definition: STOFFSpreadsheetListener.cxx:388
void insertNote(STOFFNote const ¬e, STOFFSubDocumentPtr &subDocument)
insert a note
Definition: STOFFSpreadsheetListener.cxx:941
void _flushText()
Definition: STOFFSpreadsheetListener.cxx:910
void _closePageSpan()
does close a page (low level)
Definition: STOFFSpreadsheetListener.cxx:587
void _resetParagraphState(const bool isListElement=false)
Definition: STOFFSpreadsheetListener.cxx:749
bool openFooter(librevenge::RVNGPropertyList const &extras)
open a footer (interaction with STOFFPageSpan which fills the parameters for openFooter) ...
Definition: STOFFSpreadsheetListener.cxx:645
bool closeFooter()
close a footer
Definition: STOFFSpreadsheetListener.cxx:675
This class contains a virtual interface to all listener.
Definition: STOFFListener.hxx:50
Class to store a graphic style.
Definition: STOFFGraphicStyle.hxx:44
void closeTableRow()
closes this row
Definition: STOFFSpreadsheetListener.cxx:1625
Class to define the position of an object (textbox, picture, ..) in the document. ...
Definition: STOFFPosition.hxx:47
void openTable(STOFFTable const &table)
open a table
Definition: STOFFSpreadsheetListener.cxx:1565
void _endSubDocument()
Definition: STOFFSpreadsheetListener.cxx:1294
Type getType() const
returns the listener type
Definition: STOFFSpreadsheetListener.hxx:73
void insertShape(STOFFGraphicShape const &shape, STOFFGraphicStyle const &style, STOFFPosition const &pos)
adds a shape picture in given position
Definition: STOFFSpreadsheetListener.cxx:1062