xref: /AOO41X/main/xmloff/source/style/FillStyleContext.hxx (revision ecfe53c5d1886e1e0d215b0d140d05282ab1c477)
1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 
24 #ifndef _XMLOFF_FILLSTYLECONTEXTS_HXX_
25 #define _XMLOFF_FILLSTYLECONTEXTS_HXX_
26 
27 #include <com/sun/star/io/XOutputStream.hpp>
28 #include <xmloff/xmlstyle.hxx>
29 #include<rtl/ustring.hxx>
30 
31 //////////////////////////////////////////////////////////////////////////////
32 // draw:gardient context
33 
34 class XMLGradientStyleContext: public SvXMLStyleContext
35 {
36 private:
37     ::com::sun::star::uno::Any  maAny;
38     rtl::OUString               maStrName;
39 
40 public:
41     TYPEINFO();
42 
43     XMLGradientStyleContext( SvXMLImport& rImport,  sal_uInt16 nPrfx,  const rtl::OUString& rLName,
44                            const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttrList );
45     virtual ~XMLGradientStyleContext();
46 
47     virtual void EndElement();
48 
49     virtual sal_Bool IsTransient() const;
50 };
51 
52 //////////////////////////////////////////////////////////////////////////////
53 // draw:hatch context
54 
55 class XMLHatchStyleContext: public SvXMLStyleContext
56 {
57 private:
58     ::com::sun::star::uno::Any  maAny;
59     rtl::OUString               maStrName;
60 
61 public:
62     TYPEINFO();
63 
64     XMLHatchStyleContext( SvXMLImport& rImport,  sal_uInt16 nPrfx,  const rtl::OUString& rLName,
65                            const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttrList );
66     virtual ~XMLHatchStyleContext();
67 
68     virtual void EndElement();
69 
70     virtual sal_Bool IsTransient() const;
71 };
72 
73 //////////////////////////////////////////////////////////////////////////////
74 // draw:fill-image context
75 
76 class XMLBitmapStyleContext: public SvXMLStyleContext
77 {
78 private:
79     ::com::sun::star::uno::Any  maAny;
80     rtl::OUString               maStrName;
81     ::com::sun::star::uno::Reference < ::com::sun::star::io::XOutputStream > mxBase64Stream;
82 
83 public:
84     TYPEINFO();
85 
86     XMLBitmapStyleContext( SvXMLImport& rImport,  sal_uInt16 nPrfx,  const rtl::OUString& rLName,
87                            const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttrList );
88     virtual ~XMLBitmapStyleContext();
89 
90     virtual SvXMLImportContext *CreateChildContext(
91             sal_uInt16 nPrefix,
92             const ::rtl::OUString& rLocalName,
93             const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList > & xAttrList );
94 
95     virtual void EndElement();
96 
97     virtual sal_Bool IsTransient() const;
98 };
99 
100 //////////////////////////////////////////////////////////////////////////////
101 // draw:transparency context
102 
103 class XMLTransGradientStyleContext: public SvXMLStyleContext
104 {
105 private:
106     ::com::sun::star::uno::Any  maAny;
107     rtl::OUString               maStrName;
108 
109 public:
110     TYPEINFO();
111 
112     XMLTransGradientStyleContext( SvXMLImport& rImport,  sal_uInt16 nPrfx,  const rtl::OUString& rLName,
113                            const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttrList );
114     virtual ~XMLTransGradientStyleContext();
115 
116     virtual void EndElement();
117 
118     virtual sal_Bool IsTransient() const;
119 };
120 
121 //////////////////////////////////////////////////////////////////////////////
122 // draw:marker context
123 
124 class XMLMarkerStyleContext: public SvXMLStyleContext
125 {
126 private:
127     ::com::sun::star::uno::Any  maAny;
128     rtl::OUString               maStrName;
129 
130 public:
131     TYPEINFO();
132 
133     XMLMarkerStyleContext( SvXMLImport& rImport,  sal_uInt16 nPrfx,  const rtl::OUString& rLName,
134                            const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttrList );
135     virtual ~XMLMarkerStyleContext();
136 
137     virtual void EndElement();
138 
139     virtual sal_Bool IsTransient() const;
140 };
141 
142 //////////////////////////////////////////////////////////////////////////////
143 // draw:marker context
144 
145 class XMLDashStyleContext: public SvXMLStyleContext
146 {
147 private:
148     ::com::sun::star::uno::Any  maAny;
149     rtl::OUString               maStrName;
150 
151 public:
152     TYPEINFO();
153 
154     XMLDashStyleContext( SvXMLImport& rImport,  sal_uInt16 nPrfx,  const rtl::OUString& rLName,
155                            const com::sun::star::uno::Reference< com::sun::star::xml::sax::XAttributeList >& xAttrList );
156     virtual ~XMLDashStyleContext();
157 
158     virtual void EndElement();
159 
160     virtual sal_Bool IsTransient() const;
161 };
162 
163 #endif  // _XMLOFF_FILLSTYLECONTEXTS_HXX_
164