Branch libreoffice-5-0-4
[LibreOffice.git] / include / svx / deflt3d.hxx
blob29cba8a7936b5e22cba47523d902331461b6ab58
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
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 .
20 #ifndef INCLUDED_SVX_DEFLT3D_HXX
21 #define INCLUDED_SVX_DEFLT3D_HXX
23 #include <basegfx/point/b3dpoint.hxx>
24 #include <basegfx/vector/b3dvector.hxx>
25 #include <svx/svxdllapi.h>
26 #include <tools/color.hxx>
28 /*************************************************************************
30 |* Class for managing the 3D default attributes
32 \************************************************************************/
34 class SVX_DLLPUBLIC SAL_WARN_UNUSED E3dDefaultAttributes
36 private:
37 // Compound object
38 Color aDefaultAmbientColor;
39 bool bDefaultCreateNormals;
40 bool bDefaultCreateTexture;
42 // Cube object
43 basegfx::B3DPoint aDefaultCubePos;
44 basegfx::B3DVector aDefaultCubeSize;
45 sal_uInt16 nDefaultCubeSideFlags;
46 bool bDefaultCubePosIsCenter;
48 // Sphere object
49 basegfx::B3DPoint aDefaultSphereCenter;
50 basegfx::B3DVector aDefaultSphereSize;
52 // Lathe object
53 long nDefaultLatheEndAngle;
54 bool bDefaultLatheSmoothed;
55 bool bDefaultLatheSmoothFrontBack;
56 bool bDefaultLatheCharacterMode;
57 bool bDefaultLatheCloseFront;
58 bool bDefaultLatheCloseBack;
60 // Extrude object
61 bool bDefaultExtrudeSmoothed;
62 bool bDefaultExtrudeSmoothFrontBack;
63 bool bDefaultExtrudeCharacterMode;
64 bool bDefaultExtrudeCloseFront;
65 bool bDefaultExtrudeCloseBack;
67 public:
68 // Construktor
69 E3dDefaultAttributes();
71 // Reset to defaults
72 void Reset();
74 // Getter/Setter for default values of all 3D objects
75 // Compound object
76 const Color& GetDefaultAmbientColor() { return aDefaultAmbientColor; }
77 void SetDefaultAmbientColor(const Color& rNew) { aDefaultAmbientColor = rNew; }
79 bool GetDefaultCreateNormals() const { return bDefaultCreateNormals; }
80 void SetDefaultCreateNormals(const bool bNew) { bDefaultCreateNormals = bNew; }
81 bool GetDefaultCreateTexture() const { return bDefaultCreateTexture; }
82 void SetDefaultCreateTexture(const bool bNew) { bDefaultCreateTexture = bNew; }
84 // Cube object
85 const basegfx::B3DPoint& GetDefaultCubePos() { return aDefaultCubePos; }
86 void SetDefaultCubePos(const basegfx::B3DPoint& rNew) { aDefaultCubePos = rNew; }
87 const basegfx::B3DVector& GetDefaultCubeSize() { return aDefaultCubeSize; }
88 void SetDefaultCubeSize(const basegfx::B3DVector& rNew) { aDefaultCubeSize = rNew; }
89 sal_uInt16 GetDefaultCubeSideFlags() const { return nDefaultCubeSideFlags; }
90 void SetDefaultCubeSideFlags(const sal_uInt16 nNew) { nDefaultCubeSideFlags = nNew; }
91 bool GetDefaultCubePosIsCenter() const { return bDefaultCubePosIsCenter; }
92 void SetDefaultCubePosIsCenter(const bool bNew) { bDefaultCubePosIsCenter = bNew; }
94 // Sphere object
95 const basegfx::B3DPoint& GetDefaultSphereCenter() { return aDefaultSphereCenter; }
96 void SetDefaultSphereCenter(const basegfx::B3DPoint& rNew) { aDefaultSphereCenter = rNew; }
97 const basegfx::B3DVector& GetDefaultSphereSize() { return aDefaultSphereSize; }
98 void SetDefaultSphereSize(const basegfx::B3DPoint& rNew) { aDefaultSphereSize = rNew; }
100 // Lathe object
101 long GetDefaultLatheEndAngle() const { return nDefaultLatheEndAngle; }
102 void SetDefaultLatheEndAngle(const long nNew) { nDefaultLatheEndAngle = nNew; }
103 bool GetDefaultLatheSmoothed() const { return bDefaultLatheSmoothed; }
104 void SetDefaultLatheSmoothed(const bool bNew) { bDefaultLatheSmoothed = bNew; }
105 bool GetDefaultLatheSmoothFrontBack() const { return bDefaultLatheSmoothFrontBack; }
106 void SetDefaultLatheSmoothFrontBack(const bool bNew) { bDefaultLatheSmoothFrontBack = bNew; }
107 bool GetDefaultLatheCharacterMode() const { return bDefaultLatheCharacterMode; }
108 void SetDefaultLatheCharacterMode(const bool bNew) { bDefaultLatheCharacterMode = bNew; }
109 bool GetDefaultLatheCloseFront() const { return bDefaultLatheCloseFront; }
110 void SetDefaultLatheCloseFront(const bool bNew) { bDefaultLatheCloseFront = bNew; }
111 bool GetDefaultLatheCloseBack() const { return bDefaultLatheCloseBack; }
112 void SetDefaultLatheCloseBack(const bool bNew) { bDefaultLatheCloseBack = bNew; }
114 // Extrude object
115 bool GetDefaultExtrudeSmoothed() const { return bDefaultExtrudeSmoothed; }
116 void SetDefaultExtrudeSmoothed(const bool bNew) { bDefaultExtrudeSmoothed = bNew; }
117 bool GetDefaultExtrudeSmoothFrontBack() const { return bDefaultExtrudeSmoothFrontBack; }
118 void SetDefaultExtrudeSmoothFrontBack(const bool bNew) { bDefaultExtrudeSmoothFrontBack = bNew; }
119 bool GetDefaultExtrudeCharacterMode() const { return bDefaultExtrudeCharacterMode; }
120 void SetDefaultExtrudeCharacterMode(const bool bNew) { bDefaultExtrudeCharacterMode = bNew; }
121 bool GetDefaultExtrudeCloseFront() const { return bDefaultExtrudeCloseFront; }
122 void SetDefaultExtrudeCloseFront(const bool bNew) { bDefaultExtrudeCloseFront = bNew; }
123 bool GetDefaultExtrudeCloseBack() const { return bDefaultExtrudeCloseBack; }
124 void SetDefaultExtrudeCloseBack(const bool bNew) { bDefaultExtrudeCloseBack = bNew; }
127 #endif // INCLUDED_SVX_DEFLT3D_HXX
129 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */