GreatWksGraph Class Reference documentation

Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | Friends | List of all members
GreatWksGraph Class Reference

the main class to read the graphic part of a HanMac Word-J file More...

`#include <GreatWksGraph.hxx>`

## Public Member Functions
| GreatWksGraph (GreatWksDocument &document)
| constructor More...
virtual | ~GreatWksGraph ()
| destructor More...
int | version () const
| returns the file version More...
int | numPages () const
| returns the number of pages More...

## Protected Member Functions
bool | sendPageGraphics ()
| try to send the page graphic More...
void | flushExtra ()
| sends the data which have not yet been sent to the listener More...
bool | readPatterns (MWAWEntry const &entry)
| read a pattern list block ( PAT# resource block ) More...
bool | readPalettes (MWAWEntry const &entry)
| read a list of color and maybe patterns ( PlTT resource block: v2 ) More...
bool | sendPageFrames (GreatWksGraphInternal::Zone const &zone)
| try to send all data corresponding to a zone More...
bool | sendFrame (shared_ptr< GreatWksGraphInternal::Frame > frame, GreatWksGraphInternal::Zone const &zone)
| try to send a frame More...
bool | sendGroup (GreatWksGraphInternal::FrameGroup const &group, GreatWksGraphInternal::Zone const &zone, MWAWPosition const &pos)
| try to send a group More...
void | sendGroupChild (GreatWksGraphInternal::FrameGroup const &group, GreatWksGraphInternal::Zone const &zone, MWAWPosition const &pos)
| try to send a group elements by elemenys More...
bool | canCreateGraphic (GreatWksGraphInternal::FrameGroup const &group, GreatWksGraphInternal::Zone const &zone)
| check if we can send a group as graphic More...
void | sendGroup (GreatWksGraphInternal::FrameGroup const &group, GreatWksGraphInternal::Zone const &zone, MWAWGraphicListenerPtr &listener)
| send the group as a graphic zone More...
bool | sendTextbox (GreatWksGraphInternal::FrameText const &text, GreatWksGraphInternal::Zone const &zone, MWAWPosition const &pos)
| try to send a textbox More...
bool | sendTextboxAsGraphic (MWAWBox2f const &box, GreatWksGraphInternal::FrameText const &text, MWAWGraphicStyle const &style, MWAWListenerPtr listener)
| try to send a textbox via a graphiclistener More...
bool | sendTextbox (MWAWEntry const &entry, MWAWListenerPtr listener)
| try to send the textbox text (via the mainParser) More...
bool | sendPicture (MWAWEntry const &entry, MWAWPosition pos)
| try to send a picture More...
bool | sendShape (GreatWksGraphInternal::FrameShape const &graph, GreatWksGraphInternal::Zone const &zone, MWAWPosition const &pos)
| try to send a basic picture More...
bool | readGraphicZone ()
| try to read the graphic zone ( draw file or end of v2 text file) More...
bool | isGraphicZone ()
| return true if this corresponds to a graphic zone More...
bool | findGraphicZone ()
| try to find the beginning of the next graphic zone More...
bool | isPageFrames ()
| check if a zone is or not a page frame zone More...
bool | readPageFrames ()
| try to read a list of page frame ( picture, texture or basic ) More...
shared_ptr< GreatWksGraphInternal::Frame > | readFrameHeader ()
| try to read a basic frame header More...
bool | readFrameExtraData (GreatWksGraphInternal::Frame &frame, int id, long endPos=-1)
| try to read a frame extra data zone More...
bool | readStyle (MWAWGraphicStyle &style)
| try to read a zone style More...
bool | readLineFormat (std::string &extra)
| try to read a line format style? in v1 More...
bool | readFrameExtraDataRec (GreatWksGraphInternal::Zone &zone, int id, std::set< int > &seens, long endPos=-1)
| try to read a frame extra data zone recursively ( draw method) More...
bool | checkGraph (GreatWksGraphInternal::Zone &zone, int id, std::set< int > &seens)
| check if the graph of zones is ok (ie. does not form loop) More...

## Protected Attributes
GreatWksDocument & | m_document
| the document More...
MWAWParserStatePtr | m_parserState
| the parser state More...
shared_ptr< GreatWksGraphInternal::State > | m_state
| the state More...
MWAWParser * | m_mainParser
| the main parser; More...

## Private Member Functions
| GreatWksGraph (GreatWksGraph const &orig)
GreatWksGraph & | operator= (GreatWksGraph const &orig)

## Friends
class | GreatWksDocument
class | GreatWksParser
class | GreatWksDBParser
class | GreatWksDRParser
class | GreatWksSSParser
class | GreatWksGraphInternal::SubDocument

## Detailed Description

the main class to read the graphic part of a HanMac Word-J file

## Constructor & Destructor Documentation

## § GreatWksGraph() [1/2]

GreatWksGraph::GreatWksGraph | ( | GreatWksDocument & | document | ) |
| explicit

constructor

## § ~GreatWksGraph()

GreatWksGraph::~GreatWksGraph | ( |  | ) |
| virtual

destructor

## § GreatWksGraph() [2/2]

GreatWksGraph::GreatWksGraph | ( | GreatWksGraph const & | orig | ) |
| private

## Member Function Documentation

## § canCreateGraphic()

bool GreatWksGraph::canCreateGraphic | ( | GreatWksGraphInternal::FrameGroup const & | group,
|  | GreatWksGraphInternal::Zone const & | zone
| ) |  |
| protected

check if we can send a group as graphic

Referenced by sendGroupChild().

## § checkGraph()

bool GreatWksGraph::checkGraph | ( | GreatWksGraphInternal::Zone & | zone,
|  | int | id,
|  | std::set< int > & | seens
| ) |  |
| protected

check if the graph of zones is ok (ie. does not form loop)

Referenced by readPageFrames().

## § findGraphicZone()

bool GreatWksGraph::findGraphicZone | ( |  | ) |
| protected

try to find the beginning of the next graphic zone

Referenced by readGraphicZone().

## § flushExtra()

void GreatWksGraph::flushExtra | ( |  | ) |
| protected

sends the data which have not yet been sent to the listener

## § isGraphicZone()

bool GreatWksGraph::isGraphicZone | ( |  | ) |
| protected

return true if this corresponds to a graphic zone

Referenced by findGraphicZone(), and readGraphicZone().

## § isPageFrames()

bool GreatWksGraph::isPageFrames | ( |  | ) |
| protected

check if a zone is or not a page frame zone

Referenced by isGraphicZone(), and readPageFrames().

## § numPages()

int GreatWksGraph::numPages | ( |  | ) | const

returns the number of pages

## § operator=()

GreatWksGraph& GreatWksGraph::operator= | ( | GreatWksGraph const & | orig | ) |
| private

## § readFrameExtraData()

bool GreatWksGraph::readFrameExtraData | ( | GreatWksGraphInternal::Frame & | frame,
|  | int | id,
|  | long | endPos = `-1`
| ) |  |
| protected

try to read a frame extra data zone

Referenced by readFrameExtraDataRec(), and readPageFrames().

## § readFrameExtraDataRec()

bool GreatWksGraph::readFrameExtraDataRec | ( | GreatWksGraphInternal::Zone & | zone,
|  | int | id,
|  | std::set< int > & | seens,
|  | long | endPos = `-1`
| ) |  |
| protected

try to read a frame extra data zone recursively ( draw method)

Referenced by readPageFrames().

## § readFrameHeader()

shared_ptr< GreatWksGraphInternal::Frame > GreatWksGraph::readFrameHeader | ( |  | ) |
| protected

try to read a basic frame header

Referenced by readPageFrames().

## § readGraphicZone()

bool GreatWksGraph::readGraphicZone | ( |  | ) |
| protected

try to read the graphic zone ( draw file or end of v2 text file)

## § readLineFormat()

bool GreatWksGraph::readLineFormat | ( | std::string & | extra | ) |
| protected

try to read a line format style? in v1

Referenced by readGraphicZone(), readPageFrames(), and readStyle().

## § readPageFrames()

bool GreatWksGraph::readPageFrames | ( |  | ) |
| protected

try to read a list of page frame ( picture, texture or basic )

Referenced by readGraphicZone().

## § readPalettes()

bool GreatWksGraph::readPalettes | ( | MWAWEntry const & | entry | ) |
| protected

read a list of color and maybe patterns ( PlTT resource block: v2 )

## § readPatterns()

bool GreatWksGraph::readPatterns | ( | MWAWEntry const & | entry | ) |
| protected

read a pattern list block ( PAT# resource block )

## § readStyle()

bool GreatWksGraph::readStyle | ( | MWAWGraphicStyle & | style | ) |
| protected

try to read a zone style

Referenced by readGraphicZone(), and readPageFrames().

## § sendFrame()

bool GreatWksGraph::sendFrame | ( | shared_ptr< GreatWksGraphInternal::Frame > | frame,
|  | GreatWksGraphInternal::Zone const & | zone
| ) |  |
| protected

try to send a frame

Referenced by sendGroupChild(), and sendPageFrames().

## § sendGroup() [1/2]

bool GreatWksGraph::sendGroup | ( | GreatWksGraphInternal::FrameGroup const & | group,
|  | GreatWksGraphInternal::Zone const & | zone,
|  | MWAWPosition const & | pos
| ) |  |
| protected

try to send a group

Referenced by sendFrame(), sendGroup(), and sendGroupChild().

## § sendGroup() [2/2]

void GreatWksGraph::sendGroup | ( | GreatWksGraphInternal::FrameGroup const & | group,
|  | GreatWksGraphInternal::Zone const & | zone,
|  | MWAWGraphicListenerPtr & | listener
| ) |  |
| protected

send the group as a graphic zone

## § sendGroupChild()

void GreatWksGraph::sendGroupChild | ( | GreatWksGraphInternal::FrameGroup const & | group,
|  | GreatWksGraphInternal::Zone const & | zone,
|  | MWAWPosition const & | pos
| ) |  |
| protected

try to send a group elements by elemenys

Referenced by sendGroup().

## § sendPageFrames()

bool GreatWksGraph::sendPageFrames | ( | GreatWksGraphInternal::Zone const & | zone | ) |
| protected

try to send all data corresponding to a zone

Referenced by flushExtra(), and sendPageGraphics().

## § sendPageGraphics()

bool GreatWksGraph::sendPageGraphics | ( |  | ) |
| protected

try to send the page graphic

## § sendPicture()

bool GreatWksGraph::sendPicture | ( | MWAWEntry const & | entry,
|  | MWAWPosition | pos
| ) |  |
| protected

try to send a picture

Referenced by sendFrame().

## § sendShape()

bool GreatWksGraph::sendShape | ( | GreatWksGraphInternal::FrameShape const & | graph,
|  | GreatWksGraphInternal::Zone const & | zone,
|  | MWAWPosition const & | pos
| ) |  |
| protected

try to send a basic picture

Referenced by sendFrame().

## § sendTextbox() [1/2]

bool GreatWksGraph::sendTextbox | ( | GreatWksGraphInternal::FrameText const & | text,
|  | GreatWksGraphInternal::Zone const & | zone,
|  | MWAWPosition const & | pos
| ) |  |
| protected

try to send a textbox

Referenced by sendFrame().

## § sendTextbox() [2/2]

bool GreatWksGraph::sendTextbox | ( | MWAWEntry const & | entry,
|  | MWAWListenerPtr | listener
| ) |  |
| protected

try to send the textbox text (via the mainParser)

## § sendTextboxAsGraphic()

bool GreatWksGraph::sendTextboxAsGraphic | ( | MWAWBox2f const & | box,
|  | GreatWksGraphInternal::FrameText const & | text,
|  | MWAWGraphicStyle const & | style,
|  | MWAWListenerPtr | listener
| ) |  |
| protected

try to send a textbox via a graphiclistener

Referenced by sendGroup(), sendGroupChild(), and sendTextbox().

## § version()

int GreatWksGraph::version | ( |  | ) | const

returns the file version

Referenced by findGraphicZone(), isGraphicZone(), isPageFrames(), readFrameHeader(), readGraphicZone(), readPageFrames(), and readStyle().

## Friends And Related Function Documentation

## § GreatWksDBParser

friend class GreatWksDBParser
| friend

## § GreatWksDocument

friend class GreatWksDocument
| friend

## § GreatWksDRParser

friend class GreatWksDRParser
| friend

## § GreatWksGraphInternal::SubDocument

friend class GreatWksGraphInternal::SubDocument
| friend

## § GreatWksParser

friend class GreatWksParser
| friend

## § GreatWksSSParser

friend class GreatWksSSParser
| friend

## Member Data Documentation

## § m_document

GreatWksDocument& GreatWksGraph::m_document
| protected

the document

Referenced by canCreateGraphic(), sendGroupChild(), and sendTextbox().

## § m_mainParser

MWAWParser* GreatWksGraph::m_mainParser
| protected

the main parser;

Referenced by sendFrame().

## § m_parserState

MWAWParserStatePtr GreatWksGraph::m_parserState
| protected

the parser state

Referenced by findGraphicZone(), flushExtra(), isGraphicZone(), isPageFrames(), readFrameExtraData(), readFrameExtraDataRec(), readFrameHeader(), readGraphicZone(), readLineFormat(), readPageFrames(), readPalettes(), readPatterns(), readStyle(), sendFrame(), sendGroupChild(), sendPageFrames(), sendPageGraphics(), sendPicture(), sendShape(), sendTextbox(), sendTextboxAsGraphic(), and version().

## § m_state

shared_ptr<GreatWksGraphInternal::State> GreatWksGraph::m_state
| protected

the state

Referenced by flushExtra(), numPages(), readPageFrames(), and sendPageGraphics().

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

- GreatWksGraph.hxx
- GreatWksGraph.cxx