Line data Source code
1 : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : /*
3 : * This file is part of the LibreOffice project.
4 : *
5 : * This Source Code Form is subject to the terms of the Mozilla Public
6 : * License, v. 2.0. If a copy of the MPL was not distributed with this
7 : * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 : *
9 : * This file incorporates work covered by the following license notice:
10 : *
11 : * Licensed to the Apache Software Foundation (ASF) under one or more
12 : * contributor license agreements. See the NOTICE file distributed
13 : * with this work for additional information regarding copyright
14 : * ownership. The ASF licenses this file to you under the Apache
15 : * License, Version 2.0 (the "License"); you may not use this file
16 : * except in compliance with the License. You may obtain a copy of
17 : * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 : */
19 :
20 : #include <tools/stream.hxx>
21 : #include <tools/resid.hxx>
22 : #include <com/sun/star/uno/Any.hxx>
23 : #include <com/sun/star/uno/Sequence.hxx>
24 : #include <unotools/useroptions.hxx>
25 : #include <tools/shl.hxx>
26 : #include <swmodule.hxx>
27 : #include "labimg.hxx"
28 : #include "cmdid.h"
29 : #include "swtypes.hxx"
30 : #include <unomid.h>
31 :
32 : using namespace utl;
33 : using namespace ::com::sun::star::uno;
34 :
35 : using ::rtl::OUString;
36 :
37 0 : SwLabItem::SwLabItem() :
38 :
39 : SfxPoolItem(FN_LABEL),
40 : lLeft (0),
41 : lUpper(0),
42 : nCols (1),
43 : nRows (1),
44 : nCol (1),
45 0 : nRow (1)
46 : {
47 : bAddr =
48 : bCont =
49 0 : bSynchron = sal_False;
50 0 : bPage = sal_True;
51 : lHDist =
52 : lVDist =
53 : lWidth =
54 : lHeight =
55 : lPWidth =
56 0 : lPHeight = 5669; // 10 cm
57 0 : }
58 :
59 0 : SwLabItem::SwLabItem(const SwLabItem& rItem) :
60 0 : SfxPoolItem(FN_LABEL)
61 : {
62 0 : *this = rItem;
63 0 : }
64 :
65 0 : SwLabItem& SwLabItem::operator =(const SwLabItem& rItem)
66 : {
67 0 : bAddr = rItem.bAddr;
68 0 : aWriting = rItem.aWriting;
69 0 : bCont = rItem.bCont;
70 0 : sDBName = rItem.sDBName;
71 0 : aLstMake = rItem.aLstMake;
72 0 : aLstType = rItem.aLstType;
73 0 : aMake = rItem.aMake;
74 0 : aType = rItem.aType;
75 0 : bPage = rItem.bPage;
76 0 : bSynchron = rItem.bSynchron;
77 0 : aBin = rItem.aBin;
78 0 : nCol = rItem.nCol;
79 0 : nRow = rItem.nRow;
80 0 : lHDist = rItem.lHDist;
81 0 : lVDist = rItem.lVDist;
82 0 : lWidth = rItem.lWidth;
83 0 : lHeight = rItem.lHeight;
84 0 : lLeft = rItem.lLeft;
85 0 : lUpper = rItem.lUpper;
86 0 : nCols = rItem.nCols;
87 0 : nRows = rItem.nRows;
88 0 : lPWidth = rItem.lPWidth;
89 0 : lPHeight = rItem.lPHeight;
90 0 : aPrivFirstName = rItem.aPrivFirstName;
91 0 : aPrivName = rItem.aPrivName;
92 0 : aPrivShortCut = rItem.aPrivShortCut;
93 0 : aPrivFirstName2 = rItem.aPrivFirstName2;
94 0 : aPrivName2 = rItem.aPrivName2;
95 0 : aPrivShortCut2 = rItem.aPrivShortCut2;
96 0 : aPrivStreet = rItem.aPrivStreet;
97 0 : aPrivZip = rItem.aPrivZip;
98 0 : aPrivCity = rItem.aPrivCity;
99 0 : aPrivCountry = rItem.aPrivCountry;
100 0 : aPrivState = rItem.aPrivState;
101 0 : aPrivTitle = rItem.aPrivTitle;
102 0 : aPrivProfession = rItem.aPrivProfession;
103 0 : aPrivPhone = rItem.aPrivPhone;
104 0 : aPrivMobile = rItem.aPrivMobile;
105 0 : aPrivFax = rItem.aPrivFax;
106 0 : aPrivWWW = rItem.aPrivWWW;
107 0 : aPrivMail = rItem.aPrivMail;
108 0 : aCompCompany = rItem.aCompCompany;
109 0 : aCompCompanyExt = rItem.aCompCompanyExt;
110 0 : aCompSlogan = rItem.aCompSlogan;
111 0 : aCompStreet = rItem.aCompStreet;
112 0 : aCompZip = rItem.aCompZip;
113 0 : aCompCity = rItem.aCompCity;
114 0 : aCompCountry = rItem.aCompCountry;
115 0 : aCompState = rItem.aCompState;
116 0 : aCompPosition = rItem.aCompPosition;
117 0 : aCompPhone = rItem.aCompPhone;
118 0 : aCompMobile = rItem.aCompMobile;
119 0 : aCompFax = rItem.aCompFax;
120 0 : aCompWWW = rItem.aCompWWW;
121 0 : aCompMail = rItem.aCompMail;
122 0 : sGlossaryGroup = rItem.sGlossaryGroup;
123 0 : sGlossaryBlockName = rItem.sGlossaryBlockName;
124 0 : return *this;
125 : }
126 :
127 0 : int SwLabItem::operator ==(const SfxPoolItem& rItem) const
128 : {
129 0 : const SwLabItem& rLab = (const SwLabItem&) rItem;
130 :
131 : return bAddr == rLab.bAddr &&
132 : bCont == rLab.bCont &&
133 : bPage == rLab.bPage &&
134 : bSynchron == rLab.bSynchron &&
135 0 : aBin == rLab.aBin &&
136 : nCol == rLab.nCol &&
137 : nRow == rLab.nRow &&
138 : lHDist == rLab.lHDist &&
139 : lVDist == rLab.lVDist &&
140 : lWidth == rLab.lWidth &&
141 : lHeight == rLab.lHeight &&
142 : lLeft == rLab.lLeft &&
143 : lUpper == rLab.lUpper &&
144 : nCols == rLab.nCols &&
145 : nRows == rLab.nRows &&
146 : lPWidth == rLab.lPWidth &&
147 : lPHeight == rLab.lPHeight&&
148 0 : aWriting == rLab.aWriting&&
149 0 : aMake == rLab.aMake &&
150 0 : aType == rLab.aType &&
151 0 : aLstMake == rLab.aLstMake&&
152 0 : aLstType == rLab.aLstType&&
153 0 : sDBName == rLab.sDBName &&
154 0 : aPrivFirstName == rLab.aPrivFirstName&&
155 0 : aPrivName == rLab.aPrivName&&
156 0 : aPrivShortCut == rLab.aPrivShortCut&&
157 0 : aPrivFirstName2 == rLab.aPrivFirstName2&&
158 0 : aPrivName2 == rLab.aPrivName2&&
159 0 : aPrivShortCut2 == rLab.aPrivShortCut2&&
160 0 : aPrivStreet == rLab.aPrivStreet&&
161 0 : aPrivZip == rLab.aPrivZip&&
162 0 : aPrivCity == rLab.aPrivCity&&
163 0 : aPrivCountry == rLab.aPrivCountry&&
164 0 : aPrivState == rLab.aPrivState&&
165 0 : aPrivTitle == rLab.aPrivTitle&&
166 0 : aPrivProfession == rLab.aPrivProfession&&
167 0 : aPrivPhone == rLab.aPrivPhone&&
168 0 : aPrivMobile == rLab.aPrivMobile&&
169 0 : aPrivFax == rLab.aPrivFax&&
170 0 : aPrivWWW == rLab.aPrivWWW&&
171 0 : aPrivMail == rLab.aPrivMail&&
172 0 : aCompCompany == rLab.aCompCompany&&
173 0 : aCompCompanyExt == rLab.aCompCompanyExt&&
174 0 : aCompSlogan == rLab.aCompSlogan&&
175 0 : aCompStreet == rLab.aCompStreet&&
176 0 : aCompZip == rLab.aCompZip&&
177 0 : aCompCity == rLab.aCompCity&&
178 0 : aCompCountry == rLab.aCompCountry&&
179 0 : aCompState == rLab.aCompState&&
180 0 : aCompPosition == rLab.aCompPosition&&
181 0 : aCompPhone == rLab.aCompPhone&&
182 0 : aCompMobile == rLab.aCompMobile&&
183 0 : aCompFax == rLab.aCompFax&&
184 0 : aCompWWW == rLab.aCompWWW&&
185 0 : aCompMail == rLab.aCompMail &&
186 0 : sGlossaryGroup == rLab.sGlossaryGroup &&
187 0 : sGlossaryBlockName == rLab.sGlossaryBlockName;
188 : }
189 :
190 0 : SfxPoolItem* SwLabItem::Clone(SfxItemPool*) const
191 : {
192 0 : return new SwLabItem(*this);
193 : }
194 :
195 0 : Sequence<rtl::OUString> SwLabCfgItem::GetPropertyNames()
196 : {
197 : static const char* aLabelPropNames[] =
198 : {
199 : "Medium/Continous", // 0
200 : "Medium/Brand", // 1
201 : "Medium/Type", // 2
202 : "Format/Column", // 3
203 : "Format/Row", // 4
204 : "Format/HorizontalDistance",// 5
205 : "Format/VerticalDistance", // 6
206 : "Format/Width", // 7
207 : "Format/Height", // 8
208 : "Format/LeftMargin", // 9
209 : "Format/TopMargin", //10
210 : "Format/PageWidth", //11
211 : "Format/PageHeight", //12
212 : "Option/Synchronize", //13
213 : "Option/Page", //14
214 : "Option/Column", //15
215 : "Option/Row", //16
216 : "Inscription/UseAddress", //17
217 : "Inscription/Address", //18
218 : "Inscription/Database" //19
219 : };
220 : static const char* aBusinessPropNames[] =
221 : {
222 : "PrivateAddress/FirstName", // 0
223 : "PrivateAddress/Name", // 1
224 : "PrivateAddress/ShortCut", // 2
225 : "PrivateAddress/SecondFirstName", // 3
226 : "PrivateAddress/SecondName", // 4
227 : "PrivateAddress/SecondShortCut", // 5
228 : "PrivateAddress/Street", // 6
229 : "PrivateAddress/Zip", // 7
230 : "PrivateAddress/City", // 8
231 : "PrivateAddress/Country", // 9
232 : "PrivateAddress/State", // 10
233 : "PrivateAddress/Title", // 11
234 : "PrivateAddress/Profession", // 12
235 : "PrivateAddress/Phone", // 13
236 : "PrivateAddress/Mobile", // 14
237 : "PrivateAddress/Fax", // 15
238 : "PrivateAddress/WebAddress", // 16
239 : "PrivateAddress/Email", // 17
240 : "BusinessAddress/Company", // 18
241 : "BusinessAddress/CompanyExt", // 19
242 : "BusinessAddress/Slogan", // 20
243 : "BusinessAddress/Street", // 21
244 : "BusinessAddress/Zip", // 22
245 : "BusinessAddress/City", // 23
246 : "BusinessAddress/Country", // 24
247 : "BusinessAddress/State", // 25
248 : "BusinessAddress/Position", // 26
249 : "BusinessAddress/Phone", // 27
250 : "BusinessAddress/Mobile", // 28
251 : "BusinessAddress/Fax", // 29
252 : "BusinessAddress/WebAddress", // 30
253 : "BusinessAddress/Email", // 31
254 : "AutoText/Group", // 32
255 : "AutoText/Block" // 33
256 : };
257 0 : const int nBusinessCount = bIsLabel ? 0 : 34;
258 0 : const int nLabelCount = bIsLabel ? 20 : 17;
259 0 : Sequence<OUString> aNames(nBusinessCount + nLabelCount);
260 0 : OUString* pNames = aNames.getArray();
261 0 : int nIndex = 0;
262 0 : for(int nLabel = 0; nLabel < nLabelCount; nLabel++)
263 0 : pNames[nIndex++] = OUString::createFromAscii(aLabelPropNames[nLabel]);
264 0 : for(int nBusiness = 0; nBusiness < nBusinessCount; nBusiness++)
265 0 : pNames[nIndex++] = OUString::createFromAscii(aBusinessPropNames[nBusiness]);
266 0 : return aNames;
267 : }
268 :
269 0 : SwLabCfgItem::SwLabCfgItem(sal_Bool bLabel) :
270 : ConfigItem(bLabel ? OUString("Office.Writer/Label") : OUString("Office.Writer/BusinessCard")),
271 0 : bIsLabel(bLabel)
272 : {
273 0 : Sequence<OUString> aNames = GetPropertyNames();
274 0 : Sequence<Any> aValues = GetProperties(aNames);
275 0 : EnableNotification(aNames);
276 0 : const Any* pValues = aValues.getConstArray();
277 : OSL_ENSURE(aValues.getLength() == aNames.getLength(), "GetProperties failed");
278 0 : sal_Bool bNoConfigValues = sal_True;
279 0 : if(aValues.getLength() == aNames.getLength())
280 : {
281 0 : for(int nProp = 0, nProperty = 0; nProp < aNames.getLength(); nProp++, nProperty++)
282 : {
283 :
284 0 : if(pValues[nProp].hasValue())
285 : {
286 : //to have a contiuous switch an offset is added
287 0 : if(nProp == 17 && !bIsLabel)
288 0 : nProperty += 3;
289 0 : if(nProperty >= 20)
290 0 : bNoConfigValues = sal_False;
291 0 : switch(nProperty)
292 : {
293 0 : case 0: aItem.bCont = *(sal_Bool*)pValues[nProp].getValue(); break;// "Medium/Continous",
294 0 : case 1: pValues[nProp] >>= aItem.aMake; break;// "Medium/Brand",
295 0 : case 2: pValues[nProp] >>= aItem.aType; break;// "Medium/Type",
296 0 : case 3: pValues[nProp] >>= aItem.nCols; break;// "Format/Column",
297 0 : case 4: pValues[nProp] >>= aItem.nRows; break;// "Format/Row",
298 : case 5:
299 0 : pValues[nProp] >>= aItem.lHDist;
300 0 : aItem.lHDist = MM100_TO_TWIP(aItem.lHDist);
301 0 : break;// "Format/HorizontalDistance",
302 : case 6:
303 0 : pValues[nProp] >>= aItem.lVDist;
304 0 : aItem.lVDist = MM100_TO_TWIP(aItem.lVDist);
305 0 : break;// "Format/VerticalDistance",
306 : case 7:
307 0 : pValues[nProp] >>= aItem.lWidth;
308 0 : aItem.lWidth = MM100_TO_TWIP(aItem.lWidth);
309 0 : break;// "Format/Width",
310 : case 8:
311 0 : pValues[nProp] >>= aItem.lHeight;
312 0 : aItem.lHeight = MM100_TO_TWIP(aItem.lHeight);
313 0 : break;// "Format/Height",
314 : case 9:
315 0 : pValues[nProp] >>= aItem.lLeft;
316 0 : aItem.lLeft = MM100_TO_TWIP(aItem.lLeft);
317 0 : break;// "Format/LeftMargin",
318 : case 10:
319 0 : pValues[nProp] >>= aItem.lUpper;
320 0 : aItem.lUpper = MM100_TO_TWIP(aItem.lUpper);
321 0 : break;// "Format/TopMargin",
322 : case 11:
323 0 : pValues[nProp] >>= aItem.lPWidth;
324 0 : aItem.lPWidth = MM100_TO_TWIP(aItem.lPWidth);
325 0 : break;// "Format/PageWidth",
326 : case 12:
327 0 : pValues[nProp] >>= aItem.lPHeight;
328 0 : aItem.lPHeight = MM100_TO_TWIP(aItem.lPHeight);
329 0 : break;// "Format/PageHeight",
330 0 : case 13: aItem.bSynchron = *(sal_Bool*)pValues[nProp].getValue(); break;// "Option/Synchronize",
331 0 : case 14: aItem.bPage = *(sal_Bool*)pValues[nProp].getValue(); break;// "Option/Page",
332 0 : case 15: pValues[nProp] >>= aItem.nCol; break;// "Option/Column",
333 0 : case 16: pValues[nProp] >>= aItem.nRow; break;// "Option/Row"
334 0 : case 17: aItem.bAddr = *(sal_Bool*)pValues[nProp].getValue(); break;// "Inscription/UseAddress",
335 0 : case 18: pValues[nProp] >>= aItem.aWriting; break;// "Inscription/Address",
336 0 : case 19: pValues[nProp] >>= aItem.sDBName; break;// "Inscription/Database"
337 0 : case 20: pValues[nProp] >>= aItem.aPrivFirstName; break;// "PrivateAddress/FirstName",
338 0 : case 21: pValues[nProp] >>= aItem.aPrivName; break;// "PrivateAddress/Name",
339 0 : case 22: pValues[nProp] >>= aItem.aPrivShortCut; break;// "PrivateAddress/ShortCut",
340 0 : case 23: pValues[nProp] >>= aItem.aPrivFirstName2; break;// "PrivateAddress/SecondFirstName",
341 0 : case 24: pValues[nProp] >>= aItem.aPrivName2; break;// "PrivateAddress/SecondName",
342 0 : case 25: pValues[nProp] >>= aItem.aPrivShortCut2; break;// "PrivateAddress/SecondShortCut",
343 0 : case 26: pValues[nProp] >>= aItem.aPrivStreet; break;// "PrivateAddress/Street",
344 0 : case 27: pValues[nProp] >>= aItem.aPrivZip; break;// "PrivateAddress/Zip",
345 0 : case 28: pValues[nProp] >>= aItem.aPrivCity; break;// "PrivateAddress/City",
346 0 : case 29: pValues[nProp] >>= aItem.aPrivCountry; break;// "PrivateAddress/Country",
347 0 : case 30: pValues[nProp] >>= aItem.aPrivState; break;// "PrivateAddress/State",
348 0 : case 31: pValues[nProp] >>= aItem.aPrivTitle; break;// "PrivateAddress/Title",
349 0 : case 32: pValues[nProp] >>= aItem.aPrivProfession; break;// "PrivateAddress/Profession",
350 0 : case 33: pValues[nProp] >>= aItem.aPrivPhone; break;// "PrivateAddress/Phone",
351 0 : case 34: pValues[nProp] >>= aItem.aPrivMobile; break;// "PrivateAddress/Mobile",
352 0 : case 35: pValues[nProp] >>= aItem.aPrivFax; break;// "PrivateAddress/Fax",
353 0 : case 36: pValues[nProp] >>= aItem.aPrivWWW; break;// "PrivateAddress/WebAddress",
354 0 : case 37: pValues[nProp] >>= aItem.aPrivMail; break;// "PrivateAddress/Email",
355 0 : case 38: pValues[nProp] >>= aItem.aCompCompany; break;// "BusinessAddress/Company",
356 0 : case 39: pValues[nProp] >>= aItem.aCompCompanyExt; break;// "BusinessAddress/CompanyExt",
357 0 : case 40: pValues[nProp] >>= aItem.aCompSlogan; break;// "BusinessAddress/Slogan",
358 0 : case 41: pValues[nProp] >>= aItem.aCompStreet; break;// "BusinessAddress/Street",
359 0 : case 42: pValues[nProp] >>= aItem.aCompZip; break;// "BusinessAddress/Zip",
360 0 : case 43: pValues[nProp] >>= aItem.aCompCity; break;// "BusinessAddress/City",
361 0 : case 44: pValues[nProp] >>= aItem.aCompCountry; break;// "BusinessAddress/Country",
362 0 : case 45: pValues[nProp] >>= aItem.aCompState; break;// "BusinessAddress/State",
363 0 : case 46: pValues[nProp] >>= aItem.aCompPosition; break;// "BusinessAddress/Position",
364 0 : case 47: pValues[nProp] >>= aItem.aCompPhone; break;// "BusinessAddress/Phone",
365 0 : case 48: pValues[nProp] >>= aItem.aCompMobile; break;// "BusinessAddress/Mobile",
366 0 : case 49: pValues[nProp] >>= aItem.aCompFax; break;// "BusinessAddress/Fax",
367 0 : case 50: pValues[nProp] >>= aItem.aCompWWW; break;// "BusinessAddress/WebAddress",
368 0 : case 51: pValues[nProp] >>= aItem.aCompMail; break;// "BusinessAddress/Email",
369 0 : case 52: pValues[nProp] >>= aItem.sGlossaryGroup; break;// "AutoText/Group"
370 0 : case 53: pValues[nProp] >>= aItem.sGlossaryBlockName; break;// "AutoText/Block"
371 : }
372 : }
373 : }
374 : }
375 0 : if(!bIsLabel && bNoConfigValues)
376 : {
377 :
378 0 : SvtUserOptions& rUserOpt = SW_MOD()->GetUserOptions();
379 0 : aItem.aPrivFirstName = rUserOpt.GetFirstName();
380 0 : aItem.aPrivName = rUserOpt.GetLastName();
381 0 : aItem.aPrivShortCut = rUserOpt.GetID();
382 0 : aItem.aCompCompany = rUserOpt.GetCompany();
383 0 : aItem.aCompStreet = aItem.aPrivStreet = rUserOpt.GetStreet();
384 :
385 0 : aItem.aCompCountry = aItem.aPrivCountry = rUserOpt.GetCountry();
386 0 : aItem.aCompZip = aItem.aPrivZip= rUserOpt.GetZip();
387 0 : aItem.aCompCity = aItem.aPrivCity = rUserOpt.GetCity();
388 0 : aItem.aPrivTitle = rUserOpt.GetTitle();
389 0 : aItem.aCompPosition = rUserOpt.GetPosition();
390 0 : aItem.aPrivPhone = rUserOpt.GetTelephoneHome();
391 0 : aItem.aCompPhone = rUserOpt.GetTelephoneWork();
392 0 : aItem.aCompFax = aItem.aPrivFax = rUserOpt.GetFax();
393 0 : aItem.aCompMail = aItem.aPrivMail = rUserOpt.GetEmail();
394 0 : aItem.aCompState = aItem.aPrivState = rUserOpt.GetState();
395 0 : aItem.bSynchron = sal_True;
396 0 : SetModified();
397 0 : }
398 0 : }
399 :
400 0 : void SwLabCfgItem::Notify( const ::com::sun::star::uno::Sequence< rtl::OUString >& ) {}
401 :
402 0 : void SwLabCfgItem::Commit()
403 : {
404 0 : Sequence<OUString> aNames = GetPropertyNames();
405 0 : Sequence<Any> aValues(aNames.getLength());
406 0 : Any* pValues = aValues.getArray();
407 :
408 0 : const Type& rType = ::getBooleanCppuType();
409 0 : for(int nProp = 0, nProperty = 0; nProp < aNames.getLength(); nProp++, nProperty++)
410 : {
411 : //to have a contiuous switch an offset is added
412 0 : if(nProp == 17 && !bIsLabel)
413 0 : nProperty += 3;
414 0 : switch(nProperty)
415 : {
416 0 : case 0: pValues[nProp].setValue(&aItem.bCont, rType); break;// "Medium/Continous",
417 0 : case 1: pValues[nProp] <<= aItem.aMake; break;// "Medium/Brand",
418 0 : case 2: pValues[nProp] <<= aItem.aType; break;// "Medium/Type",
419 0 : case 3: pValues[nProp] <<= aItem.nCols; break;// "Format/Column",
420 0 : case 4: pValues[nProp] <<= aItem.nRows; break;// "Format/Row",
421 0 : case 5: pValues[nProp] <<= static_cast<sal_Int32>(TWIP_TO_MM100(aItem.lHDist));break;// "Format/HorizontalDistance",
422 0 : case 6: pValues[nProp] <<= static_cast<sal_Int32>(TWIP_TO_MM100(aItem.lVDist));break;// "Format/VerticalDistance",
423 0 : case 7: pValues[nProp] <<= static_cast<sal_Int32>(TWIP_TO_MM100(aItem.lWidth)); break;// "Format/Width",
424 0 : case 8: pValues[nProp] <<= static_cast<sal_Int32>(TWIP_TO_MM100(aItem.lHeight)); break;// "Format/Height",
425 0 : case 9: pValues[nProp] <<= static_cast<sal_Int32>(TWIP_TO_MM100(aItem.lLeft)); break;// "Format/LeftMargin",
426 0 : case 10: pValues[nProp] <<= static_cast<sal_Int32>(TWIP_TO_MM100(aItem.lUpper)); break;// "Format/TopMargin",
427 0 : case 11: pValues[nProp] <<= static_cast<sal_Int32>(TWIP_TO_MM100(aItem.lPWidth)); break;// "Format/Page Width",
428 0 : case 12: pValues[nProp] <<= static_cast<sal_Int32>(TWIP_TO_MM100(aItem.lPHeight)); break;// "Format/PageHeight",
429 0 : case 13: pValues[nProp].setValue(&aItem.bSynchron, rType); break;// "Option/Synchronize",
430 0 : case 14: pValues[nProp].setValue(&aItem.bPage, rType); break;// "Option/Page",
431 0 : case 15: pValues[nProp] <<= aItem.nCol; break;// "Option/Column",
432 0 : case 16: pValues[nProp] <<= aItem.nRow; break;// "Option/Row"
433 0 : case 17: pValues[nProp].setValue(&aItem.bAddr, rType); break;// "Inscription/UseAddress",
434 0 : case 18: pValues[nProp] <<= aItem.aWriting; break;// "Inscription/Address",
435 0 : case 19: pValues[nProp] <<= aItem.sDBName; break;// "Inscription/Database"
436 0 : case 20: pValues[nProp] <<= aItem.aPrivFirstName; break;// "PrivateAddress/FirstName",
437 0 : case 21: pValues[nProp] <<= aItem.aPrivName; break;// "PrivateAddress/Name",
438 0 : case 22: pValues[nProp] <<= aItem.aPrivShortCut; break;// "PrivateAddress/ShortCut",
439 0 : case 23: pValues[nProp] <<= aItem.aPrivFirstName2; break;// "PrivateAddress/SecondFirstName",
440 0 : case 24: pValues[nProp] <<= aItem.aPrivName2; break;// "PrivateAddress/SecondName",
441 0 : case 25: pValues[nProp] <<= aItem.aPrivShortCut2; break;// "PrivateAddress/SecondShortCut",
442 0 : case 26: pValues[nProp] <<= aItem.aPrivStreet; break;// "PrivateAddress/Street",
443 0 : case 27: pValues[nProp] <<= aItem.aPrivZip; break;// "PrivateAddress/Zip",
444 0 : case 28: pValues[nProp] <<= aItem.aPrivCity; break;// "PrivateAddress/City",
445 0 : case 29: pValues[nProp] <<= aItem.aPrivCountry; break;// "PrivateAddress/Country",
446 0 : case 30: pValues[nProp] <<= aItem.aPrivState; break;// "PrivateAddress/State",
447 0 : case 31: pValues[nProp] <<= aItem.aPrivTitle; break;// "PrivateAddress/Title",
448 0 : case 32: pValues[nProp] <<= aItem.aPrivProfession; break;// "PrivateAddress/Profession",
449 0 : case 33: pValues[nProp] <<= aItem.aPrivPhone; break;// "PrivateAddress/Phone",
450 0 : case 34: pValues[nProp] <<= aItem.aPrivMobile; break;// "PrivateAddress/Mobile",
451 0 : case 35: pValues[nProp] <<= aItem.aPrivFax; break;// "PrivateAddress/Fax",
452 0 : case 36: pValues[nProp] <<= aItem.aPrivWWW; break;// "PrivateAddress/WebAddress",
453 0 : case 37: pValues[nProp] <<= aItem.aPrivMail; break;// "PrivateAddress/Email",
454 0 : case 38: pValues[nProp] <<= aItem.aCompCompany; break;// "BusinessAddress/Company",
455 0 : case 39: pValues[nProp] <<= aItem.aCompCompanyExt; break;// "BusinessAddress/CompanyExt",
456 0 : case 40: pValues[nProp] <<= aItem.aCompSlogan; break;// "BusinessAddress/Slogan",
457 0 : case 41: pValues[nProp] <<= aItem.aCompStreet; break;// "BusinessAddress/Street",
458 0 : case 42: pValues[nProp] <<= aItem.aCompZip; break;// "BusinessAddress/Zip",
459 0 : case 43: pValues[nProp] <<= aItem.aCompCity; break;// "BusinessAddress/City",
460 0 : case 44: pValues[nProp] <<= aItem.aCompCountry; break;// "BusinessAddress/Country",
461 0 : case 45: pValues[nProp] <<= aItem.aCompState; break;// "BusinessAddress/State",
462 0 : case 46: pValues[nProp] <<= aItem.aCompPosition; break;// "BusinessAddress/Position",
463 0 : case 47: pValues[nProp] <<= aItem.aCompPhone; break;// "BusinessAddress/Phone",
464 0 : case 48: pValues[nProp] <<= aItem.aCompMobile; break;// "BusinessAddress/Mobile",
465 0 : case 49: pValues[nProp] <<= aItem.aCompFax; break;// "BusinessAddress/Fax",
466 0 : case 50: pValues[nProp] <<= aItem.aCompWWW; break;// "BusinessAddress/WebAddress",
467 0 : case 51: pValues[nProp] <<= aItem.aCompMail; break;// "BusinessAddress/Email",
468 0 : case 52: pValues[nProp] <<= aItem.sGlossaryGroup; break;// "AutoText/Group"
469 0 : case 53: pValues[nProp] <<= aItem.sGlossaryBlockName; break;// "AutoText/Block"
470 : }
471 : }
472 0 : PutProperties(aNames, aValues);
473 0 : }
474 :
475 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|