MWAWSpreadsheetListener Class Referencefinal

This class contents the main functions needed to create a spreadsheet processing Document. More...

#include <MWAWSpreadsheetListener.hxx>

Inheritance diagram for MWAWSpreadsheetListener:
MWAWListener

Public Member Functions

 MWAWSpreadsheetListener (MWAWParserState &parserState, std::vector< MWAWPageSpan > const &pageList, librevenge::RVNGSpreadsheetInterface *documentInterface)
 constructor
 
 MWAWSpreadsheetListener (MWAWParserState &parserState, MWAWBox2f const &box, librevenge::RVNGSpreadsheetInterface *documentInterface)
 simplified constructor (can be used for a embedded spreadsheet with one page).
 
 ~MWAWSpreadsheetListener () final
 destructor
 
Type getType () const final
 returns the listener type
 
void setDocumentMetaData (librevenge::RVNGPropertyList const &metadata) final
 sets the documents metadata
 
void setDocumentLanguage (std::string const &locale) final
 sets the documents language
 
void startDocument () final
 starts the document
 
void endDocument (bool sendDelayedSubDoc=true) final
 ends the document
 
bool isDocumentStarted () const final
 returns true if a document is opened
 
void handleSubDocument (MWAWSubDocumentPtr const &subDocument, libmwaw::SubDocumentType subDocumentType) final
 function called to add a subdocument
 
bool isSubDocumentOpened (libmwaw::SubDocumentType &subdocType) const final
 returns try if a subdocument is open

 
bool openFrame (MWAWPosition const &pos, MWAWGraphicStyle const &style=MWAWGraphicStyle::emptyStyle()) final
 tries to open a frame
 
void closeFrame () final
 tries to close a frame
 
bool openGroup (MWAWPosition const &pos) final
 open a group (not implemented)
 
void closeGroup () final
 close a group (not implemented)
 
bool canWriteText () const final
 returns true if we can add text data
 
bool isPageSpanOpened () const final
 returns true if a page is opened
 
MWAWPageSpan const & getPageSpan () final
 returns the current page span
 
bool insertHeader (MWAWSubDocumentPtr const &subDocument, librevenge::RVNGPropertyList const &extras) final
 insert a header
 
bool insertFooter (MWAWSubDocumentPtr const &subDocument, librevenge::RVNGPropertyList const &extras) final
 insert a footer
 
bool isHeaderFooterOpened () const final
 returns true if the header/footer is open
 
void openSheet (std::vector< float > const &colWidth, librevenge::RVNGUnit unit, std::vector< int > const &repeatColWidthNumber=std::vector< int >(), std::string const &name="")
 opens a sheet
 
void closeSheet ()
 closes this sheet
 
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 )
 
void closeSheetRow ()
 closes this row
 
void openSheetCell (MWAWCell const &cell, MWAWCellContent const &content, int numRepeated=1)
 open a cell
 
void closeSheetCell ()
 close a cell
 
void insertChart (MWAWPosition const &pos, MWAWChart &chart, MWAWGraphicStyle const &style=MWAWGraphicStyle::emptyStyle())
 adds a chart in given position
 
void insertChar (uint8_t character) final
 adds a basic character, ..
 
void insertCharacter (unsigned char c) final
 insert a character using the font converter to find the utf8 character
 
int insertCharacter (unsigned char c, MWAWInputStreamPtr &input, long endPos=-1) final
 insert a character using the font converter to find the utf8 character and if needed, input to read extra character.
 
void insertUnicode (uint32_t character) final
 adds an unicode character.
 
void insertUnicodeString (librevenge::RVNGString const &str) final
 adds a unicode string
 
void insertTab () final
 adds a tab
 
void insertEOL (bool softBreak=false) final
 adds an end of line ( by default an hard one)
 
void setFont (MWAWFont const &font) final
 sets the font
 
MWAWFont const & getFont () const final
 returns the actual font
 
bool isParagraphOpened () const final
 returns true if a paragraph or a list is opened
 
void setParagraph (MWAWParagraph const &paragraph) final
 sets the paragraph
 
MWAWParagraph const & getParagraph () const final
 returns the actual paragraph
 
void insertField (MWAWField const &field) final
 adds a field type
 
void openLink (MWAWLink const &link) final
 open a link
 
void closeLink () final
 close a link
 
void insertNote (MWAWNote const &note, MWAWSubDocumentPtr &subDocument) final
 insert a note
 
void insertComment (MWAWSubDocumentPtr &subDocument) final
 adds comment
 
void insertPicture (MWAWPosition const &pos, MWAWEmbeddedObject const &picture, MWAWGraphicStyle const &style=MWAWGraphicStyle::emptyStyle()) final
 adds a picture with potential various representationin given position
 
void insertShape (MWAWPosition const &pos, MWAWGraphicShape const &shape, MWAWGraphicStyle const &style) final
 adds a shape picture in given position
 
void insertTextBox (MWAWPosition const &pos, MWAWSubDocumentPtr const &subDocument, MWAWGraphicStyle const &frameStyle=MWAWGraphicStyle::emptyStyle()) final
 adds a textbox in given position
 
void insertTable (MWAWPosition const &pos, MWAWTable &table, MWAWGraphicStyle const &style=MWAWGraphicStyle::emptyStyle())
 adds a table in given position
 
void openTable (MWAWTable const &table) final
 open a table
 
void closeTable () final
 closes this table
 
void openTableRow (float h, librevenge::RVNGUnit unit, bool headerRow=false) final
 open a row with given height ( if h < 0.0, set min-row-height = -h )
 
void closeTableRow () final
 closes this row
 
void openTableCell (MWAWCell const &cell) final
 open a cell
 
void closeTableCell () final
 close a cell
 
void addEmptyTableCell (MWAWVec2i const &pos, MWAWVec2i span=MWAWVec2i(1, 1)) final
 add empty cell
 
bool canOpenSectionAddBreak () const final
 returns true if we can add open a section, add page break, ...
 
bool isSectionOpened () const final
 returns true if a section is opened
 
MWAWSection const & getSection () const final
 returns the actual section
 
bool openSection (MWAWSection const &section) final
 open a section if possible
 
bool closeSection () final
 close a section
 
void insertBreak (BreakType breakType) final
 inserts a break type: ColumBreak, PageBreak, ..
 
- Public Member Functions inherited from MWAWListener
virtual ~MWAWListener ()
 destructor
 
virtual Type getType () const =0
 returns the listener type
 
virtual bool canWriteText () const =0
 returns true if we can add text data
 
virtual void setDocumentMetaData (librevenge::RVNGPropertyList const &metadata)=0
 sets the documents metadata
 
virtual void setDocumentLanguage (std::string const &locale)=0
 sets the documents language
 
virtual void startDocument ()=0
 starts the document
 
virtual bool isDocumentStarted () const =0
 returns true if a document is opened
 
virtual void endDocument (bool sendDelayedSubDoc=true)=0
 ends the document
 
virtual bool isPageSpanOpened () const =0
 returns true if a page is opened
 
virtual MWAWPageSpan const & getPageSpan ()=0
 returns the current page span
 
virtual bool insertHeader (MWAWSubDocumentPtr const &subDocument, librevenge::RVNGPropertyList const &extras)=0
 insert a header (interaction with MWAWPageSpan which fills the parameters for openHeader)
 
virtual bool insertFooter (MWAWSubDocumentPtr const &subDocument, librevenge::RVNGPropertyList const &extras)=0
 insert a footer (interaction with MWAWPageSpan which fills the parameters for openFooter)
 
virtual bool isHeaderFooterOpened () const =0
 returns true if the header/footer is open
 
virtual void insertChar (uint8_t character)=0
 adds a basic character, ..
 
virtual void insertCharacter (unsigned char c)=0
 insert a character using the font converter to find the utf8 character
 
