- Main Page
- Namespaces
- Classes
- Files

- File List
- File Members

RagTime5ClusterManager.hxx
Go to the documentation of this file.
1 /* -*- Mode: C++; c-default-style: "k&r"; indent-tabs-mode: nil; tab-width: 2; c-basic-offset: 2 -*- */
2
3 /* libmwaw
4 * Version: MPL 2.0 / LGPLv2+
5 *
6 * The contents of this file are subject to the Mozilla Public License Version
7 * 2.0 (the "License"); you may not use this file except in compliance with
8 * the License or as specified alternatively below. You may obtain a copy of
9 * the License at http://www.mozilla.org/MPL/
10 *
11 * Software distributed under the License is distributed on an "AS IS" basis,
12 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
13 * for the specific language governing rights and limitations under the
14 * License.
15 *
16 * Major Contributor(s):
17 * Copyright (C) 2002 William Lachance (wrlach@gmail.com)
18 * Copyright (C) 2002,2004 Marc Maurer (uwog@uwog.net)
19 * Copyright (C) 2004-2006 Fridrich Strba (fridrich.strba@bluewin.ch)
20 * Copyright (C) 2006, 2007 Andrew Ziem
21 * Copyright (C) 2011, 2012 Alonso Laurent (alonso@loria.fr)
22 *
23 *
24 * All Rights Reserved.
25 *
26 * For minor contributions see the git repository.
27 *
28 * Alternatively, the contents of this file may be used under the terms of
29 * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"),
30 * in which case the provisions of the LGPLv2+ are applicable
31 * instead of those above.
32 */
33
34 #ifndef RAG_TIME_5_ZONE_MANAGER
35 # define RAG_TIME_5_ZONE_MANAGER
36
37 #include <map>
38 #include <ostream>
39 #include <sstream>
40 #include <string>
41 #include <vector>
42
43 #include "libmwaw_internal.hxx"
44 #include "MWAWDebug.hxx"
45 #include "MWAWEntry.hxx"
46
47 #include "RagTime5StructManager.hxx"
48
49 class RagTime5Parser;
50 class RagTime5StructManager;
51
52 namespace RagTime5ClusterManagerInternal
53 {
54 struct State;
55 }
56
58 class RagTime5ClusterManager
59 {
60 public:
61 struct Link;
62
63 struct Cluster;
64 struct ClusterRoot;
65 struct ClusterParser;
66
67 friend struct ClusterParser;
68
70 RagTime5ClusterManager(RagTime5Parser &parser);
72 ~RagTime5ClusterManager();
73
75 bool readCluster(RagTime5Zone &zone, ClusterParser &parser, bool warnForUnparsed=true);
77 bool readCluster(RagTime5Zone &zone, shared_ptr<Cluster> &cluster, int type=-1);
79 bool readClusterMainList(ClusterRoot &root, std::vector<int> &list, std::vector<int> const &clusterIdList);
80
82 bool readFieldClusters(Link const &link);
84 bool readUnknownClusterC(Link const &link);
86 int getClusterFileType(RagTime5Zone &zone);
88 int getClusterType(RagTime5Zone &zone, int fileType);
90 bool getClusterBasicHeaderInfo(RagTime5Zone &zone, long &N, long &fSz, long &debHeaderPos);
91
92 // low level
93
95 bool readFieldHeader(RagTime5Zone &zone, long endPos, std::string const &headerName, long &endDataPos, long expectedLVal=-99999);
97 std::string getClusterName(int id);
98
100 struct Link {
102 enum Type { L_ClusterLink,
103 L_LinkDef,
104 L_LongList, L_UnicodeList,
105 L_FieldsList, L_List,
106 L_UnknownClusterC,
107 L_Unknown
108 };
110 Link(Type type=L_Unknown) : m_type(type), m_name(""), m_ids(), m_N(0), m_fieldSize(0), m_longList()
111 {
112 for (int i=0; i<2; ++i)
113 m_fileType[i]=0;
114 }
116 bool empty() const
117 {
118 if (m_type==L_LongList && !m_longList.empty())
119 return false;
120 for (size_t i=0; i<m_ids.size(); ++i)
121 if (m_ids[i]>0) return false;
122 return true;
123 }
125 std::string getZoneName() const
126 {
127 switch (m_type) {
128 case L_ClusterLink:
129 return "clustLink";
130 case L_LinkDef:
131 return "linkDef";
132 case L_LongList:
133 if (!m_name.empty())
134 return m_name;
135 else {
136 std::stringstream s;
137 s << "longList" << m_fieldSize;
138 return s.str();
139 }
140 case L_UnicodeList:
141 return "unicodeListLink";
142 case L_UnknownClusterC:
143 return "unknownClusterC";
144 case L_FieldsList:
145 if (!m_name.empty())
146 return m_name;
147 return "fieldsList[unkn]";
148 case L_List:
149 if (!m_name.empty())
150 return m_name;
151 break;
152 case L_Unknown:
153 default:
154 break;
155 }
156 std::stringstream s;
157 if (m_type==L_List)
158 s << "ListZone";
159 else
160 s << "FixZone";
161 s << std::hex << m_fileType[0] << "_" << m_fileType[1] << std::dec;
162 if (m_fieldSize)
163 s << "_" << m_fieldSize;
164 s << "A";
165 return s.str();
166 }
168 friend std::ostream &operator<<(std::ostream &o, Link const &z)
169 {
170 if (z.empty()) return o;
171 o << z.getZoneName() << ":";
172 size_t numLinks=z.m_ids.size();
173 if (numLinks>1) o << "[";
174 for (size_t i=0; i<numLinks; ++i) {
175 if (z.m_ids[i]<=0)
176 o << "_";
177 else
178 o << "data" << z.m_ids[i] << "A";
179 if (i+1!=numLinks) o << ",";
180 }
181 if (numLinks>1) o << "]";
182 if (z.m_fieldSize&0x8000)
183 o << "[" << std::hex << z.m_fieldSize << std::dec << ":" << z.m_N << "]";
184 else
185 o << "[" << z.m_fieldSize << ":" << z.m_N << "]";
186 return o;
187 }
189 Type m_type;
191 std::string m_name;
193 std::vector<int> m_ids;
195 int m_N;
197 int m_fieldSize;
199 long m_fileType[2];
201 std::vector<long> m_longList;
202 };
203
205 // cluster classes
207
209 struct Cluster {
211 Cluster() : m_type(C_Unknown), m_zoneId(0), m_hiLoEndian(true), m_dataLink(), m_nameLink(), m_fieldClusterLink(),
212 m_conditionFormulaLinks(), m_settingLinks(), m_linksList(), m_clusterIdsList()
213 {
214 }
216 virtual ~Cluster() {}
218 enum Type {
219 C_ColorPattern, C_Fields, C_Layout, C_Pipeline,
220 C_Root, C_Script,
221
222 // the styles
223 C_ColorStyles, C_FormatStyles, C_GraphicStyles, C_TextStyles, C_UnitStyles,
224 // unknown clusters
225 C_ClusterB, C_ClusterC,
226
227 C_Unknown
228 };
230 Type m_type;
232 int m_zoneId;
234 bool m_hiLoEndian;
236 Link m_dataLink;
238 Link m_nameLink;
240 Link m_fieldClusterLink;
242 std::vector<Link> m_conditionFormulaLinks;
244 std::vector<Link> m_settingLinks;
246 std::vector<Link> m_linksList;
248 std::vector<int> m_clusterIdsList;
249 };
250
252 struct ClusterLayout : public Cluster {
254 ClusterLayout() : Cluster(), m_zoneDimensions(), m_pipelineLink(), m_listItemLink()
255 {
256 }
258 virtual ~ClusterLayout() {}
260 std::vector<MWAWVec2f> m_zoneDimensions;
262 Link m_pipelineLink;
264 Link m_listItemLink;
265 };
266
268 struct ClusterRoot : public Cluster {
270 ClusterRoot() : Cluster(), m_graphicTypeLink(), m_docInfoLink(),
271 m_listClusterId(0), m_listClusterName(), m_linkUnknown(), m_fileName("")
272 {
273 for (int i=0; i<8; ++i) m_styleClusterIds[i]=0;
274 for (int i=0; i<1; ++i) m_clusterIds[i]=0;
275 }
277 virtual ~ClusterRoot() {}
279 int m_styleClusterIds[8];
280
282 int m_clusterIds[1];
283
285 Link m_graphicTypeLink;
286
288 Link m_docInfoLink;
289
291 int m_listClusterId;
293 Link m_listClusterName;
295 Link m_listClusterLink[2];
296
298 Link m_linkUnknown;
299
301 librevenge::RVNGString m_fileName;
302 };
303
305 struct ClusterScript : public Cluster {
307 ClusterScript() : Cluster(), m_scriptComment(), m_scriptName("")
308 {
309 }
311 virtual ~ClusterScript() {}
313 Link m_scriptComment;
315 librevenge::RVNGString m_scriptName;
316 };
317
319 // parser class
321
323 struct ClusterParser {
325 ClusterParser(RagTime5ClusterManager &parser, int type, std::string const &zoneName) :
326 m_parser(parser), m_type(type), m_hiLoEndian(true), m_name(zoneName), m_dataId(0), m_link()
327 {
328 }
330 virtual ~ClusterParser() {}
332 virtual shared_ptr<Cluster> getCluster()=0;
334 virtual std::string getZoneName() const
335 {
336 return m_name;
337 }
339 virtual std::string getZoneName(int n, int m=-1) const
340 {
341 std::stringstream s;
342 s << m_name << "-" << n;
343 if (m>=0)
344 s << "-B" << m;
345 return s.str();
346 }
348 virtual void startZone()
349 {
350 }
352 virtual bool parseZone(MWAWInputStreamPtr &/*input*/, long /*fSz*/, int /*N*/, int /*flag*/, libmwaw::DebugStream &/*f*/)
353 {
354 return false;
355 }
357 virtual void endZone()
358 {
359 }
361 virtual bool parseField(RagTime5StructManager::Field const &/*field*/, int /*m*/, libmwaw::DebugStream &/*f*/)
362 {
363 return false;
364 }
365
366 //
367 // some tools
368 //
369
371 bool isANameHeader(long N) const
372 {
373 return (m_hiLoEndian && N==int(0x80000000)) || (!m_hiLoEndian && N==0x8000);
374 }
375
377 bool readLinkHeader(MWAWInputStreamPtr &input, long fSz, Link &link, long(&values)[4], std::string &message);
379 std::string getClusterName(int id);
381 RagTime5ClusterManager &m_parser;
383 int m_type;
385 bool m_hiLoEndian;
387 std::string m_name;
389 int m_dataId;
391 Link m_link;
392 private:
393 ClusterParser(ClusterParser const &orig);
394 ClusterParser &operator=(ClusterParser const &orig);
395 };
396 protected:
398 shared_ptr<RagTime5ClusterManagerInternal::State> m_state;
400 RagTime5Parser &m_mainParser;
402 shared_ptr<RagTime5StructManager> m_structManager;
403 private:
404 RagTime5ClusterManager(RagTime5ClusterManager const &orig);
405 RagTime5ClusterManager operator=(RagTime5ClusterManager const &orig);
406 };
407
408 #endif
409 // vim: set filetype=cpp tabstop=2 shiftwidth=2 cindent autoindent smartindent noexpandtab:
RagTime5ClusterManager::readClusterMainList
bool readClusterMainList(ClusterRoot &root, std::vector< int > &list, std::vector< int > const &clusterIdList)
try to read the cluster root list (in general Data14)
Definition: RagTime5ClusterManager.cxx:197
RagTime5ClusterManager::ClusterScript::m_scriptName
librevenge::RVNGString m_scriptName
the scriptname if known
Definition: RagTime5ClusterManager.hxx:315
RagTime5ClusterManager::Cluster::C_Root
Definition: RagTime5ClusterManager.hxx:220
RagTime5ClusterManager::ClusterRoot::m_clusterIds
int m_clusterIds[1]
other cluster id (unknown cluster b, )
Definition: RagTime5ClusterManager.hxx:282
RagTime5ClusterManager::Link::L_ClusterLink
Definition: RagTime5ClusterManager.hxx:102
RagTime5ClusterManager::ClusterScript::~ClusterScript
virtual ~ClusterScript()
destructor
Definition: RagTime5ClusterManager.hxx:311
RagTime5ClusterManager::m_mainParser
RagTime5Parser & m_mainParser
the main parser
Definition: RagTime5ClusterManager.hxx:400
RagTime5ClusterManager::Cluster::m_type
Type m_type
the cluster type
Definition: RagTime5ClusterManager.hxx:230
RagTime5ClusterManager::ClusterLayout::m_zoneDimensions
std::vector< MWAWVec2f > m_zoneDimensions
list of zone's dimensions
Definition: RagTime5ClusterManager.hxx:260
RagTime5ClusterManager::Cluster::~Cluster
virtual ~Cluster()
destructor
Definition: RagTime5ClusterManager.hxx:216
RagTime5ClusterManager::Link::Type
Type
the link type
Definition: RagTime5ClusterManager.hxx:102
RagTime5ClusterManager::readCluster
bool readCluster(RagTime5Zone &zone, ClusterParser &parser, bool warnForUnparsed=true)
try to read a cluster zone
Definition: RagTime5ClusterManager.cxx:322
MWAWEntry.hxx
libmwaw_internal.hxx
RagTime5ClusterManager::Cluster::C_GraphicStyles
Definition: RagTime5ClusterManager.hxx:223
RagTime5ClusterManager::ClusterParser::m_parser
RagTime5ClusterManager & m_parser
the main parser
Definition: RagTime5ClusterManager.hxx:381
RagTime5ClusterManager::Cluster::C_UnitStyles
Definition: RagTime5ClusterManager.hxx:223
RagTime5ClusterManager::ClusterLayout::~ClusterLayout
virtual ~ClusterLayout()
destructor
Definition: RagTime5ClusterManager.hxx:258
RagTime5ClusterManager::Link::L_LinkDef
Definition: RagTime5ClusterManager.hxx:103
RagTime5ClusterManager::ClusterRoot::ClusterRoot
ClusterRoot()
constructor
Definition: RagTime5ClusterManager.hxx:270
RagTime5ClusterManager::operator=
RagTime5ClusterManager operator=(RagTime5ClusterManager const &orig)
RagTime5ClusterManager::ClusterRoot::m_linkUnknown
Link m_linkUnknown
other link: scripts and field 6
Definition: RagTime5ClusterManager.hxx:298
RagTime5ClusterManager::ClusterParser::endZone
virtual void endZone()
end of a start zone call
Definition: RagTime5ClusterManager.hxx:357
RagTime5ClusterManager::ClusterParser::m_hiLoEndian
bool m_hiLoEndian
zone endian
Definition: RagTime5ClusterManager.hxx:385
RagTime5ClusterManager::ClusterRoot::m_styleClusterIds
int m_styleClusterIds[8]
the list of style cluster ( graph, units, unitsbis, text, format, unknown, graphcolor, col/pattern id)
Definition: RagTime5ClusterManager.hxx:279
RagTime5ClusterManager::ClusterParser::m_type
int m_type
the cluster type
Definition: RagTime5ClusterManager.hxx:383
RagTime5StructManager.hxx
RagTime5ClusterManager::Cluster::C_Layout
Definition: RagTime5ClusterManager.hxx:219
RagTime5ClusterManager::ClusterScript
the cluster script ( 2/a/4002/400a zone)
Definition: RagTime5ClusterManager.hxx:305
RagTime5ClusterManager::ClusterRoot::m_graphicTypeLink
Link m_graphicTypeLink
the graphic type id
Definition: RagTime5ClusterManager.hxx:285
RagTime5ClusterManager::ClusterParser::isANameHeader
bool isANameHeader(long N) const
return true if N correspond to a file/script name
Definition: RagTime5ClusterManager.hxx:371
RagTime5ClusterManager::ClusterRoot::m_listClusterLink
Link m_listClusterLink[2]
first the main cluster link, second list of field definition link
Definition: RagTime5ClusterManager.hxx:295
RagTime5ClusterManager::ClusterParser
virtual class use to parse the cluster data
Definition: RagTime5ClusterManager.hxx:323
RagTime5ClusterManager::Link::L_UnicodeList
Definition: RagTime5ClusterManager.hxx:104
RagTime5ClusterManager::Cluster::C_ClusterB
Definition: RagTime5ClusterManager.hxx:225
RagTime5ClusterManager::Cluster::m_conditionFormulaLinks
std::vector< Link > m_conditionFormulaLinks
the conditions formula links
Definition: RagTime5ClusterManager.hxx:242
RagTime5Zone
main zone in a RagTime v5-v6 document
Definition: RagTime5StructManager.hxx:48
RagTime5ClusterManager::Cluster::C_ColorPattern
Definition: RagTime5ClusterManager.hxx:219
RagTime5ClusterManager::ClusterRoot::m_docInfoLink
Link m_docInfoLink
the doc info link
Definition: RagTime5ClusterManager.hxx:288
RagTime5ClusterManagerInternal
Internal: the structures of a RagTime5ClusterManager.
Definition: RagTime5ClusterManager.cxx:48
RagTime5ClusterManager::ClusterLayout
the layout cluster ( 4001 zone)
Definition: RagTime5ClusterManager.hxx:252
RagTime5ClusterManager::Link::operator<<
friend std::ostream & operator<<(std::ostream &o, Link const &z)
operator<<
Definition: RagTime5ClusterManager.hxx:168
RagTime5ClusterManager::ClusterRoot::m_fileName
librevenge::RVNGString m_fileName
the filename if known
Definition: RagTime5ClusterManager.hxx:301
RagTime5ClusterManager::Link::m_ids
std::vector< int > m_ids
the data ids
Definition: RagTime5ClusterManager.hxx:193
RagTime5ClusterManager::ClusterRoot
the cluster for root
Definition: RagTime5ClusterManager.hxx:268
RagTime5ClusterManager::Link::m_name
std::string m_name
the link name
Definition: RagTime5ClusterManager.hxx:191
RagTime5ClusterManager::Link::L_LongList
Definition: RagTime5ClusterManager.hxx:104
RagTime5ClusterManager::ClusterScript::ClusterScript
ClusterScript()
constructor
Definition: RagTime5ClusterManager.hxx:307
RagTime5ClusterManager::Link::L_UnknownClusterC
Definition: RagTime5ClusterManager.hxx:106
RagTime5ClusterManager::Link::m_fileType
long m_fileType[2]
the zone type in file
Definition: RagTime5ClusterManager.hxx:199
RagTime5ClusterManager::Cluster::m_hiLoEndian
bool m_hiLoEndian
the cluster hiLo endian
Definition: RagTime5ClusterManager.hxx:234
RagTime5ClusterManager::Cluster::C_Script
Definition: RagTime5ClusterManager.hxx:220
RagTime5ClusterManager::Link::Link
Link(Type type=L_Unknown)
constructor
Definition: RagTime5ClusterManager.hxx:110
RagTime5ClusterManager::ClusterParser::getCluster
virtual shared_ptr< Cluster > getCluster()=0
return the current cluster
RagTime5ClusterManager::ClusterParser::ClusterParser
ClusterParser(RagTime5ClusterManager &parser, int type, std::string const &zoneName)
constructor
Definition: RagTime5ClusterManager.hxx:325
RagTime5ClusterManager::ClusterParser::startZone
virtual void startZone()
start a new zone
Definition: RagTime5ClusterManager.hxx:348
RagTime5ClusterManager::Link::m_N
int m_N
the number of data ( or some flag if m_N & 0x8020)
Definition: RagTime5ClusterManager.hxx:195
RagTime5ClusterManager::Link::L_List
Definition: RagTime5ClusterManager.hxx:105
RagTime5ClusterManager::ClusterLayout::m_pipelineLink
Link m_pipelineLink
link to a pipeline cluster list
Definition: RagTime5ClusterManager.hxx:262
RagTime5ClusterManager::Cluster::C_Pipeline
Definition: RagTime5ClusterManager.hxx:219
RagTime5ClusterManager::ClusterRoot::m_listClusterName
Link m_listClusterName
the cluster list id name zone link
Definition: RagTime5ClusterManager.hxx:293
RagTime5ClusterManager
basic class used to manage RagTime 5/6 zones
Definition: RagTime5ClusterManager.hxx:58
RagTime5ClusterManager::Cluster::C_ColorStyles
Definition: RagTime5ClusterManager.hxx:223
RagTime5ClusterManager::Cluster::m_linksList
std::vector< Link > m_linksList
the link list
Definition: RagTime5ClusterManager.hxx:246
RagTime5ClusterManager::RagTime5ClusterManager
RagTime5ClusterManager(RagTime5Parser &parser)
constructor
Definition: RagTime5ClusterManager.cxx:143
RagTime5ClusterManager::ClusterParser::m_link
Link m_link
the actual link
Definition: RagTime5ClusterManager.hxx:391
RagTime5ClusterManager::ClusterParser::parseZone
virtual bool parseZone(MWAWInputStreamPtr &, long, int, int, libmwaw::DebugStream &)
parse a zone
Definition: RagTime5ClusterManager.hxx:352
RagTime5ClusterManager::Link::m_type
Type m_type
the link type
Definition: RagTime5ClusterManager.hxx:189
RagTime5ClusterManager::Cluster::Cluster
Cluster()
constructor
Definition: RagTime5ClusterManager.hxx:211
RagTime5ClusterManager::getClusterType
int getClusterType(RagTime5Zone &zone, int fileType)
returns the local zone type
Definition: RagTime5ClusterManager.cxx:2630
RagTime5Parser
the main class to read a RagTime v5 file
Definition: RagTime5Parser.hxx:69
RagTime5ClusterManager::Link::m_fieldSize
int m_fieldSize
the field size
Definition: RagTime5ClusterManager.hxx:197
RagTime5StructManager::Field
a field of RagTime 5/6 structures
Definition: RagTime5StructManager.hxx:220
RagTime5ClusterManager::Link::L_FieldsList
Definition: RagTime5ClusterManager.hxx:105
RagTime5ClusterManager::ClusterParser::getZoneName
virtual std::string getZoneName() const
return the debug name corresponding to a zone
Definition: RagTime5ClusterManager.hxx:334
RagTime5ClusterManager::ClusterParser::getClusterName
std::string getClusterName(int id)
returns "data"+id+"A" ( followed by the cluster type and name if know)
Definition: RagTime5ClusterManager.cxx:457
MWAWInputStreamPtr
shared_ptr< MWAWInputStream > MWAWInputStreamPtr
a smart pointer of MWAWInputStream
Definition: libmwaw_internal.hxx:439
RagTime5ClusterManager::ClusterLayout::m_listItemLink
Link m_listItemLink
link to a zone of fieldSize 8(unknown)
Definition: RagTime5ClusterManager.hxx:264
RagTime5ClusterManager::getClusterBasicHeaderInfo
bool getClusterBasicHeaderInfo(RagTime5Zone &zone, long &N, long &fSz, long &debHeaderPos)
try to return basic information about the header cluster's zone
Definition: RagTime5ClusterManager.cxx:2609
RagTime5ClusterManager::ClusterParser::readLinkHeader
bool readLinkHeader(MWAWInputStreamPtr &input, long fSz, Link &link, long(&values)[4], std::string &message)
try to read a link header
Definition: RagTime5ClusterManager.cxx:462
RagTime5ClusterManager::ClusterLayout::ClusterLayout
ClusterLayout()
constructor
Definition: RagTime5ClusterManager.hxx:254
MWAWDebug.hxx
RagTime5ClusterManager::Cluster::m_dataLink
Link m_dataLink
the main data link
Definition: RagTime5ClusterManager.hxx:236
RagTime5ClusterManager::Cluster::Type
Type
the cluster type
Definition: RagTime5ClusterManager.hxx:218
RagTime5ClusterManager::Cluster::m_settingLinks
std::vector< Link > m_settingLinks
the settings links
Definition: RagTime5ClusterManager.hxx:244
RagTime5ClusterManager::ClusterRoot::m_listClusterId
int m_listClusterId
the cluster list id
Definition: RagTime5ClusterManager.hxx:291
RagTime5ClusterManager::~RagTime5ClusterManager
~RagTime5ClusterManager()
destructor
Definition: RagTime5ClusterManager.cxx:148
RagTime5ClusterManager::Cluster::C_Unknown
Definition: RagTime5ClusterManager.hxx:227
RagTime5ClusterManager::Cluster::m_clusterIdsList
std::vector< int > m_clusterIdsList
the cluster ids
Definition: RagTime5ClusterManager.hxx:248
RagTime5ClusterManager::Cluster::C_Fields
Definition: RagTime5ClusterManager.hxx:219
RagTime5ClusterManager::m_state
shared_ptr< RagTime5ClusterManagerInternal::State > m_state
the state
Definition: RagTime5ClusterManager.hxx:398
RagTime5ClusterManager::Cluster::C_TextStyles
Definition: RagTime5ClusterManager.hxx:223
RagTime5ClusterManager::ClusterParser::parseField
virtual bool parseField(RagTime5StructManager::Field const &, int, libmwaw::DebugStream &)
parse a n_dataId:m
Definition: RagTime5ClusterManager.hxx:361
RagTime5ClusterManager::ClusterParser::m_name
std::string m_name
the cluster name
Definition: RagTime5ClusterManager.hxx:387
libmwaw::DebugStream
std::stringstream DebugStream
a basic stream (if debug_with_files is not defined, does nothing)
Definition: MWAWDebug.hxx:61
RagTime5ClusterManager::ClusterScript::m_scriptComment
Link m_scriptComment
the script comment zone
Definition: RagTime5ClusterManager.hxx:313
RagTime5ClusterManager::ClusterParser::m_dataId
int m_dataId
the actual zone id
Definition: RagTime5ClusterManager.hxx:389
RagTime5ClusterManager::m_structManager
shared_ptr< RagTime5StructManager > m_structManager
the structure manager
Definition: RagTime5ClusterManager.hxx:402
RagTime5ClusterManager::ClusterParser::~ClusterParser
virtual ~ClusterParser()
destructor
Definition: RagTime5ClusterManager.hxx:330
RagTime5ClusterManager::Link::getZoneName
std::string getZoneName() const
returns the zone name
Definition: RagTime5ClusterManager.hxx:125
RagTime5ClusterManager::Cluster::m_nameLink
Link m_nameLink
the name link
Definition: RagTime5ClusterManager.hxx:238
RagTime5ClusterManager::Link::empty
bool empty() const
returns true if all link are empty
Definition: RagTime5ClusterManager.hxx:116
RagTime5ClusterManager::ClusterParser::operator=
ClusterParser & operator=(ClusterParser const &orig)
RagTime5ClusterManager::Cluster::C_FormatStyles
Definition: RagTime5ClusterManager.hxx:223
RagTime5StructManager
basic class used to store RagTime 5/6 structures
Definition: RagTime5StructManager.hxx:158
RagTime5ClusterManager::readFieldClusters
bool readFieldClusters(Link const &link)
try to read some field cluster
Definition: RagTime5ClusterManager.cxx:283
RagTime5ClusterManager::getClusterName
std::string getClusterName(int id)
returns "data"+id+"A" ( followed by the cluster type and name if know)
Definition: RagTime5ClusterManager.cxx:184
RagTime5ClusterManager::readUnknownClusterC
bool readUnknownClusterC(Link const &link)
try to read some unknown cluster
Definition: RagTime5ClusterManager.cxx:301
RagTime5ClusterManager::getClusterFileType
int getClusterFileType(RagTime5Zone &zone)
try to find a cluster zone type ( heuristic when the cluster type is unknown )
Definition: RagTime5ClusterManager.cxx:2700
RagTime5ClusterManager::Cluster::m_fieldClusterLink
Link m_fieldClusterLink
the field cluster links (def and pos)
Definition: RagTime5ClusterManager.hxx:240
RagTime5ClusterManager::Link::L_Unknown
Definition: RagTime5ClusterManager.hxx:107
RagTime5ClusterManager::readFieldHeader
bool readFieldHeader(RagTime5Zone &zone, long endPos, std::string const &headerName, long &endDataPos, long expectedLVal=-99999)
try to read a field header, if ok set the endDataPos positions
Definition: RagTime5ClusterManager.cxx:155
RagTime5ClusterManager::ClusterParser::getZoneName
virtual std::string getZoneName(int n, int m=-1) const
return the debug name corresponding to a cluster
Definition: RagTime5ClusterManager.hxx:339
RagTime5ClusterManager::Cluster::m_zoneId
int m_zoneId
the zone id
Definition: RagTime5ClusterManager.hxx:232
RagTime5ClusterManager::Cluster::C_ClusterC
Definition: RagTime5ClusterManager.hxx:225
RagTime5ClusterManager::Link
a link to a small zone (or set of zones) in RagTime 5/6 documents
Definition: RagTime5ClusterManager.hxx:100
RagTime5ClusterManager::Cluster
the cluster data
Definition: RagTime5ClusterManager.hxx:209
RagTime5ClusterManager::ClusterRoot::~ClusterRoot
virtual ~ClusterRoot()
destructor
Definition: RagTime5ClusterManager.hxx:277
RagTime5ClusterManager::Link::m_longList
std::vector< long > m_longList
a list of long used to store decal
Definition: RagTime5ClusterManager.hxx:201