LCOV - code coverage report
Current view: top level - libreoffice/svx/inc/svx - svdoedge.hxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 7 18 38.9 %
Date: 2012-12-27 Functions: 5 16 31.2 %
Legend: Lines: hit not hit

          Line data    Source code
       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 _SVDOEDGE_HXX
      21             : #define _SVDOEDGE_HXX
      22             : 
      23             : #include <svx/svdotext.hxx>
      24             : #include <svx/svdglue.hxx>
      25             : #include "svx/svxdllapi.h"
      26             : 
      27             : //************************************************************
      28             : //   Vorausdeklarationen
      29             : //************************************************************
      30             : 
      31             : class SdrDragMethod;
      32             : class SdrPageView;
      33             : 
      34             : namespace sdr { namespace properties {
      35             :     class ConnectorProperties;
      36             : }}
      37             : 
      38             : //************************************************************
      39             : //   Hilfsklasse SdrObjConnection
      40             : //************************************************************
      41             : 
      42             : class SdrObjConnection
      43             : {
      44             :     friend class                SdrEdgeObj;
      45             :     friend class                ImpEdgeHdl;
      46             :     friend class                SdrCreateView;
      47             : 
      48             : protected:
      49             :     Point                       aObjOfs;       // Wird beim Draggen eines Knotens gesetzt
      50             :     SdrObject*                  pObj;          // Referenziertes Objekt
      51             :     long                        nXDist;        // Hor. Objektabstand wenn bXDistOvr=TRUE
      52             :     long                        nYDist;        // Vert. Objektabstand wenn bYDistOvr=TRUE
      53             :     sal_uInt16                      nConId;        // Konnektornummer
      54             : 
      55             :     // bitfield
      56             :     unsigned                    bBestConn : 1;   // sal_True= es wird der guenstigste Konnektor gesucht
      57             :     unsigned                    bBestVertex : 1; // sal_True= es wird der guenstigste Scheitelpunkt zum konnekten gesucht
      58             :     unsigned                    bXDistOvr : 1;   // sal_True= Hor. Objektabstand wurde gedragt (Overwrite)
      59             :     unsigned                    bYDistOvr : 1;   // sal_True= Vert. Objektabstand wurde gedragt (Overwrite)
      60             :     unsigned                    bAutoVertex : 1; // AutoConnector am Scheitelpunkt nCon
      61             :     unsigned                    bAutoCorner : 1; // AutoConnector am Eckpunkt nCon
      62             : 
      63             : public:
      64          10 :     SdrObjConnection() { ResetVars(); }
      65             :     SVX_DLLPUBLIC ~SdrObjConnection();
      66             : 
      67             :     void ResetVars();
      68             :     bool TakeGluePoint(SdrGluePoint& rGP, bool bSetAbsolutePos) const;
      69             : 
      70           0 :     inline void SetBestConnection( sal_Bool rB ) { bBestConn = rB; };
      71           0 :     inline void SetBestVertex( sal_Bool rB ) { bBestVertex = rB; };
      72           0 :     inline void SetAutoVertex( sal_Bool rB ) { bAutoVertex = rB; };
      73           0 :     inline void SetConnectorId( sal_uInt16 nId ) { nConId = nId; };
      74             : 
      75           0 :     inline sal_Bool IsBestConnection() const { return bBestConn; };
      76             :     inline sal_Bool IsBestVertex() const { return bBestVertex; };
      77           0 :     inline sal_Bool IsAutoVertex() const { return bAutoVertex; };
      78           0 :     inline sal_uInt16 GetConnectorId() const { return nConId; };
      79           0 :     inline SdrObject* GetObject() const { return pObj; }
      80             : };
      81             : 
      82             : //************************************************************
      83             : //   Hilfsklasse SdrEdgeInfoRec
      84             : //************************************************************
      85             : 
      86             : enum SdrEdgeLineCode {OBJ1LINE2,OBJ1LINE3,OBJ2LINE2,OBJ2LINE3,MIDDLELINE};
      87             : 
      88             : class SdrEdgeInfoRec
      89             : {
      90             : public:
      91             :     // Die 5 Distanzen werden beim draggen bzw. per SetAttr gesetzt und von
      92             :     // ImpCalcEdgeTrack ausgewertet. Per Get/SetAttr/Get/SetStyleSh werden
      93             :     // jedoch nur 0-3 longs transportiert.
      94             :     Point                       aObj1Line2;
      95             :     Point                       aObj1Line3;
      96             :     Point                       aObj2Line2;
      97             :     Point                       aObj2Line3;
      98             :     Point                       aMiddleLine;
      99             : 
     100             :     // Nachfolgende Werte werden von ImpCalcEdgeTrack gesetzt
     101             :     long                        nAngle1;           // Austrittswinkel am Obj1
     102             :     long                        nAngle2;           // Austrittswinkel am Obj2
     103             :     sal_uInt16                      nObj1Lines;        // 1..3
     104             :     sal_uInt16                      nObj2Lines;        // 1..3
     105             :     sal_uInt16                      nMiddleLine;       // 0xFFFF=keine, sonst Punktnummer des Linienbeginns
     106             :     char                        cOrthoForm;        // Form des Ortho-Verbindes, z.B. 'Z','U',I','L','S',...
     107             : 
     108             : public:
     109          56 :     SdrEdgeInfoRec()
     110             :     :   nAngle1(0),
     111             :         nAngle2(0),
     112             :         nObj1Lines(0),
     113             :         nObj2Lines(0),
     114             :         nMiddleLine(0xFFFF),
     115          56 :         cOrthoForm(0)
     116          56 :     {}
     117             : 
     118             :     Point& ImpGetLineVersatzPoint(SdrEdgeLineCode eLineCode);
     119           0 :     const Point& ImpGetLineVersatzPoint(SdrEdgeLineCode eLineCode) const { return ((SdrEdgeInfoRec*)this)->ImpGetLineVersatzPoint(eLineCode); }
     120             :     sal_uInt16 ImpGetPolyIdx(SdrEdgeLineCode eLineCode, const XPolygon& rXP) const;
     121             :     bool ImpIsHorzLine(SdrEdgeLineCode eLineCode, const XPolygon& rXP) const;
     122             :     void ImpSetLineVersatz(SdrEdgeLineCode eLineCode, const XPolygon& rXP, long nVal);
     123             :     long ImpGetLineVersatz(SdrEdgeLineCode eLineCode, const XPolygon& rXP) const;
     124             : };
     125             : 
     126             : //************************************************************
     127             : //   Hilfsklasse SdrEdgeObjGeoData
     128             : //************************************************************
     129             : 
     130             : class SdrEdgeObjGeoData : public SdrTextObjGeoData
     131             : {
     132             : public:
     133             :     SdrObjConnection            aCon1;  // Verbindungszustand des Linienanfangs
     134             :     SdrObjConnection            aCon2;  // Verbindungszustand des Linienendes
     135             :     XPolygon*                   pEdgeTrack;
     136             :     sal_Bool                    bEdgeTrackDirty;// sal_True=Verbindungsverlauf muss neu berechnet werden.
     137             :     sal_Bool                    bEdgeTrackUserDefined;
     138             :     SdrEdgeInfoRec              aEdgeInfo;
     139             : 
     140             : public:
     141             :     SdrEdgeObjGeoData();
     142             :     virtual ~SdrEdgeObjGeoData();
     143             : };
     144             : 
     145             : //************************************************************
     146             : //   Hilfsklasse SdrEdgeObj
     147             : //************************************************************
     148             : 
     149             : class SVX_DLLPUBLIC SdrEdgeObj : public SdrTextObj
     150             : {
     151             : private:
     152             :     // to allow sdr::properties::ConnectorProperties access to ImpSetAttrToEdgeInfo()
     153             :     friend class sdr::properties::ConnectorProperties;
     154             : 
     155             :     friend class                SdrCreateView;
     156             :     friend class                ImpEdgeHdl;
     157             : 
     158             : protected:
     159             :     virtual sdr::contact::ViewContact* CreateObjectSpecificViewContact();
     160             :     virtual sdr::properties::BaseProperties* CreateObjectSpecificProperties();
     161             : 
     162             :     SdrObjConnection            aCon1;  // Verbindungszustand des Linienanfangs
     163             :     SdrObjConnection            aCon2;  // Verbindungszustand des Linienendes
     164             : 
     165             :     XPolygon*                   pEdgeTrack;
     166             :     sal_uInt16                  nNotifyingCount; // Verrieglung
     167             :     SdrEdgeInfoRec              aEdgeInfo;
     168             : 
     169             :     // bitfield
     170             :     unsigned                    bEdgeTrackDirty : 1; // sal_True=Verbindungsverlauf muss neu berechnet werden.
     171             :     unsigned                    bEdgeTrackUserDefined : 1;
     172             : 
     173             :     // #109007#
     174             :     // Bool to allow supporession of default connects at object
     175             :     // inside test (HitTest) and object center test (see ImpFindConnector())
     176             :     unsigned                    mbSuppressDefaultConnect : 1;
     177             : 
     178             :     // #110649#
     179             :     // Flag value for avoiding death loops when calculating BoundRects
     180             :     // from circularly connected connectors. A coloring algorythm is used
     181             :     // here. When the GetCurrentBoundRect() calculation of a SdrEdgeObj
     182             :     // is running, the flag is set, else it is always sal_False.
     183             :     unsigned                    mbBoundRectCalculationRunning : 1;
     184             : 
     185             : public:
     186             :     // #109007#
     187             :     // Interface to default connect suppression
     188             :     void SetSuppressDefaultConnect(sal_Bool bNew) { mbSuppressDefaultConnect = bNew; }
     189           0 :     sal_Bool GetSuppressDefaultConnect() const { return mbSuppressDefaultConnect; }
     190             : 
     191             :     // #110649#
     192           3 :     sal_Bool IsBoundRectCalculationRunning() const { return mbBoundRectCalculationRunning; }
     193             : 
     194             : protected:
     195             :     virtual void Notify(SfxBroadcaster& rBC, const SfxHint& rHint);
     196             : 
     197             :     XPolygon ImpCalcObjToCenter(const Point& rStPt, long nEscAngle, const Rectangle& rRect, const Point& rCenter) const;
     198             :     void ImpRecalcEdgeTrack();  // Neuberechnung des Verbindungsverlaufs
     199             :     XPolygon ImpCalcEdgeTrack(const XPolygon& rTrack0, SdrObjConnection& rCon1, SdrObjConnection& rCon2, SdrEdgeInfoRec* pInfo) const;
     200             :     XPolygon ImpCalcEdgeTrack(const Point& rPt1, long nAngle1, const Rectangle& rBoundRect1, const Rectangle& rBewareRect1,
     201             :         const Point& rPt2, long nAngle2, const Rectangle& rBoundRect2, const Rectangle& rBewareRect2,
     202             :         sal_uIntPtr* pnQuality, SdrEdgeInfoRec* pInfo) const;
     203             :     static bool ImpFindConnector(const Point& rPt, const SdrPageView& rPV, SdrObjConnection& rCon, const SdrEdgeObj* pThis, OutputDevice* pOut=NULL);
     204             :     sal_uInt16 ImpCalcEscAngle(SdrObject* pObj, const Point& aPt2) const;
     205             :     void ImpSetTailPoint(bool bTail1, const Point& rPt);
     206             :     void ImpUndirtyEdgeTrack();  // eventuelle Neuberechnung des Verbindungsverlaufs
     207             :     void ImpDirtyEdgeTrack();   // invalidate connector path, so it will be recalculated next time
     208             :     void ImpSetAttrToEdgeInfo(); // Werte vom Pool nach aEdgeInfo kopieren
     209             :     void ImpSetEdgeInfoToAttr(); // Werte vom aEdgeInfo in den Pool kopieren
     210             : 
     211             : public:
     212             :     TYPEINFO();
     213             : 
     214             :     SdrEdgeObj();
     215             :     virtual ~SdrEdgeObj();
     216             : 
     217          30 :     SdrObjConnection& GetConnection(bool bTail1) { return *(bTail1 ? &aCon1 : &aCon2); }
     218             :     virtual void TakeObjInfo(SdrObjTransformInfoRec& rInfo) const;
     219             :     virtual sal_uInt16 GetObjIdentifier() const;
     220             :     virtual const Rectangle& GetCurrentBoundRect() const;
     221             :     virtual const Rectangle& GetSnapRect() const;
     222             :     virtual bool IsNode() const;
     223             :     virtual SdrGluePoint GetVertexGluePoint(sal_uInt16 nNum) const;
     224             :     virtual SdrGluePoint GetCornerGluePoint(sal_uInt16 nNum) const;
     225             :     virtual const SdrGluePointList* GetGluePointList() const;
     226             :     virtual SdrGluePointList* ForceGluePointList();
     227             :     virtual bool IsEdge() const;
     228             : 
     229             :     // bTail1=TRUE: Linienanfang, sonst LinienEnde
     230             :     // pObj=NULL: Disconnect
     231          10 :     void SetEdgeTrackDirty() { bEdgeTrackDirty=sal_True; }
     232             :     void ConnectToNode(bool bTail1, SdrObject* pObj);
     233             :     void DisconnectFromNode(bool bTail1);
     234             :     SdrObject* GetConnectedNode(bool bTail1) const;
     235           0 :     const SdrObjConnection& GetConnection(bool bTail1) const { return *(bTail1 ? &aCon1 : &aCon2); }
     236             :     bool CheckNodeConnection(bool bTail1) const;
     237             : 
     238             :     virtual void RecalcSnapRect();
     239             :     virtual void TakeUnrotatedSnapRect(Rectangle& rRect) const;
     240             :     virtual SdrEdgeObj* Clone() const;
     241             :     SdrEdgeObj& operator=(const SdrEdgeObj& rObj);
     242             :     virtual void TakeObjNameSingul(String& rName) const;
     243             :     virtual void TakeObjNamePlural(String& rName) const;
     244             : 
     245             :     void    SetEdgeTrackPath( const basegfx::B2DPolyPolygon& rPoly );
     246             :     basegfx::B2DPolyPolygon GetEdgeTrackPath() const;
     247             : 
     248             :     virtual basegfx::B2DPolyPolygon TakeXorPoly() const;
     249             :     virtual sal_uInt32 GetHdlCount() const;
     250             :     virtual SdrHdl* GetHdl(sal_uInt32 nHdlNum) const;
     251             : 
     252             :     // special drag methods
     253             :     virtual bool hasSpecialDrag() const;
     254             :     virtual bool beginSpecialDrag(SdrDragStat& rDrag) const;
     255             :     virtual bool applySpecialDrag(SdrDragStat& rDrag);
     256             :     virtual String getSpecialDragComment(const SdrDragStat& rDrag) const;
     257             : 
     258             :     // FullDrag support
     259             :     virtual SdrObject* getFullDragClone() const;
     260             : 
     261             :     virtual void NbcSetSnapRect(const Rectangle& rRect);
     262             :     virtual void NbcMove(const Size& aSize);
     263             :     virtual void NbcResize(const Point& rRefPnt, const Fraction& aXFact, const Fraction& aYFact);
     264             : 
     265             :     // #102344# Added missing implementation
     266             :     virtual void NbcSetAnchorPos(const Point& rPnt);
     267             : 
     268             :     virtual bool BegCreate(SdrDragStat& rStat);
     269             :     virtual bool MovCreate(SdrDragStat& rStat);
     270             :     virtual bool EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd);
     271             :     virtual bool BckCreate(SdrDragStat& rStat);
     272             :     virtual void BrkCreate(SdrDragStat& rStat);
     273             :     virtual basegfx::B2DPolyPolygon TakeCreatePoly(const SdrDragStat& rDrag) const;
     274             :     virtual Pointer GetCreatePointer() const;
     275             :     virtual SdrObject* DoConvertToPolyObj(sal_Bool bBezier, bool bAddText) const;
     276             : 
     277             :     virtual sal_uInt32 GetSnapPointCount() const;
     278             :     virtual Point GetSnapPoint(sal_uInt32 i) const;
     279             :     virtual sal_Bool IsPolyObj() const;
     280             :     virtual sal_uInt32 GetPointCount() const;
     281             :     virtual Point GetPoint(sal_uInt32 i) const;
     282             :     virtual void NbcSetPoint(const Point& rPnt, sal_uInt32 i);
     283             : 
     284             :     virtual SdrObjGeoData* NewGeoData() const;
     285             :     virtual void SaveGeoData(SdrObjGeoData& rGeo) const;
     286             :     virtual void RestGeoData(const SdrObjGeoData& rGeo);
     287             : 
     288             :     /** updates edges that are connected to the edges of this object
     289             :         as if the connected objects send a repaint broadcast
     290             :         #103122#
     291             :     */
     292             :     void Reformat();
     293             : 
     294             :     // helper methods for the StarOffice api
     295             :     Point GetTailPoint( sal_Bool bTail ) const;
     296             :     void SetTailPoint( sal_Bool bTail, const Point& rPt );
     297             :     void setGluePointIndex( sal_Bool bTail, sal_Int32 nId = -1 );
     298             :     sal_Int32 getGluePointIndex( sal_Bool bTail );
     299             : 
     300             :     virtual sal_Bool TRGetBaseGeometry(basegfx::B2DHomMatrix& rMatrix, basegfx::B2DPolyPolygon& rPolyPolygon) const;
     301             :     virtual void TRSetBaseGeometry(const basegfx::B2DHomMatrix& rMatrix, const basegfx::B2DPolyPolygon& rPolyPolygon);
     302             : 
     303             :     // for geometry access
     304             :     ::basegfx::B2DPolygon getEdgeTrack() const;
     305             : 
     306             :     // helper method for SdrDragMethod::AddConnectorOverlays. Adds a overlay polygon for
     307             :     // this connector to rResult.
     308             :     basegfx::B2DPolygon ImplAddConnectorOverlay(SdrDragMethod& rDragMethod, bool bTail1, bool bTail2, bool bDetail) const;
     309             : };
     310             : 
     311             : ////////////////////////////////////////////////////////////////////////////////////////////////////
     312             : //
     313             : // Zur Bestimmung der Verlaufslinie werden folgende Item-Parameter des SdrItemPool verwendet:
     314             : //
     315             : //  sal_uInt16 EdgeFlowAngle       Default 9000 (=90.00 Deg), min 0, max 9000
     316             : //      Verlauffreiheitswinkel.
     317             : //      Der Winkel, in dem die Verbindungslinie verlaufen darf.
     318             : //
     319             : //  sal_uInt16 EdgeEscAngle        Default 9000 (=90.00 Deg), min 0, max 9000
     320             : //      Objektaustrittswinkel.
     321             : //      Der Winkel, in dem die Verbindungslinie aus dem Objekt austreten darf.
     322             : //
     323             : //  sal_Bool   EdgeEscAsRay        Default FALSE
     324             : //      sal_True= die Verbindungslinie tritt aus dem Obj Strahlenfoermig aus.
     325             : //      Also Winkelvorgabe durch die Strecke ObjMitte/Konnektor.
     326             : //
     327             : //  sal_Bool   EdgeEscUseObjAngle  Default FALSE
     328             : //      Objektdrehwinkelberuecksichtigung.
     329             : //      sal_True= Bei der Bestimmung des Objektaustrittswinkels wird der
     330             : //      Drehwinkel des Objekts als Offset beruecksichtigt.
     331             : //
     332             : //  sal_uIntPtr  EdgeFlowDefDist     Default 0, min 0, max ?
     333             : //      Das ist der Default-Mindestabstand der bei der Berechnung der
     334             : //      Verbindungslinie zu den angedockten Objekten in logischen Einheiten.
     335             : //      Dieser Abstand wird innerhalb des Objektes "ueberschrieben", sobald
     336             : //      der User an den Linien draggd. Beim Andocken an ein neues Objekt wird
     337             : //      dann jedoch wieder dieser Default verwendet.
     338             : //
     339             : //
     340             : // Allgemeines zu Konnektoren:
     341             : //
     342             : // Es gibt Knoten und Kantenobjekte. Zwei Knoten koennen durch eine Kante
     343             : // miteinander verbunden werden. Ist eine Kante nur an einem Ende an einen
     344             : // Knoten geklebt, ist das andere Ende auf einer absoluten Position im Doc
     345             : // fixiert. Ebenso ist es natuerlich auch moeglich, dass eine Kante an beiden
     346             : // Enden "frei", also nicht mit einem Knotenobjekt verbunden ist.
     347             : //
     348             : // Ein Kantenobjekt kann theoretisch auch gleichzeitig Knotenobjekt sein. In
     349             : // der ersten Version wird das jedoch noch nicht realisiert werden.
     350             : //
     351             : // Eine Verbindung zwischen Knoten und Kante kann hergestellt werden durch:
     352             : // - Interaktives erzeugen eines neuen Kantenobjekts an der SdrView wobei
     353             : //   Anfangs- bzw. Endpunkt der Kante auf ein Konnektor (Klebestelle) eines
     354             : //   bereits vorhandenen Knotenobjekts gelegt wird.
     355             : // - Interaktives draggen des Anfangs- bzw. Endpunkts eines bestehenden
     356             : //   Kantenobjekts an der SdrView auf ein Konnektor (Klebestelle) eines
     357             : //   bereits vorhandenen Knotenobjekts.
     358             : // - Undo/Redo
     359             : // Verschieben von Knotenobjekten stellt keine Verbindungen her. Ebenso auch
     360             : // nicht das direkte Verschieben von Kantenendpunkten am SdrModel...
     361             : // Verbindungen koennen auch hergestellt werden, wenn die Konnektoren an der
     362             : // View nicht sichtbar geschaltet sind.
     363             : //
     364             : // Eine vorhandene Verbindung zwischen Knoten und Kante bleibt erhalten bei:
     365             : // - Draggen (Move/Resize/Rotate/...) des Knotenobjekts
     366             : // - Verschieben einer Konnektorposition im Knotemobjekt
     367             : // - gleichzeitiges Draggen (Move/Resize/Rotate/...) von Knoten und Kante
     368             : //
     369             : // Eine Verbindung zwischen Knoten und Kante kann geloesst werden durch:
     370             : // - Loeschen eines der Objekte
     371             : // - Draggen des Kantenobjekts ohne gleichzeitiges Draggen des Knotens
     372             : // - Loeschen des Konnektors am Knotenobjekt
     373             : // - Undo/Redo/Repeat
     374             : // Beim Draggen muss die Aufforderung zum loesen der Verbindung von ausserhalb
     375             : // des Models befohlen werden (z.B. von der SdrView). SdrEdgeObj::Move() loesst
     376             : // die Verbindung nicht selbsttaetig.
     377             : //
     378             : // Jedes Knotenobjekt kann Konnektoren, sog. Klebestellen besitzen. Das sind die
     379             : // geometrischen Punkte, an denen das verbindende Kantenobjekt bei hergestellter
     380             : // Verbindung endet. Defaultmaessig hat jedes Objekt keine Konnektoren. Trotzdem
     381             : // kann man bei bestimmten View-Einstellungen eine Kante andocken, da dann z.B.
     382             : // an den 4 Scheitelpunkten des Knotenobjekts bei Bedarf automatisch Konnektoren
     383             : // generiert werden. Jedes Objekt liefert dafuer 2x4 sog. Default-Konnektorposi-
     384             : // tionen, 4 an den Scheitelpunkten und 4 an den Eckpositionen. Im Normalfall
     385             : // liegen diese an den 8 Handlepositionen; Ausnahmen bilden hier Ellipsen,
     386             : // Parallelogramme, ... . Darueberhinaus koennen auch an jedem Knotenobjekt
     387             : // anwenderspeziefische Konnektoren gesetzt werden.
     388             : //
     389             : // Dann gibt es noch die Moeglichkeit, ein Kante an einem Objekt mit dem
     390             : // Attribut "bUseBestConnector" anzudocken. Es wird dann aus dem Angebot der
     391             : // Konnektoren des Objekts oder/und der Scheitelpunkte, jeweils die fuer den
     392             : // Verlauf der Verbindungslinie guenstigste Konnektorposition verwendet. Der
     393             : // Anwender vergibt dieses Attribut, indem er den Knoten in seiner Mitte
     394             : // andockt (siehe z.B. Visio).
     395             : // 09-06-1996: bUseBestConnector verwendet nur Scheitelpunktklebepunkte.
     396             : //
     397             : // Und hier noch etwas Begriffsdefinition:
     398             : //   Verbinder : Eben das Verbinderobjekt (Kantenobjekt)
     399             : //   Knoten    : Ein beliebiges Objekt, an dem ein Verbinder drangeklebt
     400             : //               werden kann, z.B. ein Rechteck, ...
     401             : //   Klebepunkt: Der Punkt, an dem der Verbinder an das Knotenobjekt
     402             : //               geklebt wird. Hierbei gibt es:
     403             : //                 Scheitelpunktklebepunkte: Jedes Knotenobjekt hat diese
     404             : //                     Klebepunkte von Natur aus. Moeglicherweise gibt es
     405             : //                     im Draw bereits die Option "Automatisch ankleben an
     406             : //                     Objektscheitelpunkte" (default an)
     407             : //                 Eckpunktklebepunkte: Auch diese Klebepunkte sind den
     408             : //                     Objekten von mir bereits mitgegeben. Wie die oben
     409             : //                     erwaehnten gibt es fuer diese moeglicherweise
     410             : //                     bereits auch eine Option im Draw. (default aus)
     411             : //                 Scheitelpunktklebepunkte und Eckpunktklebepunkte sind
     412             : //                     im Gegensatz zu Visio nicht optisch sichtbar; sie
     413             : //                     sind eben einfach da (wenn Option eingeschaltet).
     414             : //                 Benutzerdefinierte Klebepunkte: Gibt es an jedem
     415             : //                     Knotenobjekt beliebig viele. Per Option koennen sie
     416             : //                     sichtbar geschaltet werden (beim editieren immer
     417             : //                     sichtbar). Zur Zeit sind die jedoch noch nicht ganz
     418             : //                     fertigimplementiert.
     419             : //                 Automatische Klebepunktwahl: Wird der Verbinder so an
     420             : //                     das Knotenobjekt gedockt, dass der schwarke Rahmen
     421             : //                     das gesamte Objekt umfasst, so versucht der
     422             : //                     Verbinder von den 4 Scheitelpunktklebepunkten (und
     423             : //                     zwar nur von denen) den guenstigsten herauszufinden.
     424             : //
     425             : //////////////////////////////////////////////////////////////////////////////////////////////////
     426             : 
     427             : #endif //_SVDOEDGE_HXX
     428             : 
     429             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10