virtual int insertCharacter (unsigned char c, MWAWInputStreamPtr &input, long endPos=-1)=0
 insert a character using the font converter to find the utf8 character and if needed, input to read extra character.
 
virtual void insertUnicode (uint32_t character)=0
 adds an unicode character.
 
virtual void insertUnicodeString (librevenge::RVNGString const &str)=0
 adds a unicode string
 
virtual void insertTab ()=0
 adds a tab
 
virtual void insertEOL (bool softBreak=false)=0
 adds an end of line ( by default an hard one)
 
virtual void setFont (MWAWFont const &font)=0
 sets the font
 
virtual MWAWFont const & getFont () const =0
 returns the actual font
 
virtual bool isParagraphOpened () const =0
 returns true if a paragraph or a list is opened
 
virtual void setParagraph (MWAWParagraph const &paragraph)=0
 sets the paragraph
 
virtual MWAWParagraph const & getParagraph () const =0
 returns the actual paragraph
 
virtual void insertField (MWAWField const &field)=0
 adds a field type
 
virtual void openLink (MWAWLink const &link)=0
 open a link
 
virtual void closeLink ()=0
 close a link
 
virtual void openTable (MWAWTable const &table)=0
 open a table
 
virtual void closeTable ()=0
 closes this table
 
virtual void openTableRow (float h, librevenge::RVNGUnit unit, bool headerRow=false)=0
 open a row with given height ( if h < 0.0, set min-row-height = -h )
 
virtual void closeTableRow ()=0
 closes this row
 
virtual void openTableCell (MWAWCell const &cell)=0
 open a cell
 
virtual void closeTableCell ()=0
 close a cell
 
virtual void addEmptyTableCell (MWAWVec2i const &pos, MWAWVec2i span=MWAWVec2i(1, 1))=0
 add empty cell
 
virtual bool canOpenSectionAddBreak () const =0
 returns true if we can add open a section, add page break, ...
 
virtual bool isSectionOpened () const =0
 returns true if a section is opened
 
virtual MWAWSection const & getSection () const =0
 returns the actual section
 
virtual bool openSection (MWAWSection const &section)=0
 open a section if possible
 
virtual bool closeSection ()=0
 close a section
 
virtual void insertBreak (BreakType breakType)=0
 inserts a break type: ColumBreak, PageBreak, ..
 
virtual void insertNote (MWAWNote const &note, MWAWSubDocumentPtr &subDocument)=0
 insert a note
 
virtual void insertComment (MWAWSubDocumentPtr &subDocument)=0
 adds comment
 
virtual void insertPicture (MWAWPosition const &pos, MWAWEmbeddedObject const &picture, MWAWGraphicStyle const &style=MWAWGraphicStyle::emptyStyle())=0
 adds a picture with various representationin given position.
 
virtual void insertShape (MWAWPosition const &pos, MWAWGraphicShape const &shape, MWAWGraphicStyle const &style)=0
 adds a shape picture in given position
 
virtual void insertTextBox (MWAWPosition const &pos, MWAWSubDocumentPtr const &subDocument, MWAWGraphicStyle const &frameStyle=MWAWGraphicStyle::emptyStyle())=0
 adds a textbox in given position
 
virtual void insertTextBoxInShape (MWAWPosition const &pos, MWAWSubDocumentPtr const &subDocument, MWAWGraphicShape const &, MWAWGraphicStyle const &frameStyle=MWAWGraphicStyle::emptyStyle())
 adds a textbox in given position
 
virtual bool openFrame (MWAWPosition const &pos, MWAWGraphicStyle const &style=MWAWGraphicStyle::emptyStyle())=0
 low level: tries to open a frame
 
virtual void closeFrame ()=0
 low level: tries to close the last opened frame
 
virtual bool openGroup (MWAWPosition const &pos)=0
 low level: tries to open a group
 
virtual void closeGroup ()=0
 low level: tries to close the last opened group
 
virtual void handleSubDocument (MWAWSubDocumentPtr const &subDocument, libmwaw::SubDocumentType subDocumentType)=0
 low level: function called to add a subdocument
 
virtual bool isSubDocumentOpened (libmwaw::SubDocumentType &subdocType) const =0
 returns true if a subdocument is open

 

Protected Member Functions

void _openPageSpan (bool sendHeaderFooters=true)
 does open a new page (low level)
 
void _closePageSpan ()
 does close a page (low level)
 
void _startSubDocument ()
 
void _endSubDocument ()
 
void _handleFrameParameters (librevenge::RVNGPropertyList &propList, MWAWPosition const &pos)
 
void _openParagraph ()
 
void _closeParagraph ()
 
void _resetParagraphState (const bool isListElement=false)
 
void _openListElement ()
 open a list level
 
void _closeListElement ()
 close a list level
 
void _changeList ()
 update the list so that it corresponds to the actual level
 
int _getListId () const
 low level: find a list id which corresponds to actual list and a change of level.
 
void _openSpan ()
 
void _closeSpan ()
 
void _flushText ()
 
void _flushDeferredTabs ()
 
std::shared_ptr< MWAWSpreadsheetListenerInternal::State_pushParsingState ()
 creates a new parsing state (copy of the actual state)
 
void _popParsingState ()
 resets the previous parsing state
 

Protected Attributes

std::shared_ptr< MWAWSpreadsheetListenerInternal::DocumentStatem_ds
 the main parse state
 
std::shared_ptr< MWAWSpreadsheetListenerInternal::Statem_ps
 the actual local parse state
 
std::vector< std::shared_ptr< MWAWSpreadsheetListenerInternal::State > > m_psStack
 stack of local state
 
MWAWParserStatem_parserState
 the parser state
 
librevenge::RVNGSpreadsheetInterface * m_documentInterface
 the document interface
 

Private Member Functions

 MWAWSpreadsheetListener (const MWAWSpreadsheetListener &)
 copy constructor (unimplemented)
 
MWAWSpreadsheetListeneroperator= (const MWAWSpreadsheetListener &)
 operator= (unimplemented)
 

Additional Inherited Members

- Public Types inherited from MWAWListener
enum  Type { Graphic , Presentation , Spreadsheet , Text }
 the listener type More...
 
enum  BreakType { PageBreak =0 , SoftPageBreak , ColumnBreak }
 the different break type More...
 

Detailed Description

This class contents the main functions needed to create a spreadsheet processing Document.

Constructor & Destructor Documentation

◆ MWAWSpreadsheetListener() [1/3]

MWAWSpreadsheetListener::MWAWSpreadsheetListener ( MWAWParserState parserState,
std::vector< MWAWPageSpan > const &  pageList,
librevenge::RVNGSpreadsheetInterface *  documentInterface 
)

constructor

◆ MWAWSpreadsheetListener() [2/3]

MWAWSpreadsheetListener::MWAWSpreadsheetListener ( MWAWParserState parserState,
MWAWBox2f const &  box,
librevenge::RVNGSpreadsheetInterface *  documentInterface 
)

simplified constructor (can be used for a embedded spreadsheet with one page).

Note
the box coordinates must be given in point.

◆ ~MWAWSpreadsheetListener()

MWAWSpreadsheetListener::~MWAWSpreadsheetListener ( )
final

destructor

◆ MWAWSpreadsheetListener() [3/3]

MWAWSpreadsheetListener::MWAWSpreadsheetListener ( const MWAWSpreadsheetListener )
private

copy constructor (unimplemented)

Member Function Documentation

◆ _changeList()

void MWAWSpreadsheetListener::_changeList ( )
protected

update the list so that it corresponds to the actual level

Referenced by _endSubDocument(), _openSpan(), closeTableCell(), endDocument(), and insertNote().

◆ _closeListElement()

void MWAWSpreadsheetListener::_closeListElement ( )
protected

close a list level

Referenced by _closeParagraph().

◆ _closePageSpan()

void MWAWSpreadsheetListener::_closePageSpan ( )
protected

does close a page (low level)

Referenced by endDocument().

◆ _closeParagraph()

void MWAWSpreadsheetListener::_closeParagraph ( )
protected

◆ _closeSpan()

void MWAWSpreadsheetListener::_closeSpan ( )
protected

◆ _endSubDocument()

void MWAWSpreadsheetListener::_endSubDocument ( )
protected

◆ _flushDeferredTabs()

void MWAWSpreadsheetListener::_flushDeferredTabs ( )
protected

◆ _flushText()

void MWAWSpreadsheetListener::_flushText ( )
protected

◆ _getListId()

int MWAWSpreadsheetListener::_getListId ( ) const
protected

low level: find a list id which corresponds to actual list and a change of level.

Note
called when the list id is not set

Referenced by _changeList().

◆ _handleFrameParameters()

void MWAWSpreadsheetListener::_handleFrameParameters ( librevenge::RVNGPropertyList &  propList,
MWAWPosition const &  pos 
)
protected

Referenced by insertShape(), openFrame(), and openGroup().

◆ _openListElement()

void MWAWSpreadsheetListener::_openListElement ( )
protected

open a list level

Referenced by _openSpan().

◆ _openPageSpan()

void MWAWSpreadsheetListener::_openPageSpan ( bool  sendHeaderFooters = true)
protected

does open a new page (low level)

Referenced by endDocument(), getPageSpan(), and openSheet().

◆ _openParagraph()

void MWAWSpreadsheetListener::_openParagraph ( )
protected

◆ _openSpan()

◆ _popParsingState()

void MWAWSpreadsheetListener::_popParsingState ( )
protected

resets the previous parsing state

Referenced by closeGroup(), closeLink(), closeSheet(), closeTable(), handleSubDocument(), insertChart(), and insertTable().

◆ _pushParsingState()

std::shared_ptr< MWAWSpreadsheetListenerInternal::State > MWAWSpreadsheetListener::_pushParsingState ( )
protected

creates a new parsing state (copy of the actual state)

Returns
the old one

Referenced by handleSubDocument(), insertChart(), insertTable(), openGroup(), openLink(), openSheet(), and openTable().

◆ _resetParagraphState()

void MWAWSpreadsheetListener::_resetParagraphState ( const bool  isListElement = false)
protected

Referenced by _openListElement(), and _openParagraph().

◆ _startSubDocument()

void MWAWSpreadsheetListener::_startSubDocument ( )
protected

◆ addEmptyTableCell()

void MWAWSpreadsheetListener::addEmptyTableCell ( MWAWVec2i const &  pos,
MWAWVec2i  span = MWAWVec2i(1,1) 
)
finalvirtual

add empty cell

Implements MWAWListener.

◆ canOpenSectionAddBreak()

bool MWAWSpreadsheetListener::canOpenSectionAddBreak ( ) const
inlinefinalvirtual

returns true if we can add open a section, add page break, ...

Implements MWAWListener.

◆ canWriteText()

bool MWAWSpreadsheetListener::canWriteText ( ) const
finalvirtual

returns true if we can add text data

Implements MWAWListener.

Referenced by insertComment(), and insertNote().

◆ closeFrame()

void MWAWSpreadsheetListener::closeFrame ( )
finalvirtual

tries to close a frame

Implements MWAWListener.

Referenced by insertChart(), insertPicture(), insertTable(), and insertTextBox().

◆ closeGroup()

void MWAWSpreadsheetListener::closeGroup ( )
finalvirtual

close a group (not implemented)

Implements MWAWListener.

◆ closeLink()

void MWAWSpreadsheetListener::closeLink ( )
finalvirtual

close a link

Implements MWAWListener.

◆ closeSection()

bool MWAWSpreadsheetListener::closeSection ( )
finalvirtual

close a section

Implements MWAWListener.

◆ closeSheet()

void MWAWSpreadsheetListener::closeSheet ( )

closes this sheet

Referenced by endDocument().

◆ closeSheetCell()

void MWAWSpreadsheetListener::closeSheetCell ( )

close a cell

Referenced by openSheetCell().

◆ closeSheetRow()

void MWAWSpreadsheetListener::closeSheetRow ( )

closes this row

◆ closeTable()

void MWAWSpreadsheetListener::closeTable ( )
finalvirtual

closes this table

Implements MWAWListener.

Referenced by _endSubDocument(), and endDocument().

◆ closeTableCell()

void MWAWSpreadsheetListener::closeTableCell ( )
finalvirtual

close a cell

Implements MWAWListener.

Referenced by addEmptyTableCell(), and openTableCell().

◆ closeTableRow()

void MWAWSpreadsheetListener::closeTableRow ( )
finalvirtual

closes this row

Implements MWAWListener.

◆ endDocument()

void MWAWSpreadsheetListener::endDocument ( bool  sendDelayedSubDoc = true)
finalvirtual

ends the document

Implements MWAWListener.

◆ getFont()

MWAWFont const & MWAWSpreadsheetListener::getFont ( ) const
finalvirtual

returns the actual font

Implements MWAWListener.

◆ getPageSpan()

MWAWPageSpan const & MWAWSpreadsheetListener::getPageSpan ( )
finalvirtual

returns the current page span

Note
this forces the opening of a new page if no page is opened.

Implements MWAWListener.

◆ getParagraph()

MWAWParagraph const & MWAWSpreadsheetListener::getParagraph ( ) const
finalvirtual

returns the actual paragraph

Implements MWAWListener.

◆ getSection()

MWAWSection const & MWAWSpreadsheetListener::getSection ( ) const
finalvirtual

returns the actual section

Implements MWAWListener.

◆ getType()

Type MWAWSpreadsheetListener::getType ( ) const
inlinefinalvirtual

returns the listener type

Implements MWAWListener.

◆ handleSubDocument()

void MWAWSpreadsheetListener::handleSubDocument ( MWAWSubDocumentPtr const &  subDocument,
libmwaw::SubDocumentType  subDocumentType 
)
finalvirtual

function called to add a subdocument

Implements MWAWListener.

Referenced by insertComment(), insertFooter(), insertHeader(), insertNote(), and insertTextBox().

◆ insertBreak()

void MWAWSpreadsheetListener::insertBreak ( MWAWSpreadsheetListener::BreakType  breakType)
finalvirtual

inserts a break type: ColumBreak, PageBreak, ..

Implements MWAWListener.

◆ insertChar()

void MWAWSpreadsheetListener::insertChar ( uint8_t  character)
finalvirtual

adds a basic character, ..

Implements MWAWListener.

Referenced by insertCharacter().

◆ insertCharacter() [1/2]

void MWAWSpreadsheetListener::insertCharacter ( unsigned char  c)
finalvirtual

insert a character using the font converter to find the utf8 character

Implements MWAWListener.

◆ insertCharacter() [2/2]

int MWAWSpreadsheetListener::insertCharacter ( unsigned char  c,
MWAWInputStreamPtr input,
long  endPos = -1 
)
finalvirtual

insert a character using the font converter to find the utf8 character and if needed, input to read extra character.

Returns
the number of extra character read

Implements MWAWListener.

◆ insertChart()

void MWAWSpreadsheetListener::insertChart ( MWAWPosition const &  pos,
MWAWChart chart,
MWAWGraphicStyle const &  style = MWAWGraphicStyle::emptyStyle() 
)

adds a chart in given position

◆ insertComment()

void MWAWSpreadsheetListener::insertComment ( MWAWSubDocumentPtr subDocument)
finalvirtual

adds comment

Implements MWAWListener.

◆ insertEOL()

void MWAWSpreadsheetListener::insertEOL ( bool  softBreak = false)
finalvirtual

adds an end of line ( by default an hard one)

Implements MWAWListener.

◆ insertField()

void MWAWSpreadsheetListener::insertField ( MWAWField const &  field)
finalvirtual

adds a field type

Implements MWAWListener.

◆ insertFooter()

bool MWAWSpreadsheetListener::insertFooter ( MWAWSubDocumentPtr const &  subDocument,
librevenge::RVNGPropertyList const &  extras 
)
finalvirtual

insert a footer

Implements MWAWListener.

◆ insertHeader()

bool MWAWSpreadsheetListener::insertHeader ( MWAWSubDocumentPtr const &  subDocument,
librevenge::RVNGPropertyList const &  extras 
)
finalvirtual

insert a header

Implements MWAWListener.

◆ insertNote()

void MWAWSpreadsheetListener::insertNote ( MWAWNote const &  note,
MWAWSubDocumentPtr subDocument 
)
finalvirtual

insert a note

Must not happen excepted in corrupted document, so we do the minimum. Note that we have no choice, either we begin by closing the paragraph, ... or we reprogram handleSubDocument.

Implements MWAWListener.

◆ insertPicture()

void MWAWSpreadsheetListener::insertPicture ( MWAWPosition const &  pos,
MWAWEmbeddedObject const &  picture,
MWAWGraphicStyle const &  style = MWAWGraphicStyle::emptyStyle() 
)
finalvirtual

adds a picture with potential various representationin given position

Implements MWAWListener.

◆ insertShape()

void MWAWSpreadsheetListener::insertShape ( MWAWPosition const &  pos,
MWAWGraphicShape const &  shape,
MWAWGraphicStyle const &  style 
)
finalvirtual

adds a shape picture in given position

Implements MWAWListener.

◆ insertTab()

void MWAWSpreadsheetListener::insertTab ( )
finalvirtual

adds a tab

Implements MWAWListener.

◆ insertTable()

void MWAWSpreadsheetListener::insertTable ( MWAWPosition const &  pos,
MWAWTable table,
MWAWGraphicStyle const &  style = MWAWGraphicStyle::emptyStyle() 
)

adds a table in given position

◆ insertTextBox()

void MWAWSpreadsheetListener::insertTextBox ( MWAWPosition const &  pos,
MWAWSubDocumentPtr const &  subDocument,
MWAWGraphicStyle const &  frameStyle = MWAWGraphicStyle::emptyStyle() 
)
finalvirtual

adds a textbox in given position

Implements MWAWListener.

◆ insertUnicode()

void MWAWSpreadsheetListener::insertUnicode ( uint32_t  character)
finalvirtual

adds an unicode character.

By convention if character=0xfffd(undef), no character is added

Implements MWAWListener.

Referenced by insertChar(), and insertCharacter().

◆ insertUnicodeString()

void MWAWSpreadsheetListener::insertUnicodeString ( librevenge::RVNGString const &  str)
finalvirtual

adds a unicode string

Implements MWAWListener.

Referenced by insertField().

◆ isDocumentStarted()

bool MWAWSpreadsheetListener::isDocumentStarted ( ) const
finalvirtual

returns true if a document is opened

Implements MWAWListener.

◆ isHeaderFooterOpened()

bool MWAWSpreadsheetListener::isHeaderFooterOpened ( ) const
finalvirtual

returns true if the header/footer is open

Implements MWAWListener.

◆ isPageSpanOpened()

bool MWAWSpreadsheetListener::isPageSpanOpened ( ) const
finalvirtual

returns true if a page is opened

Implements MWAWListener.

◆ isParagraphOpened()

bool MWAWSpreadsheetListener::isParagraphOpened ( ) const
finalvirtual

returns true if a paragraph or a list is opened

Implements MWAWListener.

◆ isSectionOpened()

bool MWAWSpreadsheetListener::isSectionOpened ( ) const
inlinefinalvirtual

returns true if a section is opened

Implements MWAWListener.

◆ isSubDocumentOpened()

bool MWAWSpreadsheetListener::isSubDocumentOpened ( libmwaw::SubDocumentType subdocType) const
finalvirtual

returns try if a subdocument is open

Implements MWAWListener.

◆ openFrame()

