34 #ifndef MWAW_GRAPHIC_LISTENER_H
35 #define MWAW_GRAPHIC_LISTENER_H
39 #include <librevenge/librevenge.h>
108 bool openLayer(librevenge::RVNGString
const &name);
212 void openTableRow(
float h, librevenge::RVNGUnit unit,
bool headerRow=
false);
290 shared_ptr<MWAWGraphicListenerInternal::GraphicState>
m_ds;
292 shared_ptr<MWAWGraphicListenerInternal::State>
m_ps;
294 std::vector<shared_ptr<MWAWGraphicListenerInternal::State> >
m_psStack;
void closeGroup()
close a group
Definition: MWAWGraphicListener.cxx:1326
void insertChar(uint8_t character)
adds a basic character, ..
Definition: MWAWGraphicListener.cxx:202
void insertNote(MWAWNote const ¬e, MWAWSubDocumentPtr &subDocument)
insert a note
Definition: MWAWGraphicListener.cxx:957
void _openParagraph()
Definition: MWAWGraphicListener.cxx:604
void insertTextBox(MWAWPosition const &pos, MWAWSubDocumentPtr subDocument, MWAWGraphicStyle const &style)
adds a textbox in given position
Definition: MWAWGraphicListener.cxx:1055
bool openFrame(MWAWPosition const &pos, MWAWGraphicStyle const &style=MWAWGraphicStyle::emptyStyle())
store the position and the style (which will be needed further to insert a textbox or a table with op...
Definition: MWAWGraphicListener.cxx:1270
bool openLayer(librevenge::RVNGString const &name)
open a layer
Definition: MWAWGraphicListener.cxx:1337
void openTableCell(MWAWCell const &cell)
open a cell
Definition: MWAWGraphicListener.cxx:1235
A class which defines the page properties.
Definition: MWAWPageSpan.hxx:95
void _flushText()
Definition: MWAWGraphicListener.cxx:815
void openTable(MWAWTable const &table)
open a table (using the last parameters of openFrame for the position )
Definition: MWAWGraphicListener.cxx:1131
void endDocument(bool delayed=true)
ends the actual document
Definition: MWAWGraphicListener.cxx:440
a link
Definition: libmwaw_internal.hxx:386
bool openSection(MWAWSection const §ion)
open a section if possible
Definition: MWAWGraphicListener.cxx:906
bool canOpenSectionAddBreak() const
returns true if we can add open a section, add page break, ...
Definition: MWAWGraphicListener.hxx:225
bool isSubDocumentOpened(libmwaw::SubDocumentType &subdocType) const
returns try if a subdocument is open
Definition: MWAWGraphicListener.cxx:1599
Definition: MWAWListener.hxx:56
Internal and low level namespace to define the states of MWAWGraphicListener.
Definition: MWAWGraphicListener.cxx:62
bool openMasterPage(MWAWPageSpan &masterPage)
opens a master page
Definition: MWAWGraphicListener.cxx:491
void _resetParagraphState(const bool isListElement=false)
Definition: MWAWGraphicListener.cxx:647
void insertTab()
adds a tab
Definition: MWAWGraphicListener.cxx:312
a structure used to define a picture style
Definition: MWAWGraphicStyle.hxx:47
This class contains the code needed to create Graphic document.
Definition: MWAWGraphicListener.hxx:59
SubDocumentType
Definition: libmwaw_internal.hxx:172
void startDocument()
starts a new document
Definition: MWAWGraphicListener.cxx:429
void insertGroup(MWAWBox2f const &bdbox, MWAWSubDocumentPtr subDocument)
adds a group: ie.
Definition: MWAWGraphicListener.cxx:1091
a class used to recreate the table structure using cell informations, ....
Definition: MWAWTable.hxx:51
librevenge::RVNGDrawingInterface * m_documentInterface
the document interface
Definition: MWAWGraphicListener.hxx:298
void closeLink()
close a link
Definition: MWAWGraphicListener.cxx:416
MWAWVec2< int > MWAWVec2i
MWAWVec2 of int.
Definition: libmwaw_internal.hxx:774
void insertComment(MWAWSubDocumentPtr &subDocument)
adds comment
Definition: MWAWGraphicListener.cxx:939
void _openListElement()
open a list level
Definition: MWAWGraphicListener.cxx:656
Type
the listener type
Definition: MWAWListener.hxx:56
bool closeSection()
close a section
Definition: MWAWGraphicListener.hxx:239
void _handleFrameParameters(librevenge::RVNGPropertyList &propList, MWAWPosition const &pos, MWAWGraphicStyle const &style)
adds in propList the frame parameters.
Definition: MWAWGraphicListener.cxx:1375
bool isSectionOpened() const
returns true if a section is opened
Definition: MWAWGraphicListener.hxx:230
a structure used to define a cell and its format
Definition: MWAWCell.hxx:52
void _endSubDocument()
Definition: MWAWGraphicListener.cxx:1613
void handleSubDocument(MWAWSubDocumentPtr subDocument, libmwaw::SubDocumentType subDocumentType)
function called to add a subdocument
Definition: MWAWGraphicListener.hxx:93
shared_ptr< MWAWGraphicListenerInternal::State > _pushParsingState()
creates a new parsing state (copy of the actual state)
Definition: MWAWGraphicListener.cxx:1631
shared_ptr< MWAWSubDocument > MWAWSubDocumentPtr
a smart pointer of MWAWSubDocument
Definition: libmwaw_internal.hxx:510
MWAWGraphicListener(MWAWParserState &parserState, std::vector< MWAWPageSpan > const &pageList, librevenge::RVNGDrawingInterface *documentInterface)
constructor
Definition: MWAWGraphicListener.cxx:177
void setFont(MWAWFont const &font)
sets the font
Definition: MWAWGraphicListener.cxx:326
void insertBreak(BreakType breakType)
inserts a break type: ColumBreak, PageBreak, ..
Definition: MWAWGraphicListener.cxx:912
void insertShape(MWAWPosition const &pos, MWAWGraphicShape const &shape, MWAWGraphicStyle const &style)
adds a shape picture in given position
Definition: MWAWGraphicListener.cxx:980
void closeTableCell()
close a cell
Definition: MWAWGraphicListener.cxx:1252
void closeLayer()
close a layer
Definition: MWAWGraphicListener.cxx:1364
Type getType() const
returns the listener type
Definition: MWAWGraphicListener.hxx:72
void insertUnicodeString(librevenge::RVNGString const &str)
adds a unicode string
Definition: MWAWGraphicListener.cxx:283
bool openGroup(MWAWPosition const &pos)
open a group
Definition: MWAWGraphicListener.cxx:1301
Class to store font.
Definition: MWAWFont.hxx:43
int _getListId() const
low level: find a list id which corresponds to actual list and a change of level. ...
Definition: MWAWGraphicListener.cxx:695
MWAWGraphicListener & operator=(const MWAWGraphicListener &)
void insertUnicode(uint32_t character)
adds an unicode character.
Definition: MWAWGraphicListener.cxx:270
a class to define the parser state
Definition: MWAWParser.hxx:49
BreakType
the different break type
Definition: MWAWListener.hxx:58
void insertEOL(bool softBreak=false)
adds an end of line ( by default an hard one)
Definition: MWAWGraphicListener.cxx:293
void addEmptyTableCell(MWAWVec2i const &pos, MWAWVec2i span=MWAWVec2i(1, 1))
add empty cell
Definition: MWAWGraphicListener.cxx:1216
MWAWVec2< float > MWAWVec2f
MWAWVec2 of float.
Definition: libmwaw_internal.hxx:778
void _closePageSpan(bool masterPage=false)
does close a page (low level)
Definition: MWAWGraphicListener.cxx:565
void closeMasterPage()
close a master page
Definition: MWAWGraphicListener.hxx:116
void closeFrame()
close a frame
Definition: MWAWGraphicListener.cxx:1292
shared_ptr< MWAWGraphicListenerInternal::GraphicState > m_ds
the actual global state
Definition: MWAWGraphicListener.hxx:290
void insertPicture(MWAWPosition const &pos, MWAWEmbeddedObject const &picture, MWAWGraphicStyle const &style=MWAWGraphicStyle::emptyStyle())
adds a picture with potential various representationin given position
Definition: MWAWGraphicListener.cxx:1020
std::vector< shared_ptr< MWAWGraphicListenerInternal::State > > m_psStack
stack of local state
Definition: MWAWGraphicListener.hxx:294
void _closeListElement()
close a list level
Definition: MWAWGraphicListener.cxx:682
void setDocumentLanguage(std::string locale)
sets the documents language
Definition: MWAWGraphicListener.cxx:460
void _popParsingState()
resets the previous parsing state
Definition: MWAWGraphicListener.cxx:1639
small class use to define a embedded object
Definition: libmwaw_internal.hxx:419
void handleSubDocument(MWAWVec2f const &orig, MWAWSubDocumentPtr subDocument, libmwaw::SubDocumentType subDocumentType)
function called to add a subdocument and modify the origin
Definition: MWAWGraphicListener.cxx:1544
a class which stores section properties
Definition: MWAWSection.hxx:45
MWAWParagraph const & getParagraph() const
returns the actual paragraph
Definition: MWAWGraphicListener.cxx:367
void insertCharacter(unsigned char c)
insert a character using the font converter to find the utf8 character
Definition: MWAWGraphicListener.cxx:216
shared_ptr< MWAWInputStream > MWAWInputStreamPtr
a smart pointer of MWAWInputStream
Definition: libmwaw_internal.hxx:496
bool insertFooter(MWAWSubDocumentPtr subDocument, librevenge::RVNGPropertyList const &extras)
insert a footer
Definition: MWAWGraphicListener.cxx:872
bool isPageSpanOpened() const
returns true if a page is opened
Definition: MWAWGraphicListener.cxx:479
a structure used to define a picture shape
Definition: MWAWGraphicShape.hxx:45
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: MWAWGraphicListener.cxx:1185
bool isHeaderFooterOpened() const
returns true if the header/footer is open
Definition: MWAWGraphicListener.cxx:846
virtual ~MWAWGraphicListener()
destructor
Definition: MWAWGraphicListener.cxx:195
MWAWParserState & m_parserState
the parser state
Definition: MWAWGraphicListener.hxx:296
class to store the paragraph properties
Definition: MWAWParagraph.hxx:81
void insertTable(MWAWPosition const &pos, MWAWTable &table, MWAWGraphicStyle const &style=MWAWGraphicStyle::emptyStyle())
adds a table in given position
Definition: MWAWGraphicListener.cxx:1106
a field
Definition: libmwaw_internal.hxx:363
void closeTableRow()
closes this row
Definition: MWAWGraphicListener.cxx:1206
void closeTable()
closes this table
Definition: MWAWGraphicListener.cxx:1171
void setParagraph(MWAWParagraph const ¶graph)
sets the paragraph
Definition: MWAWGraphicListener.cxx:356
void _openPageSpan(bool sendHeaderFooters=true)
does open a new page (low level)
Definition: MWAWGraphicListener.cxx:514
void _openSpan()
Definition: MWAWGraphicListener.cxx:769
a note
Definition: libmwaw_internal.hxx:400
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
bool isDocumentStarted() const
returns true if a document is opened
Definition: MWAWGraphicListener.cxx:466
void openLink(MWAWLink const &link)
open a link
Definition: MWAWGraphicListener.cxx:396
void _closeParagraph()
Definition: MWAWGraphicListener.cxx:625
void _startSubDocument()
Definition: MWAWGraphicListener.cxx:1607
void _changeList()
update the list so that it corresponds to the actual level
Definition: MWAWGraphicListener.cxx:712
bool canWriteText() const
returns true if a text zone is opened
Definition: MWAWGraphicListener.cxx:471
void _closeSpan()
Definition: MWAWGraphicListener.cxx:796
MWAWSection const & getSection() const
returns the actual section
Definition: MWAWGraphicListener.cxx:899
MWAWPageSpan const & getPageSpan()
returns the current page span
Definition: MWAWGraphicListener.cxx:484
MWAWFont const & getFont() const
returns the actual font
Definition: MWAWGraphicListener.cxx:346
bool isParagraphOpened() const
returns true if a paragraph or a list is opened
Definition: MWAWGraphicListener.cxx:351
bool insertHeader(MWAWSubDocumentPtr subDocument, librevenge::RVNGPropertyList const &extras)
insert a header
Definition: MWAWGraphicListener.cxx:851
shared_ptr< MWAWGraphicListenerInternal::State > m_ps
the actual local parse state
Definition: MWAWGraphicListener.hxx:292
static MWAWGraphicStyle emptyStyle()
returns an empty style.
Definition: MWAWGraphicStyle.hxx:269
void insertField(MWAWField const &field)
adds a field type
Definition: MWAWGraphicListener.cxx:375