Version 4.3.0.0.beta1, tag libreoffice-4.3.0.0.beta1
[LibreOffice.git] / include / svx / svdovirt.hxx
blob766b8070c9ec78c54f90402ea3a47e960a5d0096
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_SVDOVIRT_HXX
21 #define INCLUDED_SVX_SVDOVIRT_HXX
23 #include <svx/svdobj.hxx>
24 #include <svx/svxdllapi.h>
28 // SdrVirtObj
30 // Achtung! Das virtuelle Objekt ist noch nicht bis in alle Feinheiten
31 // durchprogrammiert und getestet. Z.Zt. kommt es nur in abgeleiteter
32 // beim Writer zum Einsatz.
36 class SVX_DLLPUBLIC SdrVirtObj : public SdrObject
38 public:
39 virtual sdr::properties::BaseProperties& GetProperties() const SAL_OVERRIDE;
41 protected:
42 virtual sdr::contact::ViewContact* CreateObjectSpecificViewContact() SAL_OVERRIDE;
44 SdrObject& rRefObj; // Referenziertes Zeichenobjekt
45 Rectangle aSnapRect;
47 protected:
48 virtual void Notify(SfxBroadcaster& rBC, const SfxHint& rHint) SAL_OVERRIDE;
50 virtual SdrObjGeoData* NewGeoData() const SAL_OVERRIDE;
51 virtual void SaveGeoData(SdrObjGeoData& rGeo) const SAL_OVERRIDE;
52 virtual void RestGeoData(const SdrObjGeoData& rGeo) SAL_OVERRIDE;
54 public:
55 TYPEINFO_OVERRIDE();
56 SdrVirtObj(SdrObject& rNewObj);
57 virtual ~SdrVirtObj();
58 virtual SdrObject& ReferencedObj();
59 virtual const SdrObject& GetReferencedObj() const;
60 virtual void NbcSetAnchorPos(const Point& rAnchorPos) SAL_OVERRIDE;
61 virtual void SetModel(SdrModel* pNewModel) SAL_OVERRIDE;
63 virtual void TakeObjInfo(SdrObjTransformInfoRec& rInfo) const SAL_OVERRIDE;
64 virtual sal_uInt32 GetObjInventor() const SAL_OVERRIDE;
65 virtual sal_uInt16 GetObjIdentifier() const SAL_OVERRIDE;
66 virtual SdrObjList* GetSubList() const SAL_OVERRIDE;
68 virtual const Rectangle& GetCurrentBoundRect() const SAL_OVERRIDE;
69 virtual const Rectangle& GetLastBoundRect() const SAL_OVERRIDE;
70 virtual void RecalcBoundRect() SAL_OVERRIDE;
71 virtual void SetChanged() SAL_OVERRIDE;
72 virtual SdrVirtObj* Clone() const SAL_OVERRIDE;
73 SdrVirtObj& operator=(const SdrVirtObj& rObj);
75 virtual OUString TakeObjNameSingul() const SAL_OVERRIDE;
76 virtual OUString TakeObjNamePlural() const SAL_OVERRIDE;
78 virtual basegfx::B2DPolyPolygon TakeXorPoly() const SAL_OVERRIDE;
79 virtual sal_uInt32 GetHdlCount() const SAL_OVERRIDE;
80 virtual SdrHdl* GetHdl(sal_uInt32 nHdlNum) const SAL_OVERRIDE;
81 virtual sal_uInt32 GetPlusHdlCount(const SdrHdl& rHdl) const SAL_OVERRIDE;
82 virtual SdrHdl* GetPlusHdl(const SdrHdl& rHdl, sal_uInt32 nPlNum) const SAL_OVERRIDE;
83 virtual void AddToHdlList(SdrHdlList& rHdlList) const SAL_OVERRIDE;
85 // special drag methods
86 virtual bool hasSpecialDrag() const SAL_OVERRIDE;
87 virtual bool beginSpecialDrag(SdrDragStat& rDrag) const SAL_OVERRIDE;
88 virtual bool applySpecialDrag(SdrDragStat& rDrag) SAL_OVERRIDE;
89 virtual OUString getSpecialDragComment(const SdrDragStat& rDrag) const SAL_OVERRIDE;
90 virtual basegfx::B2DPolyPolygon getSpecialDragPoly(const SdrDragStat& rDrag) const SAL_OVERRIDE;
92 // FullDrag support
93 virtual bool supportsFullDrag() const SAL_OVERRIDE;
94 virtual SdrObject* getFullDragClone() const SAL_OVERRIDE;
96 virtual bool BegCreate(SdrDragStat& rStat) SAL_OVERRIDE;
97 virtual bool MovCreate(SdrDragStat& rStat) SAL_OVERRIDE;
98 virtual bool EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd) SAL_OVERRIDE;
99 virtual bool BckCreate(SdrDragStat& rStat) SAL_OVERRIDE;
100 virtual void BrkCreate(SdrDragStat& rStat) SAL_OVERRIDE;
101 virtual basegfx::B2DPolyPolygon TakeCreatePoly(const SdrDragStat& rDrag) const SAL_OVERRIDE;
103 virtual void NbcMove(const Size& rSiz) SAL_OVERRIDE;
104 virtual void NbcResize(const Point& rRef, const Fraction& xFact, const Fraction& yFact) SAL_OVERRIDE;
105 virtual void NbcRotate(const Point& rRef, long nWink, double sn, double cs) SAL_OVERRIDE;
106 virtual void NbcMirror(const Point& rRef1, const Point& rRef2) SAL_OVERRIDE;
107 virtual void NbcShear(const Point& rRef, long nWink, double tn, bool bVShear) SAL_OVERRIDE;
109 virtual void Move(const Size& rSiz) SAL_OVERRIDE;
110 virtual void Resize(const Point& rRef, const Fraction& xFact, const Fraction& yFact, bool bUnsetRelative = true) SAL_OVERRIDE;
111 virtual void Rotate(const Point& rRef, long nWink, double sn, double cs) SAL_OVERRIDE;
112 virtual void Mirror(const Point& rRef1, const Point& rRef2) SAL_OVERRIDE;
113 virtual void Shear(const Point& rRef, long nWink, double tn, bool bVShear) SAL_OVERRIDE;
115 virtual void RecalcSnapRect() SAL_OVERRIDE;
116 virtual const Rectangle& GetSnapRect() const SAL_OVERRIDE;
117 virtual void SetSnapRect(const Rectangle& rRect) SAL_OVERRIDE;
118 virtual void NbcSetSnapRect(const Rectangle& rRect) SAL_OVERRIDE;
120 virtual const Rectangle& GetLogicRect() const SAL_OVERRIDE;
121 virtual void SetLogicRect(const Rectangle& rRect) SAL_OVERRIDE;
122 virtual void NbcSetLogicRect(const Rectangle& rRect) SAL_OVERRIDE;
124 virtual long GetRotateAngle() const SAL_OVERRIDE;
125 virtual long GetShearAngle(bool bVertical = false) const SAL_OVERRIDE;
127 virtual sal_uInt32 GetSnapPointCount() const SAL_OVERRIDE;
128 virtual Point GetSnapPoint(sal_uInt32 i) const SAL_OVERRIDE;
130 virtual bool IsPolyObj() const SAL_OVERRIDE;
131 virtual sal_uInt32 GetPointCount() const SAL_OVERRIDE;
132 virtual Point GetPoint(sal_uInt32 i) const SAL_OVERRIDE;
133 virtual void NbcSetPoint(const Point& rPnt, sal_uInt32 i) SAL_OVERRIDE;
135 virtual SdrObjGeoData* GetGeoData() const SAL_OVERRIDE;
136 virtual void SetGeoData(const SdrObjGeoData& rGeo) SAL_OVERRIDE;
138 virtual void NbcReformatText() SAL_OVERRIDE;
139 virtual void ReformatText() SAL_OVERRIDE;
141 virtual bool HasMacro() const SAL_OVERRIDE;
142 virtual SdrObject* CheckMacroHit (const SdrObjMacroHitRec& rRec) const SAL_OVERRIDE;
143 virtual Pointer GetMacroPointer (const SdrObjMacroHitRec& rRec) const SAL_OVERRIDE;
144 virtual void PaintMacro (OutputDevice& rOut, const Rectangle& rDirtyRect, const SdrObjMacroHitRec& rRec) const SAL_OVERRIDE;
145 virtual bool DoMacro (const SdrObjMacroHitRec& rRec) SAL_OVERRIDE;
146 virtual OUString GetMacroPopupComment(const SdrObjMacroHitRec& rRec) const SAL_OVERRIDE;
148 // OD 30.06.2003 #108784# - virtual <GetOffset()> returns Point(0,0)
149 // #i73248# for default SdrVirtObj, offset is aAnchor, not (0,0)
150 virtual const Point GetOffset() const;
155 #endif // INCLUDED_SVX_SVDOVIRT_HXX
157 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */