LibreOffice Module svx (master)  1
svdoedge.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 #pragma once
21 
22 #include <memory>
23 #include <svx/svdotext.hxx>
24 #include <svx/svdglue.hxx>
25 #include <svx/svxdllapi.h>
26 
27 
28 class SdrDragMethod;
29 class SdrPageView;
30 
31 namespace sdr::properties {
32  class ConnectorProperties;
33 }
34 
35 
37 class SdrObjConnection final
38 {
39  friend class SdrEdgeObj;
40  friend class ImpEdgeHdl;
41  friend class SdrCreateView;
42 
43  Point aObjOfs; // set during dragging of a node
44  SdrObject* pObj; // referenced object
45  sal_uInt16 nConId; // connector number
46 
47  bool bBestConn : 1; // true -> the best-matching connector is searched for
48  bool bBestVertex : 1; // true -> the best-matching vertex to connect is searched for
49  bool bAutoVertex : 1; // autoConnector at apex nCon
50  bool bAutoCorner : 1; // autoConnector at corner nCon
51 
52 public:
54 
55  void ResetVars();
56  bool TakeGluePoint(SdrGluePoint& rGP) const;
57 
58  void SetBestConnection( bool rB ) { bBestConn = rB; };
59  void SetBestVertex( bool rB ) { bBestVertex = rB; };
60  void SetAutoVertex( bool rB ) { bAutoVertex = rB; };
61  void SetConnectorId( sal_uInt16 nId ) { nConId = nId; };
62 
63  bool IsBestConnection() const { return bBestConn; };
64  bool IsAutoVertex() const { return bAutoVertex; };
65  sal_uInt16 GetConnectorId() const { return nConId; };
66  SdrObject* GetObject() const { return pObj; }
67 };
68 
69 
71 
74 {
75 public:
76  // The 5 distances are set on dragging or via SetAttr and are
77  // evaluated by ImpCalcEdgeTrack. Only 0-3 longs are transported
78  // via Get/SetAttr/Get/SetStyleSh though.
84 
85  // Following values are set by ImpCalcEdgeTrack
86  tools::Long nAngle1; // exit angle at Obj1
87  tools::Long nAngle2; // exit angle at Obj2
88  sal_uInt16 nObj1Lines; // 1..3
89  sal_uInt16 nObj2Lines; // 1..3
90  sal_uInt16 nMiddleLine; // 0xFFFF=none, otherwise point number of the beginning of the line
91 
92 public:
94  : nAngle1(0),
95  nAngle2(0),
96  nObj1Lines(0),
97  nObj2Lines(0),
98  nMiddleLine(0xFFFF)
99  {}
100 
102  sal_uInt16 ImpGetPolyIdx(SdrEdgeLineCode eLineCode, const XPolygon& rXP) const;
103  bool ImpIsHorzLine(SdrEdgeLineCode eLineCode, const XPolygon& rXP) const;
104  void ImpSetLineOffset(SdrEdgeLineCode eLineCode, const XPolygon& rXP, tools::Long nVal);
105  tools::Long ImpGetLineOffset(SdrEdgeLineCode eLineCode, const XPolygon& rXP) const;
106 };
107 
108 
111 {
112 public:
113  SdrObjConnection aCon1; // connection status of the beginning of the line
114  SdrObjConnection aCon2; // connection status of the end of the line
115  std::unique_ptr<XPolygon> pEdgeTrack;
116  bool bEdgeTrackDirty; // true -> connector track needs to be recalculated
119 
120 public:
122  virtual ~SdrEdgeObjGeoData() override;
123 };
124 
125 
128 {
129 private:
130  // to allow sdr::properties::ConnectorProperties access to ImpSetAttrToEdgeInfo()
132 
133  friend class SdrCreateView;
134  friend class ImpEdgeHdl;
135 
136  virtual std::unique_ptr<sdr::contact::ViewContact> CreateObjectSpecificViewContact() override;
137  virtual std::unique_ptr<sdr::properties::BaseProperties> CreateObjectSpecificProperties() override;
138 
139  SdrObjConnection aCon1; // Connection status of the beginning of the line
140  SdrObjConnection aCon2; // Connection status of the end of the line
141 
142  std::unique_ptr<XPolygon> pEdgeTrack;
143  sal_uInt16 nNotifyingCount; // Locking
145 
146  bool bEdgeTrackDirty : 1; // true -> Connection track needs to be recalculated
147  bool bEdgeTrackUserDefined : 1;
148 
149  // Bool to allow suppression of default connects at object
150  // inside test (HitTest) and object center test (see ImpFindConnector())
151  bool mbSuppressDefaultConnect : 1;
152 
153  // Flag value for avoiding infinite loops when calculating
154  // BoundRects from ring-connected connectors. A coloring algorithm
155  // is used here. When the GetCurrentBoundRect() calculation of a
156  // SdrEdgeObj is running, the flag is set, else it is always
157  // false.
158  bool mbBoundRectCalculationRunning : 1;
159 
160  // #i123048# need to remember if layouting was suppressed before to get
161  // to a correct state for first real layouting
162  bool mbSuppressed : 1;
163 
164 public:
165  // Interface to default connect suppression
166  void SetSuppressDefaultConnect(bool bNew) { mbSuppressDefaultConnect = bNew; }
167  bool GetSuppressDefaultConnect() const { return mbSuppressDefaultConnect; }
168 
169 private:
170  virtual void Notify(SfxBroadcaster& rBC, const SfxHint& rHint) override;
171 
172  static XPolygon ImpCalcObjToCenter(const Point& rStPt, tools::Long nEscAngle, const tools::Rectangle& rRect, const Point& rCenter);
173  void ImpRecalcEdgeTrack(); // recalculation of the connection track
174  XPolygon ImpCalcEdgeTrack(const XPolygon& rTrack0, SdrObjConnection& rCon1, SdrObjConnection& rCon2, SdrEdgeInfoRec* pInfo) const;
175  XPolygon ImpCalcEdgeTrack(const Point& rPt1, tools::Long nAngle1, const tools::Rectangle& rBoundRect1, const tools::Rectangle& rBewareRect1,
176  const Point& rPt2, tools::Long nAngle2, const tools::Rectangle& rBoundRect2, const tools::Rectangle& rBewareRect2,
177  sal_uIntPtr* pnQuality, SdrEdgeInfoRec* pInfo) const;
178  static bool ImpFindConnector(const Point& rPt, const SdrPageView& rPV, SdrObjConnection& rCon, const SdrEdgeObj* pThis, OutputDevice* pOut=nullptr, SdrDragStat* pDragStat = nullptr);
179  static SdrEscapeDirection ImpCalcEscAngle(SdrObject const * pObj, const Point& aPt2);
180  void ImpSetTailPoint(bool bTail1, const Point& rPt);
181  void ImpUndirtyEdgeTrack(); // potential recalculation of the connection track
182  void ImpDirtyEdgeTrack(); // invalidate connector path, so it will be recalculated next time
183  void ImpSetAttrToEdgeInfo(); // copying values from the pool to aEdgeInfo
184  void ImpSetEdgeInfoToAttr(); // copying values from the aEdgeInfo to the pool
185 
186  // protected destructor
187  virtual ~SdrEdgeObj() override;
188 
189 public:
190  SdrEdgeObj(SdrModel& rSdrModel);
191  // Copy constructor
192  SdrEdgeObj(SdrModel& rSdrModel, SdrEdgeObj const & rSource);
193 
194  // react on model/page change
195  virtual void handlePageChange(SdrPage* pOldPage, SdrPage* pNewPage) override;
196 
197  SdrObjConnection& GetConnection(bool bTail1) { return *(bTail1 ? &aCon1 : &aCon2); }
198  virtual void TakeObjInfo(SdrObjTransformInfoRec& rInfo) const override;
199  virtual SdrObjKind GetObjIdentifier() const override;
200  virtual const tools::Rectangle& GetCurrentBoundRect() const override;
201  virtual const tools::Rectangle& GetSnapRect() const override;
202  virtual SdrGluePoint GetVertexGluePoint(sal_uInt16 nNum) const override;
203  virtual SdrGluePoint GetCornerGluePoint(sal_uInt16 nNum) const override;
204  virtual const SdrGluePointList* GetGluePointList() const override;
205  virtual SdrGluePointList* ForceGluePointList() override;
206 
207  // * for all of the below: bTail1=true: beginning of the line,
208  // otherwise end of the line
209  // * pObj=NULL: disconnect connector
210  void SetEdgeTrackDirty() { bEdgeTrackDirty=true; }
211  void ConnectToNode(bool bTail1, SdrObject* pObj) override;
212  void DisconnectFromNode(bool bTail1) override;
213  SdrObject* GetConnectedNode(bool bTail1) const override;
214  const SdrObjConnection& GetConnection(bool bTail1) const { return *(bTail1 ? &aCon1 : &aCon2); }
215  bool CheckNodeConnection(bool bTail1) const;
216 
217  virtual void RecalcSnapRect() override;
218  virtual void TakeUnrotatedSnapRect(tools::Rectangle& rRect) const override;
219  virtual SdrEdgeObj* CloneSdrObject(SdrModel& rTargetModel) const override;
220  virtual OUString TakeObjNameSingul() const override;
221  virtual OUString TakeObjNamePlural() const override;
222 
223  void SetEdgeTrackPath( const basegfx::B2DPolyPolygon& rPoly );
224  basegfx::B2DPolyPolygon GetEdgeTrackPath() const;
225 
226  virtual basegfx::B2DPolyPolygon TakeXorPoly() const override;
227  virtual sal_uInt32 GetHdlCount() const override;
228  virtual void AddToHdlList(SdrHdlList& rHdlList) const override;
229 
230  // special drag methods
231  virtual bool hasSpecialDrag() const override;
232  virtual bool beginSpecialDrag(SdrDragStat& rDrag) const override;
233  virtual bool applySpecialDrag(SdrDragStat& rDrag) override;
234  virtual OUString getSpecialDragComment(const SdrDragStat& rDrag) const override;
235 
236  // FullDrag support
237  virtual SdrObjectUniquePtr getFullDragClone() const override;
238 
239  virtual void NbcSetSnapRect(const tools::Rectangle& rRect) override;
240  virtual void NbcMove(const Size& aSize) override;
241  virtual void NbcResize(const Point& rRefPnt, const Fraction& aXFact, const Fraction& aYFact) override;
242 
243  // #i54102# added rotate, mirror and shear support
244  virtual void NbcRotate(const Point& rRef, Degree100 nAngle, double sn, double cs) override;
245  virtual void NbcMirror(const Point& rRef1, const Point& rRef2) override;
246  virtual void NbcShear(const Point& rRef, Degree100 nAngle, double tn, bool bVShear) override;
247 
248  // #102344# Added missing implementation
249  virtual void NbcSetAnchorPos(const Point& rPnt) override;
250 
251  virtual bool BegCreate(SdrDragStat& rStat) override;
252  virtual bool MovCreate(SdrDragStat& rStat) override;
253  virtual bool EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd) override;
254  virtual bool BckCreate(SdrDragStat& rStat) override;
255  virtual void BrkCreate(SdrDragStat& rStat) override;
256  virtual basegfx::B2DPolyPolygon TakeCreatePoly(const SdrDragStat& rDrag) const override;
257  virtual PointerStyle GetCreatePointer() const override;
258  virtual SdrObjectUniquePtr DoConvertToPolyObj(bool bBezier, bool bAddText) const override;
259 
260  virtual sal_uInt32 GetSnapPointCount() const override;
261  virtual Point GetSnapPoint(sal_uInt32 i) const override;
262  virtual bool IsPolyObj() const override;
263  virtual sal_uInt32 GetPointCount() const override;
264  virtual Point GetPoint(sal_uInt32 i) const override;
265  virtual void NbcSetPoint(const Point& rPnt, sal_uInt32 i) override;
266 
267  virtual std::unique_ptr<SdrObjGeoData> NewGeoData() const override;
268  virtual void SaveGeoData(SdrObjGeoData& rGeo) const override;
269  virtual void RestoreGeoData(const SdrObjGeoData& rGeo) override;
270 
275  void Reformat();
276 
277  // helper methods for the StarOffice api
278  Point GetTailPoint( bool bTail ) const;
279  void SetTailPoint( bool bTail, const Point& rPt );
280  void setGluePointIndex( bool bTail, sal_Int32 nId = -1 );
281  sal_Int32 getGluePointIndex( bool bTail );
282 
283  virtual bool TRGetBaseGeometry(basegfx::B2DHomMatrix& rMatrix, basegfx::B2DPolyPolygon& rPolyPolygon) const override;
284  virtual void TRSetBaseGeometry(const basegfx::B2DHomMatrix& rMatrix, const basegfx::B2DPolyPolygon& rPolyPolygon) override;
285 
286  // for geometry access
287  ::basegfx::B2DPolygon getEdgeTrack() const;
288 
289  // helper method for SdrDragMethod::AddConnectorOverlays. Adds an overlay polygon for
290  // this connector to rResult.
291  basegfx::B2DPolygon ImplAddConnectorOverlay(SdrDragMethod& rDragMethod, bool bTail1, bool bTail2, bool bDetail) const;
292 };
293 
294  // The following item parameters of the SdrItemPool are used to
295  // determine the actual connector line routing:
296  //
297  // sal_uInt16 EdgeFlowAngle default 9000 (= 90.00 deg), min 0, max 9000
298  // Clearance angle.
299  // The angle at which the connecting line may run.
300  //
301  // sal_uInt16 EdgeEscAngle default 9000 (= 90.00 Deg), min 0, max 9000
302  // Object exit angle.
303  // The angle at which the connection line may exit from the object.
304  //
305  // bool EdgeEscAsRay default false
306  // true -> the connecting line emerges from the object radially.
307  // Thus, angle specification by the line ObjCenter / connector.
308  //
309  // bool EdgeEscUseObjAngle default false
310  // Object rotation angle is considered
311  // true -> when determining the connector exit angle, angle for
312  // object rotation is taken as an offset.
313  //
314  // sal_uIntPtr EdgeFlowDefDist default 0, min 0, max ?
315  // This is the default minimum distance on calculation of the
316  // connection Line to the docked objects is in logical units.
317  // This distance is overridden within the object, as soon as the
318  // user drags on the lines. When docking onto a new object,
319  // however, this default is used again.
320  //
321  //
322  // General Information About Connectors:
323  //
324  // There are nodes and edge objects. Two nodes can be joined by an
325  // edge. If a connector is connected to a node only at one end, the
326  // other end is fixed to an absolute position in the document. It is
327  // of course also possible for a connector to be "free" at both ends,
328  // i.e. not connected to a node object on each side.
329  //
330  // A connector object can also theoretically be a node object at the
331  // same time. In the first version, however, this will not yet be
332  // realized.
333  //
334  // A connection between node and connector edge can be established by:
335  // - Interactive creation of a new edge object at the SdrView where
336  // the beginning or end point of the edge is placed on a connector
337  // (glueing point) of an already existing node object.
338  // - Interactive dragging of the beginning or end point of an
339  // existing connector edge object on the SdrView to a connector
340  // (glueing point) of an already existing node object.
341  // - Undo/Redo
342  // Moving node objects does not make any connections. Also not the
343  // direct shifting of edge endpoints on the SdrModel... Connections
344  // can also be established, if the connectors are not configured to
345  // be visible in the view.
346  //
347  // An existing connection between node and edge is retained for:
348  // - Dragging (Move/Resize/Rotate/...) of the node object
349  // - Moving a connector position in the node object
350  // - Simultaneous dragging (Move/Resize/Rotate/...) of the node and the
351  // edge
352  //
353  // A connection between node and edge can be removed by:
354  // - Deleting one of the objects
355  // - Dragging the edge object without simultaneously dragging the node
356  // - Deleting the connector at the node object
357  // - Undo/Redo/Repeat
358  // When dragging, the request to remove the connection must be
359  // requested from outside of the model (for example, from the
360  // SdrView). SdrEdgeObj::Move() itself does not remove the
361  // connection.
362  //
363  // Each node object can have connectors, so-called glue points. These
364  // are the geometric points at which the connecting edge object ends
365  // when the connection is established. By default, each object has no
366  // connectors. Nevertheless, one can dock an edge in certain view
367  // settings since then, e.g., connectors can be automatically
368  // generated at the 4 vertices of the node object when needed. Each
369  // object provides 2x4 so-called default connector positions, 4 at
370  // the vertices and 4 at the corner positions. In the normal case,
371  // these are located at the 8 handle positions; exceptions here are
372  // ellipses, parallelograms, ... . In addition, user-specific
373  // connectors can be set for each node object.
374  //
375  // Then there is also the possibility to dock an edge on an object
376  // with the attribute "bUseBestConnector". The best-matching
377  // connector position for the routing of the connection line is then
378  // used from the offering of connectors of the object or/and of the
379  // vertices. The user assigns this attribute by docking the node in
380  // its center (see, e.g., Visio).
381  // 09-06-1996: bUseBestConnector uses vertex glue points only.
382  //
383  // And here is some terminology:
384  // Connector : The connector object (edge object)
385  // Node : Any object to which a connector can be glued to, e.g., a rectangle,
386  // etc.
387  // Glue point: The point at which the connector is glued to the node object.
388  // There are:
389  // Vertex glue points: Each node object presents these glue
390  // points inherently. Perhaps there is already the option
391  // "automatically glue to object vertex" in Draw (default is
392  // on).
393  // Corner glue points: These glue points, too, are already
394  // auto-enabled on objects. Similar to the ones above,
395  // there may already be an option for them in Draw (default is
396  // off).
397  // In contrast to Visio, vertex glue points and corner glue
398  // points are not displayed in the UI; they are simply there (if
399  // the option is activated).
400  // Custom glue points: Any number of them are present on each
401  // node object. They can be made visible using the option
402  // (always visible when editing). At the moment, however, they
403  // are not yet fully implemented.
404  // Automatic glue point selection: If the connector is docked
405  // to the node object so that the black frame encompasses the
406  // entire object, then the connector tries to find the most
407  // convenient of the 4 vertex glue points (and only of those).
408 
409 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Point aMiddleLine
Definition: svdoedge.hxx:83
Point aObj2Line2
Definition: svdoedge.hxx:81
virtual void NbcResize(const Point &rRef, const Fraction &xFact, const Fraction &yFact) override
Definition: svdotxtr.cxx:102
Utility class SdrObjConnection.
Definition: svdoedge.hxx:37
virtual const tools::Rectangle & GetCurrentBoundRect() const
Definition: svdobj.cxx:960
tools::Long ImpGetLineOffset(SdrEdgeLineCode eLineCode, const XPolygon &rXP) const
Definition: svdoedge.cxx:131
void SetAutoVertex(bool rB)
Definition: svdoedge.hxx:60
virtual sal_uInt32 GetSnapPointCount() const override
snap to special points of an Object (polygon points, center of circle)
Definition: svdotext.cxx:1130
virtual SdrObjKind GetObjIdentifier() const override
Definition: svdotext.cxx:466
SdrObjConnection aCon2
Definition: svdoedge.hxx:114
virtual bool IsPolyObj() const
Definition: svdobj.cxx:1732
SdrEscapeDirection
Definition: svdglue.hxx:36
sal_uInt16 nNotifyingCount
Definition: svdoedge.hxx:143
sal_uInt16 nMiddleLine
Definition: svdoedge.hxx:90
Utility class SdrEdgeInfoRec.
Definition: svdoedge.hxx:73
long Long
sal_uInt16 nObj2Lines
Definition: svdoedge.hxx:89
std::unique_ptr< XPolygon > pEdgeTrack
Definition: svdoedge.hxx:115
tools::Long nAngle2
Definition: svdoedge.hxx:87
virtual sal_uInt32 GetHdlCount() const override
Via GetHdlCount the number of Handles can be retrieved.
Definition: svdotxdr.cxx:36
bool bEdgeTrackUserDefined
Definition: svdoedge.hxx:117
SdrEdgeInfoRec aEdgeInfo
Definition: svdoedge.hxx:144
SdrObject * pObj
Definition: svdhdl.hxx:136
void ResetVars()
Definition: svdoedge.cxx:49
virtual OUString TakeObjNameSingul() const override
Definition: svdotext.cxx:997
virtual void ConnectToNode(bool bTail1, SdrObject *pObj)
Definition: svdobj.cxx:2347
virtual bool hasSpecialDrag() const override
The standard transformations (Move,Resize,Rotate,Mirror,Shear) are taken over by the View (TakeXorPol...
Definition: svdotxdr.cxx:67
virtual void TRSetBaseGeometry(const basegfx::B2DHomMatrix &rMatrix, const basegfx::B2DPolyPolygon &rPolyPolygon) override
Definition: svdotext.cxx:1605
virtual sal_uInt32 GetPointCount() const
Definition: svdobj.cxx:1737
virtual const tools::Rectangle & GetSnapRect() const override
Definition: svdoattr.cxx:49
virtual SdrObjectUniquePtr getFullDragClone() const override
Definition: svdotext.cxx:2048
virtual void RecalcSnapRect() override
Snap is not done on the BoundRect but if possible on logic coordinates (i.e.
Definition: svdotext.cxx:1117
All geometrical data of an arbitrary object for use in undo/redo.
Definition: svdobj.hxx:172
SdrObjKind
Definition: svdobjkind.hxx:24
virtual bool BegCreate(SdrDragStat &rStat) override
Every object must be able to create itself interactively.
Definition: svdotxdr.cxx:182
virtual void NbcMirror(const Point &rRef1, const Point &rRef2) override
Definition: svdotxtr.cxx:232
sal_uInt16 GetConnectorId() const
Definition: svdoedge.hxx:65
Provides information about various ZObject properties.
Definition: svdobj.hxx:194
tools::Long nAngle1
Definition: svdoedge.hxx:86
Point aObj2Line3
Definition: svdoedge.hxx:82
virtual SdrGluePoint GetVertexGluePoint(sal_uInt16 nNum) const
Definition: svdobj.cxx:2254
virtual bool BckCreate(SdrDragStat &rStat) override
Definition: svdotxdr.cxx:225
virtual void SaveGeoData(SdrObjGeoData &rGeo) const override
Definition: svdotext.cxx:1414
virtual std::unique_ptr< sdr::properties::BaseProperties > CreateObjectSpecificProperties() override
Definition: svdotext.cxx:59
virtual void NbcShear(const Point &rRef, Degree100 nAngle, double tn, bool bVShear) override
Definition: svdotxtr.cxx:210
SdrObjConnection aCon1
Definition: svdoedge.hxx:113
bool TakeGluePoint(SdrGluePoint &rGP) const
Definition: svdoedge.cxx:59
Utility class SdrEdgeObjGeoData.
Definition: svdoedge.hxx:110
SdrObject * GetObject() const
Definition: svdoedge.hxx:66
SdrEdgeLineCode
Definition: svdoedge.hxx:70
virtual SdrObject * GetConnectedNode(bool bTail1) const
Definition: svdobj.cxx:2355
bool ImpIsHorzLine(SdrEdgeLineCode eLineCode, const XPolygon &rXP) const
Definition: svdoedge.cxx:112
virtual void TakeObjInfo(SdrObjTransformInfoRec &rInfo) const override
Definition: svdotext.cxx:442
virtual SdrTextObj * CloneSdrObject(SdrModel &rTargetModel) const override
Definition: svdotext.cxx:1074
void SetBestVertex(bool rB)
Definition: svdoedge.hxx:59
virtual void NbcSetPoint(const Point &rPnt, sal_uInt32 i)
Definition: svdobj.cxx:1756
virtual void handlePageChange(SdrPage *pOldPage, SdrPage *pNewPage) override
Definition: svdotext.cxx:493
virtual bool applySpecialDrag(SdrDragStat &rDrag) override
Definition: svdotxdr.cxx:149
virtual const SdrGluePointList * GetGluePointList() const
Definition: svdobj.cxx:2291
virtual OUString getSpecialDragComment(const SdrDragStat &rDrag) const override
Definition: svdotxdr.cxx:174
sal_uInt16 nObj1Lines
Definition: svdoedge.hxx:88
virtual void BrkCreate(SdrDragStat &rStat) override
Definition: svdotxdr.cxx:221
virtual ~SdrEdgeObjGeoData() override
Definition: svdoedge.cxx:2478
SdrObjConnection aCon2
Definition: svdoedge.hxx:140
Point aObj1Line3
Definition: svdoedge.hxx:80
void ImpSetLineOffset(SdrEdgeLineCode eLineCode, const XPolygon &rXP, tools::Long nVal)
Definition: svdoedge.cxx:124
void SetConnectorId(sal_uInt16 nId)
Definition: svdoedge.hxx:61
virtual void NbcMove(const Size &rSiz) override
The methods Move, Resize, Rotate, Mirror, Shear, SetSnapRect and SetLogicRect call the corresponding ...
Definition: svdotxtr.cxx:94
bool IsAutoVertex() const
Definition: svdoedge.hxx:64
virtual void NbcRotate(const Point &rRef, Degree100 nAngle, double sn, double cs) override
Definition: svdotxtr.cxx:186
Abstract DrawObject.
Definition: svdobj.hxx:258
void SetBestConnection(bool rB)
Definition: svdoedge.hxx:58
SdrObjConnection & GetConnection(bool bTail1)
Definition: svdoedge.hxx:197
Point & ImpGetLineOffsetPoint(SdrEdgeLineCode eLineCode)
Definition: svdoedge.cxx:88
virtual void DisconnectFromNode(bool bTail1)
Definition: svdobj.cxx:2351
virtual basegfx::B2DPolyPolygon TakeCreatePoly(const SdrDragStat &rDrag) const override
Polygon dragged by the user when creating the object.
Definition: svdotxdr.cxx:230
SdrEdgeInfoRec aEdgeInfo
Definition: svdoedge.hxx:118
sal_uInt16 nConId
Definition: svdoedge.hxx:45
virtual SdrGluePoint GetCornerGluePoint(sal_uInt16 nNum) const
Definition: svdobj.cxx:2275
std::unique_ptr< XPolygon > pEdgeTrack
Definition: svdoedge.hxx:142
virtual SdrGluePointList * ForceGluePointList()
Definition: svdobj.cxx:2298
virtual void Notify(SfxBroadcaster &rBC, const SfxHint &rHint) override
Detects when a stylesheet is changed.
Definition: svdoattr.cxx:61
#define SVXCORE_DLLPUBLIC
Definition: svxdllapi.h:35
bool IsBestConnection() const
Definition: svdoedge.hxx:63
SdrObjConnection aCon1
Definition: svdoedge.hxx:139
virtual void RestoreGeoData(const SdrObjGeoData &rGeo) override
Definition: svdotext.cxx:1422
std::unique_ptr< SdrObject, SdrObjectFreeOp > SdrObjectUniquePtr
Definition: svdobj.hxx:96
virtual bool beginSpecialDrag(SdrDragStat &rDrag) const
Definition: svdobj.cxx:1347
const SdrObjConnection & GetConnection(bool bTail1) const
Definition: svdoedge.hxx:214
PointerStyle
void SetEdgeTrackDirty()
Definition: svdoedge.hxx:210
sal_uInt16 ImpGetPolyIdx(SdrEdgeLineCode eLineCode, const XPolygon &rXP) const
Definition: svdoedge.cxx:100
virtual Point GetSnapPoint(sal_uInt32 i) const override
Definition: svdotext.cxx:1135
virtual bool EndCreate(SdrDragStat &rStat, SdrCreateCmd eCmd) override
Definition: svdotxdr.cxx:207
void SetSuppressDefaultConnect(bool bNew)
Definition: svdoedge.hxx:166
virtual void NbcSetAnchorPos(const Point &rPnt)
Definition: svdobj.cxx:1642
virtual bool TRGetBaseGeometry(basegfx::B2DHomMatrix &rMatrix, basegfx::B2DPolyPolygon &rPolyPolygon) const override
Definition: svdotext.cxx:1570
A SdrPage contains exactly one SdrObjList and a description of the physical page dimensions (size / m...
Definition: svdpage.hxx:365
SdrCreateCmd
Definition: svdtypes.hxx:26
virtual std::unique_ptr< sdr::contact::ViewContact > CreateObjectSpecificViewContact() override
Definition: svdotext.cxx:65
virtual bool MovCreate(SdrDragStat &rStat) override
Definition: svdotxdr.cxx:192
virtual basegfx::B2DPolyPolygon TakeXorPoly() const override
The Xor-Polygon is required by the View to drag the object.
Definition: svdotext.cxx:1079
virtual void TakeUnrotatedSnapRect(tools::Rectangle &rRect) const
Definition: svdotext.cxx:632
virtual Point GetPoint(sal_uInt32 i) const
Definition: svdobj.cxx:1742
Point aObj1Line2
Definition: svdoedge.hxx:79
virtual SdrObjectUniquePtr DoConvertToPolyObj(bool bBezier, bool bAddText) const override
Definition: svdotxtr.cxx:414
virtual void AddToHdlList(SdrHdlList &rHdlList) const override
Definition: svdotxdr.cxx:41
virtual void NbcSetSnapRect(const tools::Rectangle &rRect) override
Definition: svdotxtr.cxx:42
bool GetSuppressDefaultConnect() const
Definition: svdoedge.hxx:167
virtual std::unique_ptr< SdrObjGeoData > NewGeoData() const override
A derived class must override these 3 methods if it has own geometric data that must be saved for Und...
Definition: svdotext.cxx:1409
Utility class SdrEdgeObj.
Definition: svdoedge.hxx:127
SdrObject * pObj
Definition: svdoedge.hxx:44
virtual OUString TakeObjNamePlural() const override
Definition: svdotext.cxx:1056
virtual PointerStyle GetCreatePointer() const override
get the cursor/pointer that signals creating this object
Definition: svdotxdr.cxx:242