From f90dd4ffc4b679e61a2a8cf43853b7d3c72c3e83 Mon Sep 17 00:00:00 2001 From: randomguy3 Date: Tue, 17 Jan 2012 18:39:31 +0000 Subject: Calculate the head and tail of edges to be just where they contact the node (ie: behave more like tikz). git-svn-id: https://tikzit.svn.sourceforge.net/svnroot/tikzit/trunk@388 7c02a99a-9b00-45e3-bf44-6f3dd7fddb64 --- tikzit/src/common/Edge.h | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) (limited to 'tikzit/src/common/Edge.h') diff --git a/tikzit/src/common/Edge.h b/tikzit/src/common/Edge.h index 6069b9f..b92d7a7 100644 --- a/tikzit/src/common/Edge.h +++ b/tikzit/src/common/Edge.h @@ -141,15 +141,37 @@ typedef enum { */ @property (assign) EdgeBendMode bendMode; +/*! + @property head + @brief The starting point of the edge. + @detail This value is computed based on the source, target and + either bend or in/out angles. It is where the edge + makes contact with the source node. + */ +@property (readonly) NSPoint head; + +/*! + @property tail + @brief The ending point of the edge. + @detail This value is computed based on the source, target and + either bend or in/out angles. It is where the edge + makes contact with the target node. + */ +@property (readonly) NSPoint tail; + /*! @property cp1 - @brief The first control point. Computed from the source, target, and bend. + @brief The first control point of the edge. + @detail This value is computed based on the source, target and + either bend or in/out angles. */ @property (readonly) NSPoint cp1; /*! @property cp2 - @brief The second control point. Computed from the source, target, and bend. + @brief The second control point of the edge. + @detail This value is computed based on the source, target and + either bend or in/out angles. */ @property (readonly) NSPoint cp2; -- cgit v1.2.3