Esempio n. 1
0
        public void CreateLines()
        {
            TArrowLine    Line;
            Point         P = new Point();
            TTfeRectShape Shape;

            FreeWorkLines();
            F_LastLineId = F_NumberLineId;
            F_LastLineId++;
            Line  = new TArrowLine(F_Step, F_LastLineId);
            Shape = (TTfeRectShape)GetWorkShape(0);
            Shape.GetTailPoint(0, ref P);
            Line.xStart = StartPoint.X;
            Line.yStart = StartPoint.Y;
            Line.xEnd   = P.X;
            Line.yEnd   = P.Y;
            Line.Bend   = CalcBend(Line.xStart, Line.xEnd);
            AddLine(Line);
            Shape.AddWorkLine(Line);

            F_LastLineId++;
            Line  = new TArrowLine(F_Step, F_LastLineId);
            Shape = (TTfeRectShape)(GetWorkShape(0));
            Shape.GetTailPoint(1, ref P);
            Line.xStart = P.X;
            Line.yStart = P.Y;
            Line.xEnd   = P.X + 2 * F_Step;
            Line.yEnd   = P.Y;
            Line.Bend   = CalcBend(Line.xStart, Line.xEnd);
            AddLine(Line);
            Shape.AddWorkLine(Line);
        }
Esempio n. 2
0
        public TArrowLine GetWorkLine(int num)
        {
            TArrowLine Res = null;

            if ((num >= 0) || (num < WorkLines.Count))
            {
                Res = (TArrowLine)(WorkLines.ElementAt(num));
            }
            return(Res);
        }
Esempio n. 3
0
        void CreateLines()
        {
            TArrowLine     Line, Lnb, Lnb3;
            Point          P1 = new Point(), P2 = new Point();
            int            tmp_x;
            TTfeRectShape  Rct;
            TTfeRhombShape Rhomb;

            FreeWorkLines();
            F_LastLineId = F_NumberLineId;

            Rhomb = (TTfeRhombShape)(GetWorkShape(0));
            Rct   = (TTfeRectShape)(GetWorkShape(1));
            Rhomb.GetTailPoint(0, ref P1);
            F_LastLineId++;
            //1
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = StartPoint.X;
            Line.yStart = StartPoint.Y;
            Line.xEnd   = P1.X;
            Line.yEnd   = P1.Y;
            Line.Bend   = CalcBend(Line.xStart, Line.xEnd);
            AddLine(Line);
            Lnb = Line;

            Rhomb.GetTailPoint(1, ref P1);
            Rct.GetTailPoint(0, ref P2);

            F_LastLineId++;
            //2
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = P1.X;
            Line.yStart = P1.Y;
            Line.xEnd   = P2.X;
            Line.yEnd   = P2.Y;
            AddLine(Line);


            Rct.GetTailPoint(1, ref P1);
            F_LastLineId++;
            //3
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = P1.X;
            Line.yStart = P1.Y;
            Line.xEnd   = P1.X + 4 * F_Step;
            Line.yEnd   = Lnb.yEnd;
            Line.Bend   = CalcBend(Line.xStart, Line.xEnd);
            AddLine(Line);
            Lnb3 = Line;

            Rhomb.GetTailPoint(2, ref P1);
            F_LastLineId++;
            //4
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = P1.X;
            Line.yStart = P1.Y;
            Line.xEnd   = Lnb3.xEnd;
            Line.yEnd   = Lnb3.yEnd;
            Line.Bend   = CalcBend(Line.xStart, Line.xEnd);
            AddLine(Line);


            //5
            F_LastLineId++;
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = Lnb3.xEnd;
            Line.yStart = Lnb3.yEnd;
            Line.xEnd   = Lnb3.xEnd + 2 * F_Step;
            Line.yEnd   = Lnb3.yEnd;
            AddLine(Line);
        }
