xref: /AOO41X/main/xmloff/source/draw/ximpshap.hxx (revision ddde725d65c83fe3ba1186d46f6e3e08f12ba47e)
1ecfe53c5SAndrew Rist /**************************************************************
2cdf0e10cSrcweir  *
3ecfe53c5SAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
4ecfe53c5SAndrew Rist  * or more contributor license agreements.  See the NOTICE file
5ecfe53c5SAndrew Rist  * distributed with this work for additional information
6ecfe53c5SAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
7ecfe53c5SAndrew Rist  * to you under the Apache License, Version 2.0 (the
8ecfe53c5SAndrew Rist  * "License"); you may not use this file except in compliance
9ecfe53c5SAndrew Rist  * with the License.  You may obtain a copy of the License at
10cdf0e10cSrcweir  *
11ecfe53c5SAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
12cdf0e10cSrcweir  *
13ecfe53c5SAndrew Rist  * Unless required by applicable law or agreed to in writing,
14ecfe53c5SAndrew Rist  * software distributed under the License is distributed on an
15ecfe53c5SAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16ecfe53c5SAndrew Rist  * KIND, either express or implied.  See the License for the
17ecfe53c5SAndrew Rist  * specific language governing permissions and limitations
18ecfe53c5SAndrew Rist  * under the License.
19cdf0e10cSrcweir  *
20ecfe53c5SAndrew Rist  *************************************************************/
21ecfe53c5SAndrew Rist 
22ecfe53c5SAndrew Rist 
23cdf0e10cSrcweir 
24cdf0e10cSrcweir #ifndef _XIMPSHAPE_HXX
25cdf0e10cSrcweir #define _XIMPSHAPE_HXX
26cdf0e10cSrcweir 
27cdf0e10cSrcweir #include <com/sun/star/io/XOutputStream.hpp>
28cdf0e10cSrcweir #include <com/sun/star/document/XActionLockable.hpp>
29cdf0e10cSrcweir #include <com/sun/star/container/XIdentifierContainer.hpp>
30cdf0e10cSrcweir #include <xmloff/xmlictxt.hxx>
31cdf0e10cSrcweir #include "sdxmlimp_impl.hxx"
32cdf0e10cSrcweir #include <xmloff/nmspmap.hxx>
33cdf0e10cSrcweir #include <com/sun/star/drawing/XShapes.hpp>
34cdf0e10cSrcweir #include <com/sun/star/text/XTextCursor.hpp>
35cdf0e10cSrcweir #include <com/sun/star/awt/Point.hpp>
36cdf0e10cSrcweir #include <tools/rtti.hxx>
37cdf0e10cSrcweir #include "xexptran.hxx"
38cdf0e10cSrcweir 
39cdf0e10cSrcweir #include <vector>
40cdf0e10cSrcweir #include <xmloff/shapeimport.hxx>
41*ddde725dSArmin Le Grand #include <xmloff/xmlmultiimagehelper.hxx>
42cdf0e10cSrcweir 
43cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
44cdf0e10cSrcweir // common shape context
45cdf0e10cSrcweir 
46cdf0e10cSrcweir class SdXMLShapeContext : public SvXMLShapeContext
47cdf0e10cSrcweir {
48cdf0e10cSrcweir protected:
49cdf0e10cSrcweir 	// the shape group this object should be created inside
50cdf0e10cSrcweir 	com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >	mxShapes;
51cdf0e10cSrcweir 	com::sun::star::uno::Reference< com::sun::star::text::XTextCursor >	mxCursor;
52cdf0e10cSrcweir 	com::sun::star::uno::Reference< com::sun::star::text::XTextCursor >	mxOldCursor;
53cdf0e10cSrcweir 	com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList> mxAttrList;
54cdf0e10cSrcweir 	com::sun::star::uno::Reference< com::sun::star::container::XIdentifierContainer > mxGluePoints;
55cdf0e10cSrcweir 	com::sun::star::uno::Reference< com::sun::star::document::XActionLockable > mxLockable;
56cdf0e10cSrcweir 
57cdf0e10cSrcweir 	rtl::OUString				maDrawStyleName;
58cdf0e10cSrcweir 	rtl::OUString				maTextStyleName;
59cdf0e10cSrcweir 	rtl::OUString				maPresentationClass;
60cdf0e10cSrcweir 	rtl::OUString				maShapeName;
61cdf0e10cSrcweir 	rtl::OUString				maThumbnailURL;
62cdf0e10cSrcweir 
63cdf0e10cSrcweir     /// whether to restore list context (#91964#)
64cdf0e10cSrcweir     bool                        mbListContextPushed;
65cdf0e10cSrcweir 
66cdf0e10cSrcweir 	sal_uInt16					mnStyleFamily;
67cdf0e10cSrcweir 	sal_uInt16					mnClass;
68cdf0e10cSrcweir 	sal_Bool					mbIsPlaceholder;
69cdf0e10cSrcweir 	bool						mbClearDefaultAttributes;
70cdf0e10cSrcweir 	sal_Bool					mbIsUserTransformed;
71cdf0e10cSrcweir 	sal_Int32					mnZOrder;
72cdf0e10cSrcweir 	rtl::OUString				maShapeId;
73cdf0e10cSrcweir 	rtl::OUString				maLayerName;
74cdf0e10cSrcweir 
75cdf0e10cSrcweir 	// #i68101#
76cdf0e10cSrcweir 	rtl::OUString				maShapeTitle;
77cdf0e10cSrcweir 	rtl::OUString				maShapeDescription;
78cdf0e10cSrcweir 
79cdf0e10cSrcweir 	SdXMLImExTransform2D		mnTransform;
80cdf0e10cSrcweir 	com::sun::star::awt::Size	maSize;
81cdf0e10cSrcweir 	com::sun::star::awt::Point	maPosition;
82cdf0e10cSrcweir 
83cdf0e10cSrcweir 	bool						mbVisible;
84cdf0e10cSrcweir 	bool						mbPrintable;
85cdf0e10cSrcweir 
86cdf0e10cSrcweir 	/** if bSupportsStyle is false, auto styles will be set but not	a style */
87cdf0e10cSrcweir 	void SetStyle( bool bSupportsStyle = true );
88cdf0e10cSrcweir 	void SetLayer();
89cdf0e10cSrcweir 	void SetThumbnail();
90cdf0e10cSrcweir 
91cdf0e10cSrcweir 	void AddShape(com::sun::star::uno::Reference< com::sun::star::drawing::XShape >& xShape);
92cdf0e10cSrcweir 	void AddShape(const char* pServiceName );
93cdf0e10cSrcweir 	void SetTransformation();
94cdf0e10cSrcweir 
95cdf0e10cSrcweir 	SvXMLImport& GetImport() { return SvXMLImportContext::GetImport(); }
96cdf0e10cSrcweir 	const SvXMLImport& GetImport() const { return SvXMLImportContext::GetImport(); }
97cdf0e10cSrcweir 
98cdf0e10cSrcweir 	void addGluePoint( const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList );
99cdf0e10cSrcweir 
100cdf0e10cSrcweir 	sal_Bool isPresentationShape() const;
101cdf0e10cSrcweir 
102cdf0e10cSrcweir public:
103cdf0e10cSrcweir 	TYPEINFO();
104cdf0e10cSrcweir 
105cdf0e10cSrcweir 	SdXMLShapeContext( SvXMLImport& rImport,
106cdf0e10cSrcweir 		sal_uInt16 nPrfx,
107cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
108cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
109cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
110cdf0e10cSrcweir         sal_Bool bTemporaryShape);
111cdf0e10cSrcweir 	virtual ~SdXMLShapeContext();
112cdf0e10cSrcweir 
113cdf0e10cSrcweir 	virtual void StartElement(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList);
114cdf0e10cSrcweir 	virtual void EndElement();
115cdf0e10cSrcweir 
116cdf0e10cSrcweir 	virtual SvXMLImportContext * CreateChildContext( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName,
117cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList );
118cdf0e10cSrcweir 
119cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
120cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
121cdf0e10cSrcweir };
122cdf0e10cSrcweir 
123cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
124cdf0e10cSrcweir // draw:rect context
125cdf0e10cSrcweir 
126cdf0e10cSrcweir class SdXMLRectShapeContext : public SdXMLShapeContext
127cdf0e10cSrcweir {
128cdf0e10cSrcweir 	sal_Int32					mnRadius;
129cdf0e10cSrcweir 
130cdf0e10cSrcweir public:
131cdf0e10cSrcweir 	TYPEINFO();
132cdf0e10cSrcweir 
133cdf0e10cSrcweir 	SdXMLRectShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
134cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
135cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
136cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
137cdf0e10cSrcweir         sal_Bool bTemporaryShape);
138cdf0e10cSrcweir 	virtual ~SdXMLRectShapeContext();
139cdf0e10cSrcweir 	virtual void StartElement(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList);
140cdf0e10cSrcweir 
141cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
142cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
143cdf0e10cSrcweir };
144cdf0e10cSrcweir 
145cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
146cdf0e10cSrcweir // draw:line context
147cdf0e10cSrcweir 
148cdf0e10cSrcweir class SdXMLLineShapeContext : public SdXMLShapeContext
149cdf0e10cSrcweir {
150cdf0e10cSrcweir 	sal_Int32					mnX1;
151cdf0e10cSrcweir 	sal_Int32					mnY1;
152cdf0e10cSrcweir 	sal_Int32					mnX2;
153cdf0e10cSrcweir 	sal_Int32					mnY2;
154cdf0e10cSrcweir 
155cdf0e10cSrcweir public:
156cdf0e10cSrcweir 	TYPEINFO();
157cdf0e10cSrcweir 
158cdf0e10cSrcweir 	SdXMLLineShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
159cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
160cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
161cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
162cdf0e10cSrcweir         sal_Bool bTemporaryShape);
163cdf0e10cSrcweir 	virtual ~SdXMLLineShapeContext();
164cdf0e10cSrcweir 	virtual void StartElement(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList);
165cdf0e10cSrcweir 
166cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
167cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
168cdf0e10cSrcweir };
169cdf0e10cSrcweir 
170cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
171cdf0e10cSrcweir // draw:ellipse and draw:circle context
172cdf0e10cSrcweir 
173cdf0e10cSrcweir class SdXMLEllipseShapeContext : public SdXMLShapeContext
174cdf0e10cSrcweir {
175cdf0e10cSrcweir 	sal_Int32					mnCX;
176cdf0e10cSrcweir 	sal_Int32					mnCY;
177cdf0e10cSrcweir 	sal_Int32					mnRX;
178cdf0e10cSrcweir 	sal_Int32					mnRY;
179cdf0e10cSrcweir 
180cdf0e10cSrcweir 	sal_uInt16						meKind;
181cdf0e10cSrcweir 	sal_Int32					mnStartAngle;
182cdf0e10cSrcweir 	sal_Int32					mnEndAngle;
183cdf0e10cSrcweir public:
184cdf0e10cSrcweir 	TYPEINFO();
185cdf0e10cSrcweir 
186cdf0e10cSrcweir 	SdXMLEllipseShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
187cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
188cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
189cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
190cdf0e10cSrcweir         sal_Bool bTemporaryShape);
191cdf0e10cSrcweir 	virtual ~SdXMLEllipseShapeContext();
192cdf0e10cSrcweir 	virtual void StartElement(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList);
193cdf0e10cSrcweir 
194cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
195cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
196cdf0e10cSrcweir };
197cdf0e10cSrcweir 
198cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
199cdf0e10cSrcweir // draw:polyline and draw:polygon context
200cdf0e10cSrcweir 
201cdf0e10cSrcweir class SdXMLPolygonShapeContext : public SdXMLShapeContext
202cdf0e10cSrcweir {
203cdf0e10cSrcweir 	rtl::OUString				maPoints;
204cdf0e10cSrcweir 	rtl::OUString				maViewBox;
205cdf0e10cSrcweir 	sal_Bool					mbClosed;
206cdf0e10cSrcweir 
207cdf0e10cSrcweir public:
208cdf0e10cSrcweir 	TYPEINFO();
209cdf0e10cSrcweir 
210cdf0e10cSrcweir 	SdXMLPolygonShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
211cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
212cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
213cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes, sal_Bool bClosed, sal_Bool bTemporaryShape);
214cdf0e10cSrcweir 	virtual ~SdXMLPolygonShapeContext();
215cdf0e10cSrcweir 	virtual void StartElement(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList);
216cdf0e10cSrcweir 
217cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
218cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
219cdf0e10cSrcweir };
220cdf0e10cSrcweir 
221cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
222cdf0e10cSrcweir // draw:path context
223cdf0e10cSrcweir 
224cdf0e10cSrcweir class SdXMLPathShapeContext : public SdXMLShapeContext
225cdf0e10cSrcweir {
226cdf0e10cSrcweir 	rtl::OUString				maD;
227cdf0e10cSrcweir 	rtl::OUString				maViewBox;
228cdf0e10cSrcweir 	sal_Bool					mbClosed;
229cdf0e10cSrcweir 
230cdf0e10cSrcweir public:
231cdf0e10cSrcweir 	TYPEINFO();
232cdf0e10cSrcweir 
233cdf0e10cSrcweir 	SdXMLPathShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
234cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
235cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
236cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
237cdf0e10cSrcweir         sal_Bool bTemporaryShape);
238cdf0e10cSrcweir 	virtual ~SdXMLPathShapeContext();
239cdf0e10cSrcweir 	virtual void StartElement(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList);
240cdf0e10cSrcweir 
241cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
242cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
243cdf0e10cSrcweir };
244cdf0e10cSrcweir 
245cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
246cdf0e10cSrcweir // draw:text-box context
247cdf0e10cSrcweir 
248cdf0e10cSrcweir class SdXMLTextBoxShapeContext : public SdXMLShapeContext
249cdf0e10cSrcweir {
250cdf0e10cSrcweir 	sal_Int32					mnRadius;
251cdf0e10cSrcweir 
252cdf0e10cSrcweir public:
253cdf0e10cSrcweir 	TYPEINFO();
254cdf0e10cSrcweir 
255cdf0e10cSrcweir 	SdXMLTextBoxShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
256cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
257cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
258cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
259cdf0e10cSrcweir         sal_Bool bTemporaryShape);
260cdf0e10cSrcweir 	virtual ~SdXMLTextBoxShapeContext();
261cdf0e10cSrcweir 	virtual void StartElement(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList);
262cdf0e10cSrcweir 
263cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
264cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
265cdf0e10cSrcweir };
266cdf0e10cSrcweir 
267cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
268cdf0e10cSrcweir // draw:control context
269cdf0e10cSrcweir 
270cdf0e10cSrcweir class SdXMLControlShapeContext : public SdXMLShapeContext
271cdf0e10cSrcweir {
272cdf0e10cSrcweir private:
273cdf0e10cSrcweir 	rtl::OUString maFormId;
274cdf0e10cSrcweir 
275cdf0e10cSrcweir public:
276cdf0e10cSrcweir 	TYPEINFO();
277cdf0e10cSrcweir 
278cdf0e10cSrcweir 	SdXMLControlShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
279cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
280cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
281cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
282cdf0e10cSrcweir         sal_Bool bTemporaryShape);
283cdf0e10cSrcweir 	virtual ~SdXMLControlShapeContext();
284cdf0e10cSrcweir 	virtual void StartElement(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList);
285cdf0e10cSrcweir 
286cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
287cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
288cdf0e10cSrcweir };
289cdf0e10cSrcweir 
290cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
291cdf0e10cSrcweir // draw:connector context
292cdf0e10cSrcweir 
293cdf0e10cSrcweir class SdXMLConnectorShapeContext : public SdXMLShapeContext
294cdf0e10cSrcweir {
295cdf0e10cSrcweir private:
296cdf0e10cSrcweir 	::com::sun::star::awt::Point maStart;
297cdf0e10cSrcweir 	::com::sun::star::awt::Point maEnd;
298cdf0e10cSrcweir 
299cdf0e10cSrcweir 	sal_uInt16		mnType;
300cdf0e10cSrcweir 
301cdf0e10cSrcweir 	rtl::OUString	maStartShapeId;
302cdf0e10cSrcweir 	sal_Int32		mnStartGlueId;
303cdf0e10cSrcweir 	rtl::OUString	maEndShapeId;
304cdf0e10cSrcweir 	sal_Int32		mnEndGlueId;
305cdf0e10cSrcweir 
306cdf0e10cSrcweir 	sal_Int32	mnDelta1;
307cdf0e10cSrcweir 	sal_Int32	mnDelta2;
308cdf0e10cSrcweir 	sal_Int32	mnDelta3;
309cdf0e10cSrcweir 
310cdf0e10cSrcweir 	com::sun::star::uno::Any maPath;
311cdf0e10cSrcweir 
312cdf0e10cSrcweir public:
313cdf0e10cSrcweir 	TYPEINFO();
314cdf0e10cSrcweir 
315cdf0e10cSrcweir 	SdXMLConnectorShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
316cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
317cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
318cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
319cdf0e10cSrcweir         sal_Bool bTemporaryShape);
320cdf0e10cSrcweir 	virtual ~SdXMLConnectorShapeContext();
321cdf0e10cSrcweir 	virtual void StartElement(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList);
322cdf0e10cSrcweir 
323cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
324cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
325cdf0e10cSrcweir };
326cdf0e10cSrcweir 
327cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
328cdf0e10cSrcweir // draw:measure context
329cdf0e10cSrcweir 
330cdf0e10cSrcweir class SdXMLMeasureShapeContext : public SdXMLShapeContext
331cdf0e10cSrcweir {
332cdf0e10cSrcweir private:
333cdf0e10cSrcweir 	::com::sun::star::awt::Point maStart;
334cdf0e10cSrcweir 	::com::sun::star::awt::Point maEnd;
335cdf0e10cSrcweir 
336cdf0e10cSrcweir public:
337cdf0e10cSrcweir 	TYPEINFO();
338cdf0e10cSrcweir 
339cdf0e10cSrcweir 	SdXMLMeasureShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
340cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
341cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
342cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
343cdf0e10cSrcweir         sal_Bool bTemporaryShape);
344cdf0e10cSrcweir 	virtual ~SdXMLMeasureShapeContext();
345cdf0e10cSrcweir 	virtual void StartElement(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList);
346cdf0e10cSrcweir 	virtual void EndElement();
347cdf0e10cSrcweir 
348cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
349cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
350cdf0e10cSrcweir };
351cdf0e10cSrcweir 
352cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
353cdf0e10cSrcweir // draw:page context
354cdf0e10cSrcweir 
355cdf0e10cSrcweir class SdXMLPageShapeContext : public SdXMLShapeContext
356cdf0e10cSrcweir {
357cdf0e10cSrcweir private:
358cdf0e10cSrcweir 	sal_Int32	mnPageNumber;
359cdf0e10cSrcweir public:
360cdf0e10cSrcweir 	TYPEINFO();
361cdf0e10cSrcweir 
362cdf0e10cSrcweir 	SdXMLPageShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
363cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
364cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
365cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
366cdf0e10cSrcweir         sal_Bool bTemporaryShape);
367cdf0e10cSrcweir 	virtual ~SdXMLPageShapeContext();
368cdf0e10cSrcweir 	virtual void StartElement(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList);
369cdf0e10cSrcweir 
370cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
371cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
372cdf0e10cSrcweir };
373cdf0e10cSrcweir 
374cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
375cdf0e10cSrcweir // draw:caption context
376cdf0e10cSrcweir 
377cdf0e10cSrcweir class SdXMLCaptionShapeContext : public SdXMLShapeContext
378cdf0e10cSrcweir {
379cdf0e10cSrcweir private:
380cdf0e10cSrcweir 	com::sun::star::awt::Point maCaptionPoint;
381cdf0e10cSrcweir 	sal_Int32 mnRadius;
382cdf0e10cSrcweir 
383cdf0e10cSrcweir public:
384cdf0e10cSrcweir 	TYPEINFO();
385cdf0e10cSrcweir 
386cdf0e10cSrcweir 	SdXMLCaptionShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
387cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
388cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
389cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
390cdf0e10cSrcweir         sal_Bool bTemporaryShape);
391cdf0e10cSrcweir 	virtual ~SdXMLCaptionShapeContext();
392cdf0e10cSrcweir 	virtual void StartElement(const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList);
393cdf0e10cSrcweir 
394cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
395cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
396cdf0e10cSrcweir };
397cdf0e10cSrcweir 
398cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
399cdf0e10cSrcweir // office:image context
400cdf0e10cSrcweir 
401cdf0e10cSrcweir class SdXMLGraphicObjectShapeContext : public SdXMLShapeContext
402cdf0e10cSrcweir {
403cdf0e10cSrcweir private:
404cdf0e10cSrcweir 	::rtl::OUString maURL;
405cdf0e10cSrcweir 	::com::sun::star::uno::Reference < ::com::sun::star::io::XOutputStream > mxBase64Stream;
406cdf0e10cSrcweir 
407cdf0e10cSrcweir public:
408cdf0e10cSrcweir 	TYPEINFO();
409cdf0e10cSrcweir 
410cdf0e10cSrcweir 	SdXMLGraphicObjectShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
411cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
412cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
413cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
414cdf0e10cSrcweir         sal_Bool bTemporaryShape);
415cdf0e10cSrcweir 	virtual ~SdXMLGraphicObjectShapeContext();
416cdf0e10cSrcweir 
417cdf0e10cSrcweir 	virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList );
418cdf0e10cSrcweir 	virtual void EndElement();
419cdf0e10cSrcweir 	virtual SvXMLImportContext * CreateChildContext( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName,
420cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList );
421cdf0e10cSrcweir 
422cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
423cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
424cdf0e10cSrcweir };
425cdf0e10cSrcweir 
426cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
427cdf0e10cSrcweir // chart:chart context
428cdf0e10cSrcweir 
429cdf0e10cSrcweir class SdXMLChartShapeContext : public SdXMLShapeContext
430cdf0e10cSrcweir {
431cdf0e10cSrcweir 	SvXMLImportContext*			mpChartContext;
432cdf0e10cSrcweir 
433cdf0e10cSrcweir public:
434cdf0e10cSrcweir 	TYPEINFO();
435cdf0e10cSrcweir 
436cdf0e10cSrcweir 	SdXMLChartShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
437cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
438cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
439cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
440cdf0e10cSrcweir         sal_Bool bTemporaryShape);
441cdf0e10cSrcweir 	virtual ~SdXMLChartShapeContext();
442cdf0e10cSrcweir 
443cdf0e10cSrcweir 	virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList );
444cdf0e10cSrcweir 	virtual void EndElement();
445cdf0e10cSrcweir 	virtual void Characters( const ::rtl::OUString& rChars );
446cdf0e10cSrcweir 	virtual SvXMLImportContext * CreateChildContext( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName,
447cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList );
448cdf0e10cSrcweir };
449cdf0e10cSrcweir 
450cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
451cdf0e10cSrcweir // draw:object and draw:object_ole context
452cdf0e10cSrcweir 
453cdf0e10cSrcweir class SdXMLObjectShapeContext : public SdXMLShapeContext
454cdf0e10cSrcweir {
455cdf0e10cSrcweir private:
456cdf0e10cSrcweir 	rtl::OUString maCLSID;
457cdf0e10cSrcweir 	rtl::OUString maHref;
458cdf0e10cSrcweir 
459cdf0e10cSrcweir 	// #100592#
460cdf0e10cSrcweir 	::com::sun::star::uno::Reference < ::com::sun::star::io::XOutputStream > mxBase64Stream;
461cdf0e10cSrcweir 
462cdf0e10cSrcweir public:
463cdf0e10cSrcweir 	TYPEINFO();
464cdf0e10cSrcweir 
465cdf0e10cSrcweir 	SdXMLObjectShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
466cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
467cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
468cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
469cdf0e10cSrcweir         sal_Bool bTemporaryShape);
470cdf0e10cSrcweir 	virtual ~SdXMLObjectShapeContext();
471cdf0e10cSrcweir 
472cdf0e10cSrcweir 	virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList );
473cdf0e10cSrcweir 	virtual void EndElement();
474cdf0e10cSrcweir 
475cdf0e10cSrcweir 	// #100592#
476cdf0e10cSrcweir 	virtual SvXMLImportContext * CreateChildContext( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName,
477cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList );
478cdf0e10cSrcweir 
479cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
480cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
481cdf0e10cSrcweir };
482cdf0e10cSrcweir 
483cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
484cdf0e10cSrcweir // draw:applet
485cdf0e10cSrcweir 
486cdf0e10cSrcweir class SdXMLAppletShapeContext : public SdXMLShapeContext
487cdf0e10cSrcweir {
488cdf0e10cSrcweir private:
489cdf0e10cSrcweir 	rtl::OUString maAppletName;
490cdf0e10cSrcweir 	rtl::OUString maAppletCode;
491cdf0e10cSrcweir 	rtl::OUString maHref;
492cdf0e10cSrcweir 	sal_Bool mbIsScript;
493cdf0e10cSrcweir 
494cdf0e10cSrcweir 	com::sun::star::uno::Sequence< com::sun::star::beans::PropertyValue > maParams;
495cdf0e10cSrcweir 
496cdf0e10cSrcweir public:
497cdf0e10cSrcweir 	TYPEINFO();
498cdf0e10cSrcweir 
499cdf0e10cSrcweir 	SdXMLAppletShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
500cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
501cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
502cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
503cdf0e10cSrcweir         sal_Bool bTemporaryShape);
504cdf0e10cSrcweir 	virtual ~SdXMLAppletShapeContext();
505cdf0e10cSrcweir 
506cdf0e10cSrcweir 	virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList );
507cdf0e10cSrcweir 	virtual void EndElement();
508cdf0e10cSrcweir 
509cdf0e10cSrcweir 	virtual SvXMLImportContext * CreateChildContext( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName,
510cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList );
511cdf0e10cSrcweir 
512cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
513cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
514cdf0e10cSrcweir };
515cdf0e10cSrcweir 
516cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
517cdf0e10cSrcweir // draw:plugin
518cdf0e10cSrcweir 
519cdf0e10cSrcweir class SdXMLPluginShapeContext : public SdXMLShapeContext
520cdf0e10cSrcweir {
521cdf0e10cSrcweir private:
522cdf0e10cSrcweir 	rtl::OUString 	maMimeType;
523cdf0e10cSrcweir 	rtl::OUString 	maHref;
524cdf0e10cSrcweir 	bool			mbMedia;
525cdf0e10cSrcweir 
526cdf0e10cSrcweir 	com::sun::star::uno::Sequence< com::sun::star::beans::PropertyValue > maParams;
527cdf0e10cSrcweir 
528cdf0e10cSrcweir public:
529cdf0e10cSrcweir 	TYPEINFO();
530cdf0e10cSrcweir 
531cdf0e10cSrcweir 	SdXMLPluginShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
532cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
533cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
534cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
535cdf0e10cSrcweir         sal_Bool bTemporaryShape);
536cdf0e10cSrcweir 	virtual ~SdXMLPluginShapeContext();
537cdf0e10cSrcweir 
538cdf0e10cSrcweir 	virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList );
539cdf0e10cSrcweir 	virtual void EndElement();
540cdf0e10cSrcweir 
541cdf0e10cSrcweir 	virtual SvXMLImportContext * CreateChildContext( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName,
542cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList );
543cdf0e10cSrcweir 
544cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
545cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
546cdf0e10cSrcweir };
547cdf0e10cSrcweir 
548cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
549cdf0e10cSrcweir // draw:floating-frame
550cdf0e10cSrcweir 
551cdf0e10cSrcweir class SdXMLFloatingFrameShapeContext : public SdXMLShapeContext
552cdf0e10cSrcweir {
553cdf0e10cSrcweir private:
554cdf0e10cSrcweir 	rtl::OUString maFrameName;
555cdf0e10cSrcweir 	rtl::OUString maHref;
556cdf0e10cSrcweir 
557cdf0e10cSrcweir public:
558cdf0e10cSrcweir 	TYPEINFO();
559cdf0e10cSrcweir 
560cdf0e10cSrcweir 	SdXMLFloatingFrameShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
561cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
562cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
563cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
564cdf0e10cSrcweir         sal_Bool bTemporaryShape);
565cdf0e10cSrcweir 	virtual ~SdXMLFloatingFrameShapeContext();
566cdf0e10cSrcweir 
567cdf0e10cSrcweir 	virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList );
568cdf0e10cSrcweir 	virtual void EndElement();
569cdf0e10cSrcweir 
570cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
571cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
572cdf0e10cSrcweir };
573cdf0e10cSrcweir 
574cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
575cdf0e10cSrcweir // draw:-frame
576cdf0e10cSrcweir 
577*ddde725dSArmin Le Grand class SdXMLFrameShapeContext : public SdXMLShapeContext, public multiImageImportHelper
578cdf0e10cSrcweir {
579cdf0e10cSrcweir private:
580cdf0e10cSrcweir 	sal_Bool mbSupportsReplacement;
581cdf0e10cSrcweir 	SvXMLImportContextRef mxImplContext;
582cdf0e10cSrcweir 	SvXMLImportContextRef mxReplImplContext;
583cdf0e10cSrcweir 
584*ddde725dSArmin Le Grand protected:
585*ddde725dSArmin Le Grand     /// helper to get the created xShape instance, needs to be overloaded
586*ddde725dSArmin Le Grand     virtual rtl::OUString getGraphicURLFromImportContext(const SvXMLImportContext& rContext) const;
587*ddde725dSArmin Le Grand     virtual void removeGraphicFromImportContext(const SvXMLImportContext& rContext) const;
588*ddde725dSArmin Le Grand 
589cdf0e10cSrcweir public:
590cdf0e10cSrcweir 	TYPEINFO();
591cdf0e10cSrcweir 
592cdf0e10cSrcweir 	SdXMLFrameShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
593cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
594cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
595cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
596cdf0e10cSrcweir         sal_Bool bTemporaryShape);
597cdf0e10cSrcweir 	virtual ~SdXMLFrameShapeContext();
598cdf0e10cSrcweir 
599cdf0e10cSrcweir 	virtual SvXMLImportContext * CreateChildContext( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName,
600cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList );
601cdf0e10cSrcweir 
602cdf0e10cSrcweir 	virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList );
603cdf0e10cSrcweir 	virtual void EndElement();
604cdf0e10cSrcweir 
605cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
606cdf0e10cSrcweir };
607cdf0e10cSrcweir 
608cdf0e10cSrcweir class SdXMLCustomShapeContext : public SdXMLShapeContext
609cdf0e10cSrcweir {
610cdf0e10cSrcweir 
611cdf0e10cSrcweir protected :
612cdf0e10cSrcweir 
613cdf0e10cSrcweir 	rtl::OUString maCustomShapeEngine;
614cdf0e10cSrcweir 	rtl::OUString maCustomShapeData;
615cdf0e10cSrcweir 
616cdf0e10cSrcweir 	std::vector< com::sun::star::beans::PropertyValue > maCustomShapeGeometry;
617cdf0e10cSrcweir 
618cdf0e10cSrcweir public:
619cdf0e10cSrcweir 
620cdf0e10cSrcweir 	TYPEINFO();
621cdf0e10cSrcweir 
622cdf0e10cSrcweir 	SdXMLCustomShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx, const rtl::OUString& rLocalName,
623cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
624cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes,
625cdf0e10cSrcweir         sal_Bool bTemporaryShape);
626cdf0e10cSrcweir 	virtual ~SdXMLCustomShapeContext();
627cdf0e10cSrcweir 
628cdf0e10cSrcweir 	virtual void StartElement( const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList );
629cdf0e10cSrcweir 	virtual void EndElement();
630cdf0e10cSrcweir 
631cdf0e10cSrcweir 	virtual SvXMLImportContext * CreateChildContext( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName,
632cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList );
633cdf0e10cSrcweir 
634cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
635cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
636cdf0e10cSrcweir };
637cdf0e10cSrcweir 
638cdf0e10cSrcweir //////////////////////////////////////////////////////////////////////////////
639cdf0e10cSrcweir // draw:table
640cdf0e10cSrcweir 
641cdf0e10cSrcweir class SdXMLTableShapeContext : public SdXMLShapeContext
642cdf0e10cSrcweir {
643cdf0e10cSrcweir public:
644cdf0e10cSrcweir 	TYPEINFO();
645cdf0e10cSrcweir 
646cdf0e10cSrcweir 	SdXMLTableShapeContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
647cdf0e10cSrcweir 		const rtl::OUString& rLocalName,
648cdf0e10cSrcweir 		const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList,
649cdf0e10cSrcweir 		com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >& rShapes );
650cdf0e10cSrcweir 	virtual ~SdXMLTableShapeContext();
651cdf0e10cSrcweir 
652cdf0e10cSrcweir 	virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList );
653cdf0e10cSrcweir 	virtual void EndElement();
654cdf0e10cSrcweir 
655cdf0e10cSrcweir 	virtual SvXMLImportContext * CreateChildContext( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList>& xAttrList );
656cdf0e10cSrcweir 
657cdf0e10cSrcweir 	// this is called from the parent group for each unparsed attribute in the attribute list
658cdf0e10cSrcweir 	virtual void processAttribute( sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName, const ::rtl::OUString& rValue );
659cdf0e10cSrcweir 
660cdf0e10cSrcweir private:
661cdf0e10cSrcweir 	SvXMLImportContextRef mxTableImportContext;
662cdf0e10cSrcweir 	rtl::OUString msTemplateStyleName;
663cdf0e10cSrcweir 	sal_Bool maTemplateStylesUsed[6];
664cdf0e10cSrcweir };
665cdf0e10cSrcweir 
666cdf0e10cSrcweir #endif	//  _XIMPSHAPE_HXX
667