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 : #ifndef _SVX3DITEMS_HXX
20 : #define _SVX3DITEMS_HXX
21 :
22 : #include <svl/intitem.hxx>
23 : #include <svl/eitem.hxx>
24 :
25 :
26 : #include <editeng/colritem.hxx>
27 : #include <svx/e3ditem.hxx>
28 : #include <svx/viewpt3d.hxx>
29 : #include <svx/svddef.hxx>
30 : #include "svx/svxdllapi.h"
31 :
32 : // Svx3D _3DOBJ_ Items
33 2769 : class SVX_DLLPUBLIC Svx3DPercentDiagonalItem : public SfxUInt16Item {
34 : public:
35 : Svx3DPercentDiagonalItem(sal_uInt16 nVal = 10);
36 : };
37 :
38 2680 : class Svx3DBackscaleItem : public SfxUInt16Item {
39 : public:
40 : SVX_DLLPUBLIC Svx3DBackscaleItem(sal_uInt16 nVal = 100);
41 : };
42 :
43 2680 : class Svx3DDepthItem : public SfxUInt32Item {
44 : public:
45 : SVX_DLLPUBLIC Svx3DDepthItem(sal_uInt32 nVal = 1000);
46 : };
47 :
48 2680 : class SVX_DLLPUBLIC Svx3DHorizontalSegmentsItem : public SfxUInt32Item {
49 : public:
50 : Svx3DHorizontalSegmentsItem(sal_uInt32 nVal = 24);
51 : };
52 :
53 2680 : class Svx3DVerticalSegmentsItem : public SfxUInt32Item {
54 : public:
55 : SVX_DLLPUBLIC Svx3DVerticalSegmentsItem(sal_uInt32 nVal = 24);
56 : };
57 :
58 2680 : class Svx3DEndAngleItem : public SfxUInt32Item {
59 : public:
60 : SVX_DLLPUBLIC Svx3DEndAngleItem(sal_uInt32 nVal = 3600);
61 : };
62 :
63 2680 : class SVX_DLLPUBLIC Svx3DDoubleSidedItem : public SfxBoolItem {
64 : public:
65 : Svx3DDoubleSidedItem(sal_Bool bVal = 0);
66 : };
67 :
68 : // #i28528#
69 : // Added extra Item (Bool) for chart2 to be able to show reduced line geometry
70 2680 : class Svx3DReducedLineGeometryItem : public SfxBoolItem {
71 : public:
72 : Svx3DReducedLineGeometryItem(sal_Bool bVal = 0);
73 : virtual SfxPoolItem* Create(SvStream& rIn, sal_uInt16 nItemVersion) const;
74 : virtual sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion) const;
75 : };
76 :
77 4144 : class SVX_DLLPUBLIC Svx3DNormalsKindItem : public SfxUInt16Item {
78 : public:
79 : Svx3DNormalsKindItem(sal_uInt16 nVal = 0);
80 :
81 : // use drawing::NormalsKind
82 : SVX_DLLPRIVATE virtual bool QueryValue( com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 ) const;
83 : SVX_DLLPRIVATE virtual bool PutValue( const com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 );
84 : SVX_DLLPRIVATE virtual SfxPoolItem* Clone(SfxItemPool* pPool = NULL) const;
85 : };
86 :
87 2680 : class Svx3DNormalsInvertItem : public SfxBoolItem {
88 : public:
89 : SVX_DLLPUBLIC Svx3DNormalsInvertItem(sal_Bool bVal = 0);
90 : };
91 :
92 8508 : class SVX_DLLPUBLIC Svx3DTextureProjectionXItem : public SfxUInt16Item {
93 : public:
94 : Svx3DTextureProjectionXItem(sal_uInt16 nVal = 0);
95 :
96 : // use drawing::TextureProjectionMode
97 : SVX_DLLPRIVATE virtual bool QueryValue( com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 ) const;
98 : SVX_DLLPRIVATE virtual bool PutValue( const com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 );
99 : SVX_DLLPRIVATE virtual SfxPoolItem* Clone(SfxItemPool* pPool = NULL) const;
100 : };
101 :
102 8508 : class SVX_DLLPUBLIC Svx3DTextureProjectionYItem : public SfxUInt16Item {
103 : public:
104 : Svx3DTextureProjectionYItem(sal_uInt16 nVal = 0);
105 :
106 : // use drawing::TextureProjectionMode
107 : virtual bool QueryValue( com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 ) const;
108 : virtual bool PutValue( const com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 );
109 : virtual SfxPoolItem* Clone(SfxItemPool* pPool = NULL) const;
110 : };
111 :
112 2680 : class Svx3DShadow3DItem : public SfxBoolItem {
113 : public:
114 : SVX_DLLPUBLIC Svx3DShadow3DItem(sal_Bool bVal = 0);
115 : };
116 :
117 2680 : class Svx3DMaterialColorItem : public SvxColorItem {
118 : public:
119 : Svx3DMaterialColorItem(const Color& rCol = Color(0x0000b8ff));
120 : };
121 :
122 2680 : class Svx3DMaterialEmissionItem : public SvxColorItem {
123 : public:
124 : SVX_DLLPUBLIC Svx3DMaterialEmissionItem(const Color& rCol = Color(0x00000000));
125 : };
126 :
127 2680 : class Svx3DMaterialSpecularItem : public SvxColorItem {
128 : public:
129 : SVX_DLLPUBLIC Svx3DMaterialSpecularItem(const Color& rCol = Color(0x00ffffff));
130 : };
131 :
132 2680 : class Svx3DMaterialSpecularIntensityItem : public SfxUInt16Item {
133 : public:
134 : SVX_DLLPUBLIC Svx3DMaterialSpecularIntensityItem(sal_uInt16 nVal = 15);
135 : };
136 :
137 2680 : class SVX_DLLPUBLIC Svx3DTextureKindItem : public SfxUInt16Item {
138 : public:
139 : Svx3DTextureKindItem(sal_uInt16 nVal = 3);
140 :
141 : // use drawing::TextureKind
142 : SVX_DLLPRIVATE virtual bool QueryValue( com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 ) const;
143 : SVX_DLLPRIVATE virtual bool PutValue( const com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 );
144 : SVX_DLLPRIVATE virtual SfxPoolItem* Clone(SfxItemPool* pPool = NULL) const;
145 : };
146 :
147 2680 : class SVX_DLLPUBLIC Svx3DTextureModeItem : public SfxUInt16Item {
148 : public:
149 : Svx3DTextureModeItem(sal_uInt16 nVal = 2);
150 :
151 : // use drawing:TextureMode
152 : SVX_DLLPRIVATE virtual bool QueryValue( com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 ) const;
153 : SVX_DLLPRIVATE virtual bool PutValue( const com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 );
154 : SVX_DLLPRIVATE virtual SfxPoolItem* Clone(SfxItemPool* pPool = NULL) const;
155 : };
156 :
157 2680 : class Svx3DTextureFilterItem : public SfxBoolItem {
158 : public:
159 : SVX_DLLPUBLIC Svx3DTextureFilterItem(sal_Bool bVal = 0);
160 : };
161 :
162 : // Svx3D _3DSCENE_ Items
163 3168 : class SVX_DLLPUBLIC Svx3DPerspectiveItem : public SfxUInt16Item {
164 : public:
165 : Svx3DPerspectiveItem(sal_uInt16 nVal = (sal_uInt16)PR_PERSPECTIVE);
166 :
167 : // use drawing::ProjectionMode
168 : SVX_DLLPRIVATE virtual bool QueryValue( com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 ) const;
169 : SVX_DLLPRIVATE virtual bool PutValue( const com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 );
170 : SVX_DLLPRIVATE virtual SfxPoolItem* Clone(SfxItemPool* pPool = NULL) const;
171 : };
172 :
173 3102 : class Svx3DDistanceItem : public SfxUInt32Item {
174 : public:
175 : SVX_DLLPUBLIC Svx3DDistanceItem(sal_uInt32 nVal = 100);
176 : };
177 :
178 3102 : class Svx3DFocalLengthItem : public SfxUInt32Item {
179 : public:
180 : SVX_DLLPUBLIC Svx3DFocalLengthItem(sal_uInt32 nVal = 100);
181 : };
182 :
183 2680 : class Svx3DTwoSidedLightingItem : public SfxBoolItem {
184 : public:
185 : SVX_DLLPUBLIC Svx3DTwoSidedLightingItem(sal_Bool bVal = 0);
186 : };
187 :
188 2680 : class SVX_DLLPUBLIC Svx3DLightcolor1Item : public SvxColorItem {
189 : public:
190 : Svx3DLightcolor1Item(const Color& rCol = Color(0xffcccccc));
191 : };
192 :
193 2680 : class SVX_DLLPUBLIC Svx3DLightcolor2Item : public SvxColorItem {
194 : public:
195 : Svx3DLightcolor2Item(const Color& rCol = Color(0x00000000));
196 : };
197 :
198 2680 : class SVX_DLLPUBLIC Svx3DLightcolor3Item : public SvxColorItem {
199 : public:
200 : Svx3DLightcolor3Item(const Color& rCol = Color(0x00000000));
201 : };
202 :
203 2680 : class SVX_DLLPUBLIC Svx3DLightcolor4Item : public SvxColorItem {
204 : public:
205 : Svx3DLightcolor4Item(const Color& rCol = Color(0x00000000));
206 : };
207 :
208 2680 : class SVX_DLLPUBLIC Svx3DLightcolor5Item : public SvxColorItem {
209 : public:
210 : Svx3DLightcolor5Item(const Color& rCol = Color(0x00000000));
211 : };
212 :
213 2680 : class SVX_DLLPUBLIC Svx3DLightcolor6Item : public SvxColorItem {
214 : public:
215 : Svx3DLightcolor6Item(const Color& rCol = Color(0x00000000));
216 : };
217 :
218 2680 : class SVX_DLLPUBLIC Svx3DLightcolor7Item : public SvxColorItem {
219 : public:
220 : Svx3DLightcolor7Item(const Color& rCol = Color(0x00000000));
221 : };
222 :
223 2680 : class SVX_DLLPUBLIC Svx3DLightcolor8Item : public SvxColorItem {
224 : public:
225 : Svx3DLightcolor8Item(const Color& rCol = Color(0x00000000));
226 : };
227 :
228 2680 : class SVX_DLLPUBLIC Svx3DAmbientcolorItem : public SvxColorItem {
229 : public:
230 : Svx3DAmbientcolorItem(const Color& rCol = Color(0x00666666));
231 : };
232 :
233 2680 : class SVX_DLLPUBLIC Svx3DLightOnOff1Item : public SfxBoolItem {
234 : public:
235 : Svx3DLightOnOff1Item(sal_Bool bVal = 1);
236 : };
237 :
238 2680 : class SVX_DLLPUBLIC Svx3DLightOnOff2Item : public SfxBoolItem {
239 : public:
240 : Svx3DLightOnOff2Item(sal_Bool bVal = 0);
241 : };
242 :
243 2680 : class SVX_DLLPUBLIC Svx3DLightOnOff3Item : public SfxBoolItem {
244 : public:
245 : Svx3DLightOnOff3Item(sal_Bool bVal = 0);
246 : };
247 :
248 2680 : class SVX_DLLPUBLIC Svx3DLightOnOff4Item : public SfxBoolItem {
249 : public:
250 : Svx3DLightOnOff4Item(sal_Bool bVal = 0);
251 : };
252 :
253 2680 : class SVX_DLLPUBLIC Svx3DLightOnOff5Item : public SfxBoolItem {
254 : public:
255 : Svx3DLightOnOff5Item(sal_Bool bVal = 0);
256 : };
257 :
258 2680 : class SVX_DLLPUBLIC Svx3DLightOnOff6Item : public SfxBoolItem {
259 : public:
260 : Svx3DLightOnOff6Item(sal_Bool bVal = 0);
261 : };
262 :
263 2680 : class SVX_DLLPUBLIC Svx3DLightOnOff7Item : public SfxBoolItem {
264 : public:
265 : Svx3DLightOnOff7Item(sal_Bool bVal = 0);
266 : };
267 :
268 2680 : class SVX_DLLPUBLIC Svx3DLightOnOff8Item : public SfxBoolItem {
269 : public:
270 : Svx3DLightOnOff8Item(sal_Bool bVal = 0);
271 : };
272 :
273 2680 : class SVX_DLLPUBLIC Svx3DLightDirection1Item : public SvxB3DVectorItem {
274 : public:
275 : Svx3DLightDirection1Item(const basegfx::B3DVector& rVec = basegfx::B3DVector(0.57735026918963, 0.57735026918963, 0.57735026918963));
276 : };
277 :
278 2680 : class SVX_DLLPUBLIC Svx3DLightDirection2Item : public SvxB3DVectorItem {
279 : public:
280 : Svx3DLightDirection2Item(const basegfx::B3DVector& rVec = basegfx::B3DVector(0.0,0.0,1.0));
281 : };
282 :
283 2680 : class SVX_DLLPUBLIC Svx3DLightDirection3Item : public SvxB3DVectorItem {
284 : public:
285 : Svx3DLightDirection3Item(const basegfx::B3DVector& rVec = basegfx::B3DVector(0.0,0.0,1.0));
286 : };
287 :
288 2680 : class SVX_DLLPUBLIC Svx3DLightDirection4Item : public SvxB3DVectorItem {
289 : public:
290 : Svx3DLightDirection4Item(const basegfx::B3DVector& rVec = basegfx::B3DVector(0.0,0.0,1.0));
291 : };
292 :
293 2680 : class SVX_DLLPUBLIC Svx3DLightDirection5Item : public SvxB3DVectorItem {
294 : public:
295 : Svx3DLightDirection5Item(const basegfx::B3DVector& rVec = basegfx::B3DVector(0.0,0.0,1.0));
296 : };
297 :
298 2680 : class SVX_DLLPUBLIC Svx3DLightDirection6Item : public SvxB3DVectorItem {
299 : public:
300 : Svx3DLightDirection6Item(const basegfx::B3DVector& rVec = basegfx::B3DVector(0.0,0.0,1.0));
301 : };
302 :
303 2680 : class SVX_DLLPUBLIC Svx3DLightDirection7Item : public SvxB3DVectorItem {
304 : public:
305 : Svx3DLightDirection7Item(const basegfx::B3DVector& rVec = basegfx::B3DVector(0.0,0.0,1.0));
306 : };
307 :
308 2680 : class SVX_DLLPUBLIC Svx3DLightDirection8Item : public SvxB3DVectorItem {
309 : public:
310 : Svx3DLightDirection8Item(const basegfx::B3DVector& rVec = basegfx::B3DVector(0.0,0.0,1.0));
311 : };
312 :
313 2680 : class Svx3DShadowSlantItem : public SfxUInt16Item {
314 : public:
315 : SVX_DLLPUBLIC Svx3DShadowSlantItem(sal_uInt16 nVal = 0);
316 : };
317 :
318 2728 : class SVX_DLLPUBLIC Svx3DShadeModeItem : public SfxUInt16Item {
319 : public:
320 : Svx3DShadeModeItem(sal_uInt16 nVal = 2);
321 :
322 : // use drawing::ShadeMode
323 : SVX_DLLPRIVATE virtual bool QueryValue( com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 ) const;
324 : SVX_DLLPRIVATE virtual bool PutValue( const com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 );
325 : SVX_DLLPRIVATE virtual SfxPoolItem* Clone(SfxItemPool* pPool = NULL) const;
326 : };
327 :
328 : //////////////////////////////////////////////////////////////////////////////
329 : // #107245# Item to replace bExtrudeSmoothed and bLatheSmoothed
330 3522 : class Svx3DSmoothNormalsItem : public SfxBoolItem {
331 : public:
332 : Svx3DSmoothNormalsItem(sal_Bool bVal = 1);
333 : virtual SfxPoolItem* Create(SvStream& rIn, sal_uInt16 nItemVersion) const;
334 : virtual sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion) const;
335 : };
336 :
337 : // #107245# Item to replace bExtrudeSmoothFrontBack and bLatheSmoothFrontBack
338 3522 : class Svx3DSmoothLidsItem : public SfxBoolItem {
339 : public:
340 : Svx3DSmoothLidsItem(sal_Bool bVal = 0);
341 : virtual SfxPoolItem* Create(SvStream& rIn, sal_uInt16 nItemVersion) const;
342 : virtual sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion) const;
343 : };
344 :
345 : // #107245# Item to replace bExtrudeCharacterMode and bLatheCharacterMode
346 4364 : class Svx3DCharacterModeItem : public SfxBoolItem {
347 : public:
348 : Svx3DCharacterModeItem(sal_Bool bVal = 0);
349 : virtual SfxPoolItem* Create(SvStream& rIn, sal_uInt16 nItemVersion) const;
350 : virtual sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion) const;
351 : };
352 :
353 : // #107245# Item to replace bExtrudeCloseFront and bLatheCloseFront
354 3522 : class SVX_DLLPUBLIC Svx3DCloseFrontItem : public SfxBoolItem {
355 : public:
356 : Svx3DCloseFrontItem(sal_Bool bVal = 1);
357 : SVX_DLLPRIVATE virtual SfxPoolItem* Create(SvStream& rIn, sal_uInt16 nItemVersion) const;
358 : SVX_DLLPRIVATE virtual sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion) const;
359 : };
360 :
361 : // #107245# Item to replace bExtrudeCloseBack and bLatheCloseBack
362 3522 : class SVX_DLLPUBLIC Svx3DCloseBackItem : public SfxBoolItem {
363 : public:
364 : Svx3DCloseBackItem(sal_Bool bVal = 1);
365 : SVX_DLLPRIVATE virtual SfxPoolItem* Create(SvStream& rIn, sal_uInt16 nItemVersion) const;
366 : SVX_DLLPRIVATE virtual sal_uInt16 GetVersion(sal_uInt16 nFileFormatVersion) const;
367 : };
368 :
369 : #endif // _SVX3DITEMS_HXX
370 :
371 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|