Esempio n. 4
0
        void CreateLines()
        {
            TArrowLine    Line, Lnb;
            Point         P = new Point(), P2 = new Point();
            int           tmp_x;
            TTfeRectShape Shape1, Shape2;

            FreeWorkLines();
            F_LastLineId = F_NumberLineId;

            Shape1 = (TTfeRectShape)(GetWorkShape(0));
            Shape2 = (TTfeRectShape)(GetWorkShape(1));
            Shape1.GetTailPoint(0, ref P);


            F_LastLineId++;
            //1
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = StartPoint.X;
            Line.yStart = StartPoint.Y;
            Line.xEnd   = P.X - 3 * F_Step;
            Line.yEnd   = P.Y + 4 * F_Step;
            Line.Bend   = CalcBend(Line.xStart, Line.xEnd);
            AddLine(Line);
            Lnb = Line;
            Shape1.AddWorkLine(Line);



            F_LastLineId++;
            //2
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = Lnb.xEnd;
            Line.yStart = Lnb.yEnd;
            Line.xEnd   = P.X;
            Line.yEnd   = P.Y;
            Line.Bend   = CalcBend(Line.xStart, Line.xEnd);
            //stas   Line.Prepare();
            AddLine(Line);
            Shape1.AddWorkLine(Line);



            Shape1.GetTailPoint(1, ref P);
            Shape2.GetTailPoint(1, ref P2);

            tmp_x = P.X;
            if (tmp_x < P2.X)
            {
                tmp_x = P2.X;
            }
            tmp_x = tmp_x + 3 * F_Step;


            F_LastLineId++;
            //3
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = P.X;
            Line.yStart = P.Y;

            Line.xEnd = tmp_x;
            Line.yEnd = Lnb.yEnd;
            Line.Bend = CalcBend(Line.xStart, Line.xEnd);
            AddLine(Line);
            Shape1.AddWorkLine(Line);


            F_LastLineId++;
            //4
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = P2.X;
            Line.yStart = P2.Y;

            Line.xEnd = tmp_x;
            Line.yEnd = Lnb.yEnd;
            Line.Bend = CalcBend(Line.xStart, Line.xEnd);
            AddLine(Line);
            Shape2.AddWorkLine(Line);


            Shape2.GetTailPoint(0, ref P2);
            F_LastLineId++;
            //5
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = Lnb.xEnd;
            Line.yStart = Lnb.yEnd;

            Line.xEnd = P2.X;
            Line.yEnd = P2.Y;
            Line.Bend = CalcBend(Line.xStart, Line.xEnd);
            AddLine(Line);
            Shape2.AddWorkLine(Line);


            F_LastLineId++;
            //6
            Lnb = (TArrowLine)(GetWorkLine(2));

            Line            = new TArrowLine(F_Step, F_LastLineId);
            Line.PointStart = Lnb.PointEnd;
            Line.xEnd       = Lnb.PointEnd.X + 2 * F_Step;
            Line.yEnd       = Lnb.PointEnd.Y;
            AddLine(Line);
            Shape2.AddWorkLine(Line);
        }
