update emoji autocorrect entries from po-files
[LibreOffice.git] / include / drawinglayer / primitive2d / unifiedtransparenceprimitive2d.hxx
blob95db70985f4a21a4e74f537809e0b46aee473e17
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_DRAWINGLAYER_PRIMITIVE2D_UNIFIEDTRANSPARENCEPRIMITIVE2D_HXX
21 #define INCLUDED_DRAWINGLAYER_PRIMITIVE2D_UNIFIEDTRANSPARENCEPRIMITIVE2D_HXX
23 #include <drawinglayer/drawinglayerdllapi.h>
25 #include <drawinglayer/primitive2d/groupprimitive2d.hxx>
29 namespace drawinglayer
31 namespace primitive2d
33 /** UnifiedTransparencePrimitive2D class
35 This primitive encapsualtes a child hierarchy and defines
36 that it shall be visualized with the given transparency. That
37 transparency is unique for all contained geometry, so that
38 e.g. overlapping polygons in the child geometry will not show
39 regions of combined transparency, but be all rendered with the
40 defined, single transparency.
42 class DRAWINGLAYER_DLLPUBLIC UnifiedTransparencePrimitive2D : public GroupPrimitive2D
44 private:
45 /// the unified transparence
46 double mfTransparence;
48 public:
49 /// constructor
50 UnifiedTransparencePrimitive2D(
51 const Primitive2DSequence& rChildren,
52 double fTransparence);
54 /// data read access
55 double getTransparence() const { return mfTransparence; }
57 /// compare operator
58 virtual bool operator==(const BasePrimitive2D& rPrimitive) const SAL_OVERRIDE;
60 /// own getB2DRange implementation to include transparent geometries to BoundRect calculations
61 virtual basegfx::B2DRange getB2DRange(const geometry::ViewInformation2D& rViewInformation) const SAL_OVERRIDE;
63 /// create decomposition
64 virtual Primitive2DSequence get2DDecomposition(const geometry::ViewInformation2D& rViewInformation) const SAL_OVERRIDE;
66 /// provide unique ID
67 DeclPrimitive2DIDBlock()
69 } // end of namespace primitive2d
70 } // end of namespace drawinglayer
74 #endif //INCLUDED_DRAWINGLAYER_PRIMITIVE2D_UNIFIEDTRANSPARENCEPRIMITIVE2D_HXX
76 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */