34 #ifndef MWAW_LISTENER_H 35 #define MWAW_LISTENER_H 39 #include <librevenge/librevenge.h> 76 virtual void endDocument(
bool sendDelayedSubDoc=
true) = 0;
115 virtual void insertEOL(
bool softBreak=
false)=0;
148 virtual void openTableRow(
float h, librevenge::RVNGUnit unit,
bool headerRow=
false) = 0;
192 static bool first=
true;
194 MWAW_DEBUG_MSG((
"MWAWListener::insertTextBoxInShape: umimplemented, revert to basic insertTextBox\n"));
virtual bool canOpenSectionAddBreak() const =0
returns true if we can add open a section, add page break, ...
virtual void startDocument()=0
starts the document
virtual void endDocument(bool sendDelayedSubDoc=true)=0
ends the document
virtual void insertCharacter(unsigned char c)=0
insert a character using the font converter to find the utf8 character
virtual bool openSection(MWAWSection const §ion)=0
open a section if possible
virtual bool isSectionOpened() const =0
returns true if a section is opened
virtual bool isParagraphOpened() const =0
returns true if a paragraph or a list is opened
A class which defines the page properties.
Definition: MWAWPageSpan.hxx:98
virtual void closeTableCell()=0
close a cell
a link
Definition: libmwaw_internal.hxx:430
Definition: MWAWListener.hxx:58
virtual void insertUnicode(uint32_t character)=0
adds an unicode character.
Definition: MWAWListener.hxx:56
virtual void setParagraph(MWAWParagraph const ¶graph)=0
sets the paragraph
virtual void openLink(MWAWLink const &link)=0
open a link
virtual void insertComment(MWAWSubDocumentPtr &subDocument)=0
adds comment
virtual void closeGroup()=0
low level: tries to close the last opened group
virtual void openTable(MWAWTable const &table)=0
open a table
virtual void setFont(MWAWFont const &font)=0
sets the font
a structure used to define a picture style
Definition: MWAWGraphicStyle.hxx:47
SubDocumentType
Definition: libmwaw_internal.hxx:188
Definition: MWAWListener.hxx:58
a class used to recreate the table structure using cell informations, ....
Definition: MWAWTable.hxx:51
virtual bool isHeaderFooterOpened() const =0
returns true if the header/footer is open
MWAWVec2< int > MWAWVec2i
MWAWVec2 of int.
Definition: libmwaw_internal.hxx:838
virtual void addEmptyTableCell(MWAWVec2i const &pos, MWAWVec2i span=MWAWVec2i(1, 1))=0
add empty cell
virtual MWAWFont const & getFont() const =0
returns the actual font
virtual bool isDocumentStarted() const =0
returns true if a document is opened
virtual void insertChar(uint8_t character)=0
adds a basic character, ..
Type
the listener type
Definition: MWAWListener.hxx:56
a structure used to define a cell and its format
Definition: MWAWCell.hxx:52
virtual void setDocumentLanguage(std::string const &locale)=0
sets the documents language
virtual bool isPageSpanOpened() const =0
returns true if a page is opened
virtual bool insertFooter(MWAWSubDocumentPtr const &subDocument, librevenge::RVNGPropertyList const &extras)=0
insert a footer (interaction with MWAWPageSpan which fills the parameters for openFooter) ...
virtual void insertUnicodeString(librevenge::RVNGString const &str)=0
adds a unicode string
virtual bool openGroup(MWAWPosition const &pos)=0
low level: tries to open a group
Class to store font.
Definition: MWAWFont.hxx:43
virtual void insertBreak(BreakType breakType)=0
inserts a break type: ColumBreak, PageBreak, ..
#define MWAW_DEBUG_MSG(M)
Definition: libmwaw_internal.hxx:129
BreakType
the different break type
Definition: MWAWListener.hxx:58
virtual void insertPicture(MWAWPosition const &pos, MWAWEmbeddedObject const &picture, MWAWGraphicStyle const &style=MWAWGraphicStyle::emptyStyle())=0
adds a picture with various representationin given position.
virtual bool canWriteText() const =0
returns true if we can add text data
virtual void closeLink()=0
close a link
virtual void insertTextBoxInShape(MWAWPosition const &pos, MWAWSubDocumentPtr const &subDocument, MWAWGraphicShape const &, MWAWGraphicStyle const &frameStyle=MWAWGraphicStyle::emptyStyle())
adds a textbox in given position
Definition: MWAWListener.hxx:188
virtual void closeFrame()=0
low level: tries to close the last opened frame
virtual void closeTableRow()=0
closes this row
virtual void insertEOL(bool softBreak=false)=0
adds an end of line ( by default an hard one)
virtual MWAWPageSpan const & getPageSpan()=0
returns the current page span
virtual MWAWSection const & getSection() const =0
returns the actual section
virtual void insertNote(MWAWNote const ¬e, MWAWSubDocumentPtr &subDocument)=0
insert a note
small class use to define a embedded object
Definition: libmwaw_internal.hxx:467
Definition: MWAWListener.hxx:58
virtual bool insertHeader(MWAWSubDocumentPtr const &subDocument, librevenge::RVNGPropertyList const &extras)=0
insert a header (interaction with MWAWPageSpan which fills the parameters for openHeader) ...
virtual void insertShape(MWAWPosition const &pos, MWAWGraphicShape const &shape, MWAWGraphicStyle const &style)=0
adds a shape picture in given position
a class which stores section properties
Definition: MWAWSection.hxx:45
Definition: MWAWListener.hxx:56
Definition: MWAWListener.hxx:56
virtual void openTableCell(MWAWCell const &cell)=0
open a cell
virtual void insertField(MWAWField const &field)=0
adds a field type
virtual MWAWParagraph const & getParagraph() const =0
returns the actual paragraph
virtual void setDocumentMetaData(librevenge::RVNGPropertyList const &metadata)=0
sets the documents metadata
std::shared_ptr< MWAWInputStream > MWAWInputStreamPtr
a smart pointer of MWAWInputStream
Definition: libmwaw_internal.hxx:551
virtual ~MWAWListener()
destructor
Definition: MWAWListener.cxx:36
Definition: MWAWListener.hxx:56
a structure used to define a picture shape
Definition: MWAWGraphicShape.hxx:45
virtual bool isSubDocumentOpened(libmwaw::SubDocumentType &subdocType) const =0
returns true if a subdocument is open
class to store the paragraph properties
Definition: MWAWParagraph.hxx:84
a field
Definition: libmwaw_internal.hxx:399
virtual bool openFrame(MWAWPosition const &pos, MWAWGraphicStyle const &style=MWAWGraphicStyle::emptyStyle())=0
low level: tries to open a frame
virtual void insertTab()=0
adds a tab
virtual void insertTextBox(MWAWPosition const &pos, MWAWSubDocumentPtr const &subDocument, MWAWGraphicStyle const &frameStyle=MWAWGraphicStyle::emptyStyle())=0
adds a textbox in given position
a note
Definition: libmwaw_internal.hxx:445
virtual void closeTable()=0
closes this table
Class to define the position of an object (textbox, picture, ..) in the document. ...
Definition: MWAWPosition.hxx:47
This class contains a virtual interface to all listener.
Definition: MWAWListener.hxx:49
std::shared_ptr< MWAWSubDocument > MWAWSubDocumentPtr
a smart pointer of MWAWSubDocument
Definition: libmwaw_internal.hxx:565
virtual Type getType() const =0
returns the listener type
virtual void handleSubDocument(MWAWSubDocumentPtr const &subDocument, libmwaw::SubDocumentType subDocumentType)=0
low level: function called to add a subdocument
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 )
static MWAWGraphicStyle emptyStyle()
returns an empty style.
Definition: MWAWGraphicStyle.hxx:477
virtual bool closeSection()=0
close a section