Esempio n. 5
0
        void CreateLines()
        {
            TArrowLine     Line, Lnb;
            Point          P1 = new Point(), P2 = new Point();
            int            tmp_x;
            TTfeRectShape  Rct;
            TTfeRhombShape Rhomb;

            FreeWorkLines();
            F_LastLineId = F_NumberLineId;

            Rhomb = (TTfeRhombShape)(GetWorkShape(0));
            Rct   = (TTfeRectShape)(GetWorkShape(1));
            Rhomb.GetTailPoint(0, ref P1);
            F_LastLineId++;
            //1
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = StartPoint.X;
            Line.yStart = StartPoint.Y;
            Line.xEnd   = P1.X;
            Line.yEnd   = P1.Y;
            Line.Bend   = CalcBend(Line.xStart, Line.xEnd);
            AddLine(Line);
            Lnb = Line;

            Rhomb.GetTailPoint(1, ref P1);
            Rct.GetTailPoint(0, ref P2);

            F_LastLineId++;
            //2
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = P1.X;
            Line.yStart = P1.Y;
            Line.xEnd   = P2.X;
            Line.yEnd   = P2.Y;
            AddLine(Line);

            Rct.GetTailPoint(1, ref P1);
            Rct = (TTfeRectShape)(GetWorkShape(2));
            Rct.GetTailPoint(1, ref P2);

            tmp_x = P1.X;
            if (tmp_x < P2.X)
            {
                tmp_x = P2.X;
            }
            tmp_x = tmp_x + 3 * F_Step;

            F_LastLineId++;
            //3
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = P1.X;
            Line.yStart = P1.Y;
            Line.xEnd   = tmp_x;
            Line.yEnd   = Lnb.yEnd;
            AddLine(Line);

            F_LastLineId++;
            //4
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = P2.X;
            Line.yStart = P2.Y;
            Line.xEnd   = tmp_x;
            Line.yEnd   = Lnb.yEnd;
            AddLine(Line);

            Rhomb.GetTailPoint(3, ref P1);
            Rct.GetTailPoint(0, ref P2);
            F_LastLineId++;
            //5
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = P2.X;
            Line.yStart = P2.Y;
            Line.xEnd   = P1.X;
            Line.yEnd   = P1.Y;
            AddLine(Line);

            F_LastLineId++;
            //6
            Lnb             = (TArrowLine)(GetWorkLine(2));
            Line            = new TArrowLine(F_Step, F_LastLineId);
            Line.PointStart = Lnb.PointEnd;
            Line.xEnd       = Lnb.PointEnd.X + 2 * F_Step;
            Line.yEnd       = Lnb.PointEnd.Y;
            AddLine(Line);
        }
Esempio n. 6
0
        void CreateLines()
        {
            TArrowLine    Line, Lnb;
            Point         P1 = new Point(), P2 = new Point(), VP = new Point();
            int           tmp_x;
            TTfeRectShape Rct, Rct2;
            TTfeEllShape  Ell;

            FreeWorkLines();
            F_LastLineId = F_NumberLineId;

            Rct  = (TTfeRectShape)(GetWorkShape(0));
            Rct2 = (TTfeRectShape)(GetWorkShape(1));
            Ell  = (TTfeEllShape)(GetWorkShape(2));
            Rct2.GetTailPoint(0, ref P1);
            VP.X = P1.X - 4 * F_Step;
            VP.Y = P1.Y;

            F_LastLineId++;
            //1
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = StartPoint.X;
            Line.yStart = StartPoint.Y;
            Line.xEnd   = VP.X;
            Line.yEnd   = VP.Y;
            Line.Bend   = CalcBend(Line.xStart, Line.xEnd);
            AddLine(Line);
            Lnb = Line;


            Rct.GetTailPoint(0, ref P1);
            F_LastLineId++;
            //2
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = Lnb.xEnd;
            Line.yStart = Lnb.yEnd;
            Line.xEnd   = P1.X;
            Line.yEnd   = P1.Y;
            AddLine(Line);


            Rct.GetTailPoint(1, ref P1);
            Ell.GetTailPoint(1, ref P2);
            F_LastLineId++;
            //3
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = P1.X;
            Line.yStart = P1.Y;
            Line.xEnd   = P2.X;
            Line.yEnd   = P2.Y;
            Line.Bend   = 1;
            AddLine(Line);


            Rct2.GetTailPoint(0, ref P1);
            F_LastLineId++;
            //4
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = Lnb.xEnd;
            Line.yStart = Lnb.yEnd;
            Line.xEnd   = P1.X;
            Line.yEnd   = P1.Y;
            AddLine(Line);

            //5
            Rct2.GetTailPoint(1, ref P1);
            Ell.GetTailPoint(0, ref P2);

            F_LastLineId++;
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = P1.X;
            Line.yStart = P1.Y;
            Line.xEnd   = P2.X;
            Line.yEnd   = P2.Y;
            AddLine(Line);

            //6
            Ell.GetTailPoint(2, ref P1);
            F_LastLineId++;
            Line        = new TArrowLine(F_Step, F_LastLineId);
            Line.xStart = P1.X;
            Line.yStart = P1.Y;
            Line.xEnd   = P1.X + 2 * F_Step;
            Line.yEnd   = P1.Y;
            AddLine(Line);
        }
Esempio n. 7
0
 public void AddLine(TArrowLine L)
 {
     WorkLines.Add(L);
 }