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_PAGEMASTERPROPHDL_HXX_
25 #define _XMLOFF_PAGEMASTERPROPHDL_HXX_
26 
27 #include <xmloff/xmlprhdl.hxx>
28 #include <rtl/ustring.hxx>
29 #include <xmloff/xmltoken.hxx>
30 
31 
32 //______________________________________________________________________________
33 // property handler for style:page-usage (style::PageStyleLayout)
34 
35 class XMLPMPropHdl_PageStyleLayout : public XMLPropertyHandler
36 {
37 public:
38 	virtual					~XMLPMPropHdl_PageStyleLayout();
39 	virtual bool            equals(
40 								const ::com::sun::star::uno::Any& rAny1,
41 								const ::com::sun::star::uno::Any& rAny2
42 								) const;
43 	virtual sal_Bool		importXML(
44 								const ::rtl::OUString& rStrImpValue,
45 								::com::sun::star::uno::Any& rValue,
46 								const SvXMLUnitConverter& rUnitConverter
47 								) const;
48 	virtual sal_Bool		exportXML(
49 								::rtl::OUString& rStrExpValue,
50 								const ::com::sun::star::uno::Any& rValue,
51 								const SvXMLUnitConverter& rUnitConverter
52 								) const;
53 };
54 
55 
56 //______________________________________________________________________________
57 // property handler for style:num-format (style::NumberingType)
58 
59 class XMLPMPropHdl_NumFormat : public XMLPropertyHandler
60 {
61 public:
62 	virtual					~XMLPMPropHdl_NumFormat();
63 	virtual sal_Bool		importXML(
64 								const ::rtl::OUString& rStrImpValue,
65 								::com::sun::star::uno::Any& rValue,
66 								const SvXMLUnitConverter& rUnitConverter
67 								) const;
68 	virtual sal_Bool		exportXML(
69 								::rtl::OUString& rStrExpValue,
70 								const ::com::sun::star::uno::Any& rValue,
71 								const SvXMLUnitConverter& rUnitConverter
72 								) const;
73 };
74 
75 
76 //______________________________________________________________________________
77 // property handler for style:num-letter-sync (style::NumberingType)
78 
79 class XMLPMPropHdl_NumLetterSync : public XMLPropertyHandler
80 {
81 public:
82 	virtual					~XMLPMPropHdl_NumLetterSync();
83 	virtual sal_Bool		importXML(
84 								const ::rtl::OUString& rStrImpValue,
85 								::com::sun::star::uno::Any& rValue,
86 								const SvXMLUnitConverter& rUnitConverter
87 								) const;
88 	virtual sal_Bool		exportXML(
89 								::rtl::OUString& rStrExpValue,
90 								const ::com::sun::star::uno::Any& rValue,
91 								const SvXMLUnitConverter& rUnitConverter
92 								) const;
93 };
94 
95 
96 //______________________________________________________________________________
97 // property handler for style:paper-tray-number
98 
99 class XMLPMPropHdl_PaperTrayNumber : public XMLPropertyHandler
100 {
101 public:
102 	virtual					~XMLPMPropHdl_PaperTrayNumber();
103 	virtual sal_Bool		importXML(
104 								const ::rtl::OUString& rStrImpValue,
105 								::com::sun::star::uno::Any& rValue,
106 								const SvXMLUnitConverter& rUnitConverter
107 								) const;
108 	virtual sal_Bool		exportXML(
109 								::rtl::OUString& rStrExpValue,
110 								const ::com::sun::star::uno::Any& rValue,
111 								const SvXMLUnitConverter& rUnitConverter
112 								) const;
113 };
114 
115 
116 //______________________________________________________________________________
117 // property handler for style:print
118 
119 class XMLPMPropHdl_Print : public XMLPropertyHandler
120 {
121 protected:
122 	::rtl::OUString			sAttrValue;
123 
124 public:
125 							XMLPMPropHdl_Print( enum ::xmloff::token::XMLTokenEnum eValue );
126 	virtual					~XMLPMPropHdl_Print();
127 
128 	virtual sal_Bool		importXML(
129 								const ::rtl::OUString& rStrImpValue,
130 								::com::sun::star::uno::Any& rValue,
131 								const SvXMLUnitConverter& rUnitConverter
132 								) const;
133 	virtual sal_Bool		exportXML(
134 								::rtl::OUString& rStrExpValue,
135 								const ::com::sun::star::uno::Any& rValue,
136 								const SvXMLUnitConverter& rUnitConverter
137 								) const;
138 };
139 
140 //______________________________________________________________________________
141 // property handler for style:table-centering
142 
143 class XMLPMPropHdl_CenterHorizontal : public XMLPropertyHandler
144 {
145 public:
146 	virtual					~XMLPMPropHdl_CenterHorizontal();
147 	virtual sal_Bool		importXML(
148 								const ::rtl::OUString& rStrImpValue,
149 								::com::sun::star::uno::Any& rValue,
150 								const SvXMLUnitConverter& rUnitConverter
151 								) const;
152 	virtual sal_Bool		exportXML(
153 								::rtl::OUString& rStrExpValue,
154 								const ::com::sun::star::uno::Any& rValue,
155 								const SvXMLUnitConverter& rUnitConverter
156 								) const;
157 };
158 
159 class XMLPMPropHdl_CenterVertical : public XMLPropertyHandler
160 {
161 public:
162 	virtual					~XMLPMPropHdl_CenterVertical();
163 	virtual sal_Bool		importXML(
164 								const ::rtl::OUString& rStrImpValue,
165 								::com::sun::star::uno::Any& rValue,
166 								const SvXMLUnitConverter& rUnitConverter
167 								) const;
168 	virtual sal_Bool		exportXML(
169 								::rtl::OUString& rStrExpValue,
170 								const ::com::sun::star::uno::Any& rValue,
171 								const SvXMLUnitConverter& rUnitConverter
172 								) const;
173 };
174 
175 #endif
176 
177