Exemplo n.º 1
0
 int getArrowPioner(Point locate)
 {
     for (int i = 0; i < skillList.Count; i++)
     {
         var currTail = skillList[i].getTail;
         foreach (int ed in currTail)
         {
             if (Geom.pointInArrowHand(locate, Geom.getArrowHead(circleCenter[i], circleCenter[ed], size_circle)))
             {
                 return(i);
             }
         }
     }
     return(selectedId_None);
 }
Exemplo n.º 2
0
        private void DrawArrow(PointF _st, PointF _ed, DrawStyle start)
        {
            Point st     = Point.Round(_st);
            Point ed     = Point.Round(_ed);
            int   length = Geom.Distance(st, ed);

            if (length <= size_circle * 2)
            {
                return;
            }
            Point[] pointList = Geom.getArrowHead(st, ed, size_circle);
            Geom.scaleLine(ref st, ref ed, size_circle);
            if (start.ArrowLine.IsEmpty == false)
            {
                Pen edPen = new Pen(start.ArrowLine);
                edPen.Width = lineW;
                buffer.DrawLine(edPen, st, pointList[0]);
            }
            DrawArrow(pointList, start);
        }