LibreOffice Module svx (master)  1
sdrolecontentprimitive2d.hxx
Go to the documentation of this file.
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 #ifndef INCLUDED_SVX_INC_SDR_PRIMITIVE2D_SDROLECONTENTPRIMITIVE2D_HXX
21 #define INCLUDED_SVX_INC_SDR_PRIMITIVE2D_SDROLECONTENTPRIMITIVE2D_HXX
22 
25 #include <tools/weakbase.h>
26 
27 
28 // predefinitions
29 
30 class SdrOle2Obj;
31 
32 
33 namespace drawinglayer
34 {
35  namespace primitive2d
36  {
38  {
39  private:
42 
43  // #i104867# The GraphicVersion number to identify in operator== if
44  // the graphic has changed, but without fetching it (which may
45  // be expensive, e.g. triggering chart creation)
46  sal_uInt32 mnGraphicVersion;
47 
48  // local decomposition.
49  virtual void create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& aViewInformation) const override;
50 
51  public:
53  const SdrOle2Obj& rSdrOle2Obj,
54  const basegfx::B2DHomMatrix& rObjectTransform,
55  sal_uInt32 nGraphicVersion
56  );
57 
58  // compare operator
59  virtual bool operator==(const BasePrimitive2D& rPrimitive) const override;
60 
61  // The default implementation will use getDecomposition results to create the range
62  virtual basegfx::B2DRange getB2DRange(const geometry::ViewInformation2D& rViewInformation) const override;
63 
64  // data access
66 
67  // provide unique ID
68  virtual sal_uInt32 getPrimitive2DID() const override;
69  };
70  } // end of namespace primitive2d
71 } // end of namespace drawinglayer
72 
73 
74 #endif // INCLUDED_SVX_INC_SDR_PRIMITIVE2D_SDROLECONTENTPRIMITIVE2D_HXX
75 
76 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual sal_uInt32 getPrimitive2DID() const override
virtual void create2DDecomposition(Primitive2DContainer &rContainer, const geometry::ViewInformation2D &aViewInformation) const override
const basegfx::B2DHomMatrix & getObjectTransform() const
SdrOleContentPrimitive2D(const SdrOle2Obj &rSdrOle2Obj, const basegfx::B2DHomMatrix &rObjectTransform, sal_uInt32 nGraphicVersion)
virtual bool operator==(const BasePrimitive2D &rPrimitive) const override
virtual basegfx::B2DRange getB2DRange(const geometry::ViewInformation2D &rViewInformation) const override