Bump version to 5.0-43
[LibreOffice.git] / xmloff / inc / xexptran.hxx
blob3f9d42dc593b94b97dfd29dc55a935e4f8eb7f87
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_XMLOFF_INC_XEXPTRAN_HXX
21 #define INCLUDED_XMLOFF_INC_XEXPTRAN_HXX
23 #include <rtl/ustring.hxx>
24 #include <com/sun/star/drawing/PolyPolygonBezierCoords.hpp>
25 #include <com/sun/star/drawing/PointSequence.hpp>
26 #include <com/sun/star/drawing/FlagSequence.hpp>
27 #include <com/sun/star/awt/Size.hpp>
28 #include <com/sun/star/drawing/HomogenMatrix.hpp>
29 #include <tools/mapunit.hxx>
31 #include <vector>
33 struct ImpSdXMLExpTransObj2DBase;
34 struct ImpSdXMLExpTransObj3DBase;
35 class SvXMLUnitConverter;
36 class SvXMLImport;
37 class SvXMLExport;
39 namespace basegfx
41 class B2DTuple;
42 class B2DHomMatrix;
43 class B3DHomMatrix;
46 typedef ::std::vector< ImpSdXMLExpTransObj2DBase* > ImpSdXMLExpTransObj2DBaseList;
47 typedef ::std::vector< ImpSdXMLExpTransObj3DBase* > ImpSdXMLExpTransObj3DBaseList;
49 class SdXMLImExTransform2D
51 ImpSdXMLExpTransObj2DBaseList maList;
52 OUString msString;
54 void EmptyList();
56 public:
57 SdXMLImExTransform2D() {}
58 ~SdXMLImExTransform2D() { EmptyList(); }
60 void AddRotate(double fNew);
61 void AddTranslate(const ::basegfx::B2DTuple& rNew);
62 void AddSkewX(double fNew);
64 bool NeedsAction() const { return !maList.empty(); }
65 void GetFullTransform(::basegfx::B2DHomMatrix& rFullTrans);
66 const OUString& GetExportString(const SvXMLUnitConverter& rConv);
67 void SetString(const OUString& rNew, const SvXMLUnitConverter& rConv);
70 class SdXMLImExTransform3D
72 ImpSdXMLExpTransObj3DBaseList maList;
73 OUString msString;
75 void EmptyList();
77 public:
78 SdXMLImExTransform3D() {}
79 SdXMLImExTransform3D(const OUString& rNew, const SvXMLUnitConverter& rConv);
80 ~SdXMLImExTransform3D() { EmptyList(); }
82 void AddMatrix(const ::basegfx::B3DHomMatrix& rNew);
84 void AddHomogenMatrix(const com::sun::star::drawing::HomogenMatrix& xHomMat);
85 bool NeedsAction() const { return !maList.empty(); }
86 void GetFullTransform(::basegfx::B3DHomMatrix& rFullTrans);
87 bool GetFullHomogenTransform(com::sun::star::drawing::HomogenMatrix& xHomMat);
88 const OUString& GetExportString(const SvXMLUnitConverter& rConv);
89 void SetString(const OUString& rNew, const SvXMLUnitConverter& rConv);
92 class SdXMLImExViewBox
94 OUString msString;
95 double mfX;
96 double mfY;
97 double mfW;
98 double mfH;
100 public:
101 SdXMLImExViewBox(double fX = 0.0, double fY = 0.0, double fW = 1000.0, double fH = 1000.0);
102 SdXMLImExViewBox(const OUString& rNew, const SvXMLUnitConverter& rConv);
104 double GetX() const { return mfX; }
105 double GetY() const { return mfY; }
106 double GetWidth() const { return mfW; }
107 double GetHeight() const { return mfH; }
108 const OUString& GetExportString();
111 #endif // _XEXPTRANSFORM_HXX
113 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */