PowerPoint7Graph.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 /*
35  * Parser to PowerPoint 95 document ( graphic part )
36  *
37  */
38 #ifndef POWER_POINT7_GRAPH
39 # define POWER_POINT7_GRAPH
40 
41 #include <set>
42 #include <string>
43 #include <vector>
44 
45 #include <librevenge/librevenge.h>
46 
47 #include "libmwaw_internal.hxx"
48 
49 #include "MWAWDebug.hxx"
50 #include "MWAWInputStream.hxx"
51 
53 {
54 struct Frame;
55 struct Picture;
56 
57 struct State;
58 class SubDocument;
59 }
60 
62 {
63 struct SlideId;
64 }
65 
66 class PowerPoint7Parser;
67 
74 {
75  friend class PowerPoint7Parser;
77 public:
79  explicit PowerPoint7Graph(PowerPoint7Parser &parser);
81  virtual ~PowerPoint7Graph();
82 
84  int version() const;
86  void setPageSize(MWAWVec2i &pageSize);
88  void setSlideId(PowerPoint7Struct::SlideId const &id);
90  void setColorList(std::vector<MWAWColor> const &colorList);
91 protected:
93  bool sendSlide(PowerPoint7Struct::SlideId const &id, bool sendBackground);
95  bool sendFrame(PowerPoint7GraphInternal::Frame const &frame, bool master);
97  bool sendText(int textId);
98 
99  //
100  // Intermediate level
101  //
102 
104  bool readBitmapContainer(int level, long endPos, PowerPoint7GraphInternal::Picture &picture);
106  bool readPictureList(int level, long endPos);
108  bool readBitmap(int level, long endPos, MWAWEmbeddedObject &object, MWAWBox2i &box);
110  bool readBitmapFlag(int level, long endPos);
111 
113  bool readPictureContainer(int level, long endPos, PowerPoint7GraphInternal::Picture &picture);
115  bool readPictureIdContainer(int level, long endPos, int &id);
117  bool readPictureId(int level, long endPos, int &id);
118 
120  bool readMetaFile(int level, long endPos, MWAWEmbeddedObject &object);
122  bool readMetaFileContainer(int level, long endPos, PowerPoint7GraphInternal::Picture &picture);
124  bool readMetaFileBox(int level, long endPos, MWAWBox2i &box);
125 
127  bool readExternalOleObjectAtom(int level, long endPos);
129  bool readExternalOleEmbed(int level, long endPos, int &id);
131  bool readExternalOleEmbedAtom(int level, long endPos);
132 
134  bool readGroup(int level, long endPos);
136  bool readGroupAtom(int level, long endPos);
138  bool readStyle(int level, long endPos);
140  bool readLineArrows(int level, long endPos);
142  bool readRect(int level, long endPos);
144  bool readRectAtom(int level, long endPos);
146  bool readPlaceholderContainer(int level, long endPos);
148  bool readPlaceholderAtom(int level, long endPos);
150  bool readLine(int level, long endPos);
152  bool readLineAtom(int level, long endPos);
154  bool readPolygon(int level, long endPos);
156  bool readPolygonAtom(int level, long endPos);
158  bool readArc(int level, long endPos);
160  bool readArcAtom(int level, long endPos);
161 
163  bool readPointList(int level, long endPos, std::vector<MWAWVec2i> &points);
165  bool readZoneFlags(int level, long endPos);
166 
168  bool readZone5000(int level, long endPos);
170  bool readZone5000Header(int level, long endPos);
172  bool readZone5000Data(int level, long endPos);
173 
174  //
175  // low level
176  //
177 
178 private:
179  PowerPoint7Graph(PowerPoint7Graph const &orig) = delete;
180  PowerPoint7Graph &operator=(PowerPoint7Graph const &orig) = delete;
181 
182 protected:
183  //
184  // data
185  //
188 
190  std::shared_ptr<PowerPoint7GraphInternal::State> m_state;
191 
194 };
195 #endif
196 // vim: set filetype=cpp tabstop=2 shiftwidth=2 cindent autoindent smartindent noexpandtab:
bool readZoneFlags(int level, long endPos)
try to read the graph zone flags zone 3036
Definition: PowerPoint7Graph.cxx:1857
bool readMetaFileBox(int level, long endPos, MWAWBox2i &box)
try to read the meta file box zone 4038
Definition: PowerPoint7Graph.cxx:2243
Internal: a picture of a PowerPoint7Graph.
Definition: PowerPoint7Graph.cxx:276
std::shared_ptr< MWAWParserState > MWAWParserStatePtr
a smart pointer of MWAWParserState
Definition: libmwaw_internal.hxx:557
bool readBitmapFlag(int level, long endPos)
try to read the bitmap type zone 3038
Definition: PowerPoint7Graph.cxx:2121
bool readPolygon(int level, long endPos)
try to read the polygon zone 3016
Definition: PowerPoint7Graph.cxx:1603
bool sendText(int textId)
try to send the text content
Definition: PowerPoint7Graph.cxx:2822
Internal: a frame of a PowerPoint7Graph.
Definition: PowerPoint7Graph.cxx:62
int version() const
returns the file version
Definition: PowerPoint7Graph.cxx:651
bool readBitmapContainer(int level, long endPos, PowerPoint7GraphInternal::Picture &picture)
try to read the bitmap container zone 1027
Definition: PowerPoint7Graph.cxx:1963
bool readGroupAtom(int level, long endPos)
try to read the zone 3002
Definition: PowerPoint7Graph.cxx:731
PowerPoint7Graph & operator=(PowerPoint7Graph const &orig)=delete
void setPageSize(MWAWVec2i &pageSize)
sets the page size
Definition: PowerPoint7Graph.cxx:656
bool readRect(int level, long endPos)
try to read the graph rectangle zone 3008
Definition: PowerPoint7Graph.cxx:1222
bool readExternalOleEmbed(int level, long endPos, int &id)
try to read the external ole embed zone 4044
Definition: PowerPoint7Graph.cxx:2316
bool readPointList(int level, long endPos, std::vector< MWAWVec2i > &points)
try to read the list of point zone 3035
Definition: PowerPoint7Graph.cxx:1816
bool readPlaceholderAtom(int level, long endPos)
try to read the place holder atom zone 3011
Definition: PowerPoint7Graph.cxx:1479
bool readArc(int level, long endPos)
try to read the graph arc zone 3018
Definition: PowerPoint7Graph.cxx:1705
bool readPictureList(int level, long endPos)
try to read the font collection 10 zone 2006
Definition: PowerPoint7Graph.cxx:1896
PowerPoint7Graph(PowerPoint7Parser &parser)
constructor
Definition: PowerPoint7Graph.cxx:641
bool readGroup(int level, long endPos)
try to read the group zone
Definition: PowerPoint7Graph.cxx:677
bool sendFrame(PowerPoint7GraphInternal::Frame const &frame, bool master)
try to send a frame
Definition: PowerPoint7Graph.cxx:2701
bool readZone5000(int level, long endPos)
try to read the zone 5000: child of GraphRect (only found in 95 an 97 document)
Definition: PowerPoint7Graph.cxx:2531
bool readLineAtom(int level, long endPos)
try to read the graph line atom zone 3015
Definition: PowerPoint7Graph.cxx:1565
bool readPictureIdContainer(int level, long endPos, int &id)
try to read the picture id container zone 4053
Definition: PowerPoint7Graph.cxx:2485
PowerPoint7Parser * m_mainParser
the main parser;
Definition: PowerPoint7Graph.hxx:193
bool readStyle(int level, long endPos)
try to read the graphic style zone 3005
Definition: PowerPoint7Graph.cxx:764
bool readZone5000Header(int level, long endPos)
try to read the zone 5000 header: 5001
Definition: PowerPoint7Graph.cxx:2579
bool readPictureContainer(int level, long endPos, PowerPoint7GraphInternal::Picture &picture)
try to read the picture container 4028
Definition: PowerPoint7Graph.cxx:2407
bool readRectAtom(int level, long endPos)
try to read the graph shape zone 3009
Definition: PowerPoint7Graph.cxx:1309
bool readPolygonAtom(int level, long endPos)
try to read the polygon atom zone 3017
Definition: PowerPoint7Graph.cxx:1660
void setColorList(std::vector< MWAWColor > const &colorList)
sets the color list
Definition: PowerPoint7Graph.cxx:666
small class use to define a embedded object
Definition: libmwaw_internal.hxx:467
bool readBitmap(int level, long endPos, MWAWEmbeddedObject &object, MWAWBox2i &box)
try to read a bitmap zone 2012
Definition: PowerPoint7Graph.cxx:2016
bool readLineArrows(int level, long endPos)
try to read the line arrow zone 3007
Definition: PowerPoint7Graph.cxx:1184
std::shared_ptr< PowerPoint7GraphInternal::State > m_state
the state
Definition: PowerPoint7Graph.hxx:190
bool readArcAtom(int level, long endPos)
try to read the graph arc atom 3019
Definition: PowerPoint7Graph.cxx:1758
the main class to read a Microsoft PowerPoint 95 files (Windows)
Definition: PowerPoint7Parser.hxx:61
bool readPlaceholderContainer(int level, long endPos)
try to read a place holder container 3010
Definition: PowerPoint7Graph.cxx:1410
bool readLine(int level, long endPos)
try to read the line graph zone 3014
Definition: PowerPoint7Graph.cxx:1512
bool readMetaFile(int level, long endPos, MWAWEmbeddedObject &object)
try to read the meta file zone 4033
Definition: PowerPoint7Graph.cxx:2202
void setSlideId(PowerPoint7Struct::SlideId const &id)
sets the slide id
Definition: PowerPoint7Graph.cxx:661
Internal: the subdocument of a PowerPoint7Graph.
Definition: PowerPoint7Graph.cxx:569
bool readExternalOleObjectAtom(int level, long endPos)
try to read the external ole object atom zone: 4035
Definition: PowerPoint7Graph.cxx:2283
bool sendSlide(PowerPoint7Struct::SlideId const &id, bool sendBackground)
try to send the slide content
Definition: PowerPoint7Graph.cxx:2663
a slide id
Definition: PowerPoint7Struct.hxx:50
bool readPictureId(int level, long endPos, int &id)
try to read the picture id 4036
Definition: PowerPoint7Graph.cxx:2452
the main class to read the graphic part of a PowerPoint 95 file
Definition: PowerPoint7Graph.hxx:73
bool readMetaFileContainer(int level, long endPos, PowerPoint7GraphInternal::Picture &picture)
try to read the meta file container zone 4037
Definition: PowerPoint7Graph.cxx:2154
MWAWParserStatePtr m_parserState
the parser state
Definition: PowerPoint7Graph.hxx:187
virtual ~PowerPoint7Graph()
destructor
Definition: PowerPoint7Graph.cxx:648
Internal: the structures of a PowerPoint7Graph.
Definition: PowerPoint7Graph.cxx:59
bool readZone5000Data(int level, long endPos)
try to read the zone 5000 data: 5002
Definition: PowerPoint7Graph.cxx:2611
namespace used to define basic struct of a Microsoft PowerPoint 95 files (Windows) ...
Definition: PowerPoint7Graph.hxx:61
bool readExternalOleEmbedAtom(int level, long endPos)
try to read the external ole object atom zone: 4045
Definition: PowerPoint7Graph.cxx:2374

Generated for libmwaw by doxygen 1.8.14