bool MWAWSpreadsheetListener::openFrame ( MWAWPosition const &  pos,
MWAWGraphicStyle const &  style = MWAWGraphicStyle::emptyStyle() 
)
finalvirtual

tries to open a frame

Implements MWAWListener.

Referenced by insertChart(), insertPicture(), insertTable(), and insertTextBox().

◆ openGroup()

bool MWAWSpreadsheetListener::openGroup ( MWAWPosition const &  pos)
finalvirtual

open a group (not implemented)

Implements MWAWListener.

◆ openLink()

void MWAWSpreadsheetListener::openLink ( MWAWLink const &  link)
finalvirtual

open a link

Implements MWAWListener.

◆ openSection()

bool MWAWSpreadsheetListener::openSection ( MWAWSection const &  section)
finalvirtual

open a section if possible

Implements MWAWListener.

◆ openSheet()

void MWAWSpreadsheetListener::openSheet ( std::vector< float > const &  colWidth,
librevenge::RVNGUnit  unit,
std::vector< int > const &  repeatColWidthNumber = std::vector<int>(),
std::string const &  name = "" 
)

opens a sheet

Note
if defWidth is positive, add 1000 columns with size defWidth

◆ openSheetCell()

void MWAWSpreadsheetListener::openSheetCell ( MWAWCell const &  cell,
MWAWCellContent const &  content,
int  numRepeated = 1 
)

open a cell

◆ openSheetRow()

void MWAWSpreadsheetListener::openSheetRow ( float  h,
librevenge::RVNGUnit  unit,
int  numRepeated = 1 
)

open a row with given height ( if h < 0.0, set min-row-height = -h )

◆ openTable()

void MWAWSpreadsheetListener::openTable ( MWAWTable const &  table)
finalvirtual

open a table

Implements MWAWListener.

◆ openTableCell()

void MWAWSpreadsheetListener::openTableCell ( MWAWCell const &  cell)
finalvirtual

open a cell

Implements MWAWListener.

◆ openTableRow()

void MWAWSpreadsheetListener::openTableRow ( float  h,
librevenge::RVNGUnit  unit,
bool  headerRow = false 
)
finalvirtual

open a row with given height ( if h < 0.0, set min-row-height = -h )

Implements MWAWListener.

◆ operator=()

MWAWSpreadsheetListener & MWAWSpreadsheetListener::operator= ( const MWAWSpreadsheetListener )
private

operator= (unimplemented)

◆ setDocumentLanguage()

void MWAWSpreadsheetListener::setDocumentLanguage ( std::string const &  locale)
finalvirtual

sets the documents language

Implements MWAWListener.

◆ setDocumentMetaData()

void MWAWSpreadsheetListener::setDocumentMetaData ( librevenge::RVNGPropertyList const &  metadata)
finalvirtual

sets the documents metadata

Implements MWAWListener.

◆ setFont()

void MWAWSpreadsheetListener::setFont ( MWAWFont const &  font)
finalvirtual

sets the font

Implements MWAWListener.

Referenced by _flushDeferredTabs().

◆ setParagraph()

void MWAWSpreadsheetListener::setParagraph ( MWAWParagraph const &  paragraph)
finalvirtual

sets the paragraph

Implements MWAWListener.

◆ startDocument()

void MWAWSpreadsheetListener::startDocument ( )
finalvirtual

starts the document

Implements MWAWListener.

Referenced by _openPageSpan().

Member Data Documentation

◆ m_documentInterface

◆ m_ds

◆ m_parserState

MWAWParserState& MWAWSpreadsheetListener::m_parserState
protected

◆ m_ps

◆ m_psStack

std::vector<std::shared_ptr<MWAWSpreadsheetListenerInternal::State> > MWAWSpreadsheetListener::m_psStack
protected

stack of local state

Referenced by _popParsingState(), and _pushParsingState().


The documentation for this class was generated from the following files:

Generated on Wed May 3 2023 07:18:29 for libmwaw by doxygen 1.9.6