xref: /trunk/main/xmloff/source/style/FillStyleContext.hxx (revision 1ecadb572e7010ff3b3382ad9bf179dbc6efadbb)
1 /*************************************************************************
2  *
3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4  *
5  * Copyright 2000, 2010 Oracle and/or its affiliates.
6  *
7  * OpenOffice.org - a multi-platform office productivity suite
8  *
9  * This file is part of OpenOffice.org.
10  *
11  * OpenOffice.org is free software: you can redistribute it and/or modify
12  * it under the terms of the GNU Lesser General Public License version 3
13  * only, as published by the Free Software Foundation.
14  *
15  * OpenOffice.org is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  * GNU Lesser General Public License version 3 for more details
19  * (a copy is included in the LICENSE file that accompanied this code).
20  *
21  * You should have received a copy of the GNU Lesser General Public License
22  * version 3 along with OpenOffice.org.  If not, see
23  * <http://www.openoffice.org/license.html>
24  * for a copy of the LGPLv3 License.
25  *
26  ************************************************************************/
27 
28 #ifndef _XMLOFF_FILLSTYLECONTEXTS_HXX_
29 #define _XMLOFF_FILLSTYLECONTEXTS_HXX_
30 
31 #include <com/sun/star/io/XOutputStream.hpp>
32 #include <xmloff/xmlstyle.hxx>
33 #include<rtl/ustring.hxx>
34 
35 //////////////////////////////////////////////////////////////////////////////
36 // draw:gardient context
37 
38 class XMLGradientStyleContext: public SvXMLStyleContext
39 {
40 private:
41     ::com::sun::star::uno::Any  maAny;
42     rtl::OUString               maStrName;
43 
44 public:
45     TYPEINFO();
46 
47     XMLGradientStyleContext( SvXMLImport& rImport,  sal_uInt16 nPrfx,  const rtl::OUString& rLName,
48                            const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttrList );
49     virtual ~XMLGradientStyleContext();
50 
51     virtual void EndElement();
52 
53     virtual sal_Bool IsTransient() const;
54 };
55 
56 //////////////////////////////////////////////////////////////////////////////
57 // draw:hatch context
58 
59 class XMLHatchStyleContext: public SvXMLStyleContext
60 {
61 private:
62     ::com::sun::star::uno::Any  maAny;
63     rtl::OUString               maStrName;
64 
65 public:
66     TYPEINFO();
67 
68     XMLHatchStyleContext( SvXMLImport& rImport,  sal_uInt16 nPrfx,  const rtl::OUString& rLName,
69                            const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttrList );
70     virtual ~XMLHatchStyleContext();
71 
72     virtual void EndElement();
73 
74     virtual sal_Bool IsTransient() const;
75 };
76 
77 //////////////////////////////////////////////////////////////////////////////
78 // draw:fill-image context
79 
80 class XMLBitmapStyleContext: public SvXMLStyleContext
81 {
82 private:
83     ::com::sun::star::uno::Any  maAny;
84     rtl::OUString               maStrName;
85     ::com::sun::star::uno::Reference < ::com::sun::star::io::XOutputStream > mxBase64Stream;
86 
87 public:
88     TYPEINFO();
89 
90     XMLBitmapStyleContext( SvXMLImport& rImport,  sal_uInt16 nPrfx,  const rtl::OUString& rLName,
91                            const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttrList );
92     virtual ~XMLBitmapStyleContext();
93 
94     virtual SvXMLImportContext *CreateChildContext(
95             sal_uInt16 nPrefix,
96             const ::rtl::OUString& rLocalName,
97             const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList > & xAttrList );
98 
99     virtual void EndElement();
100 
101     virtual sal_Bool IsTransient() const;
102 };
103 
104 //////////////////////////////////////////////////////////////////////////////
105 // draw:transparency context
106 
107 class XMLTransGradientStyleContext: public SvXMLStyleContext
108 {
109 private:
110     ::com::sun::star::uno::Any  maAny;
111     rtl::OUString               maStrName;
112 
113 public:
114     TYPEINFO();
115 
116     XMLTransGradientStyleContext( SvXMLImport& rImport,  sal_uInt16 nPrfx,  const rtl::OUString& rLName,
117                            const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttrList );
118     virtual ~XMLTransGradientStyleContext();
119 
120     virtual void EndElement();
121 
122     virtual sal_Bool IsTransient() const;
123 };
124 
125 //////////////////////////////////////////////////////////////////////////////
126 // draw:marker context
127 
128 class XMLMarkerStyleContext: public SvXMLStyleContext
129 {
130 private:
131     ::com::sun::star::uno::Any  maAny;
132     rtl::OUString               maStrName;
133 
134 public:
135     TYPEINFO();
136 
137     XMLMarkerStyleContext( SvXMLImport& rImport,  sal_uInt16 nPrfx,  const rtl::OUString& rLName,
138                            const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttrList );
139     virtual ~XMLMarkerStyleContext();
140 
141     virtual void EndElement();
142 
143     virtual sal_Bool IsTransient() const;
144 };
145 
146 //////////////////////////////////////////////////////////////////////////////
147 // draw:marker context
148 
149 class XMLDashStyleContext: public SvXMLStyleContext
150 {
151 private:
152     ::com::sun::star::uno::Any  maAny;
153     rtl::OUString               maStrName;
154 
155 public:
156     TYPEINFO();
157 
158     XMLDashStyleContext( SvXMLImport& rImport,  sal_uInt16 nPrfx,  const rtl::OUString& rLName,
159                            const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttrList );
160     virtual ~XMLDashStyleContext();
161 
162     virtual void EndElement();
163 
164     virtual sal_Bool IsTransient() const;
165 };
166 
167 #endif  // _XMLOFF_FILLSTYLECONTEXTS_HXX_
168