示例#1
0
        static void ColorizeWord(int SomeIndex001, MyFunc.Quadrupla <int> HorizKoods001)
        {
            //Colorize LEFT PART
            Console.Write(MyFunc.GetString(SomeIndex001, HorizKoods001.Primis, HorizKoods001.Secundus, Global.Field));

            //Colorize CENTER PART
            Console.ForegroundColor = ConsoleColor.DarkRed;
            Console.Write(MyFunc.GetString(SomeIndex001, HorizKoods001.Secundus, HorizKoods001.Tertium, Global.Field));
            Console.ResetColor();

            //Colorize RIGHT PART
            string Str001 = MyFunc.GetString(SomeIndex001, HorizKoods001.Tertium, HorizKoods001.Quartus, Global.Field);

            Console.Write(Str001);

            //Move To The Next Line
            Console.WriteLine();
        }
示例#2
0
        static public void AddTextPainterKoords(int VertIndex001, int VertKoordField, MyFunc.Quadrupla <int> TextHorizontalKoords001)
        {
            //Проверяем на совпадение и если оно есть, то удаляем
            for (int i = 0; i < TextIndexes.Count; ++i)
            {
                if (TextIndexes[i] == VertIndex001)
                {
                    TextIndexes.RemoveAt(i);
                    Sort();
                    return;
                }
            }

            TextIndexes.Add(VertIndex001);
            TextVertKoord        = VertKoordField;
            TextHorizontalKoords = TextHorizontalKoords001;

            Sort();
        }
示例#3
0
        public void Init(int Top001, int FieldKoordSecundus, int FieldHeigth, int ListLength)
        {
            VertIndex.SetMinMax(Top001, ListLength - 1);
            VertIndex.Set(0);
            if (VertIndex.GetMax() <= FieldHeigth)
            {
                VisIndex.SetMinMax(FieldKoordSecundus, FieldKoordSecundus + VertIndex.GetMax());

                BorderUp.SetMinMax(0, 0);
                BorderDown.SetMinMax(ListLength, ListLength);
            }
            else
            {
                VisIndex.SetMinMax(FieldKoordSecundus, FieldKoordSecundus + FieldHeigth - 1);

                BorderUp.SetMinMax(Top001, ListLength - FieldHeigth);
                BorderDown.SetMinMax(FieldHeigth, ListLength);
            }
            VisIndex.Set(0);

            BorderUp.Set(0);
            BorderDown.Set(0);

            VertStep = FieldHeigth / 2;

            if (IsUp && LastIndexes.Any())
            //if (IsUp)
            {
                MyFunc.Quadrupla <int> Tempo = LastIndexes.Last();

                VertIndex.Set(Tempo.Primis);
                VisIndex.Set(Tempo.Secundus);

                BorderUp.Set(Tempo.Tertium);
                BorderDown.Set(Tempo.Quartus);

                LastIndexes.RemoveAt(LastIndexes.Count - 1);
                IsUp = false;
            }
        }
示例#4
0
        public void PrepareDirectory()
        {
            /*
             * try
             * {
             *  GetEntariesDir(ref DirEntare, MaWalker.GetPath());
             *  CurrentPath = NewPath;
             * }
             * catch (UnauthorizedAccessException)
             * {
             *  Nintus.NewName("Access Denied");
             *  //MyFunc.CopyStringToArray(0, "Access Denied", Nintus.SomeArray);
             *  //Nintus.SomeString = "Access Denied";
             *  //MyFunc.Copy(ref Nintus.Koords, Nintus.SomeArray, Global.Field, true);
             *  //MyFunc.CopyStringToArray(ref Nintus.Koords, Nintus.SomeString, Global.Field, true);
             *
             *  //Console.WriteLine("Access Denied");
             * }*/

            GetEntariesDir(ref DirEntare, MaWalker.GetPath());
            LabelCurrentPath.NewName(MaWalker.GetPath());

            MainMarker.Init(0, AncPoints[1].Secundus, ContentSizes.Secundus, DirEntare.Count);

            /*
             * MainMarker.Reset();
             *
             * MainMarker.SetVerticalLImites(0, 0, Placer.Field.GetLength(0), DirEntare.Count);
             * MainMarker.SetHorizontalLimites(0, Placer.Koords.Primis, Placer.Koords.Primis + Placer.Field.GetLength(1), Global.Sizes.Primis);
             * MainMarker.SetGlobalKoords(Placer.Koords.Primis, Placer.Koords.Secundus);*/



            VertIndex.SetMinMax(0, DirEntare.Count - 1);
            VertIndex.Set(0);
            if (VertIndex.GetMax() <= ContentSizes.Secundus)
            {
                VisIndex.SetMinMax(AncPoints[1].Secundus, AncPoints[1].Secundus + VertIndex.GetMax());

                BorderUp.SetMinMax(0, 0);
                BorderDown.SetMinMax(DirEntare.Count, DirEntare.Count);
            }
            else
            {
                VisIndex.SetMinMax(AncPoints[1].Secundus, AncPoints[1].Secundus + ContentSizes.Secundus - 1);

                BorderUp.SetMinMax(0, DirEntare.Count - ContentSizes.Secundus);
                BorderDown.SetMinMax(ContentSizes.Secundus, DirEntare.Count);
            }
            VisIndex.Set(0);

            BorderUp.Set(0);
            BorderDown.Set(0);

            if (IsUp && LastIndexes.Any())
            {
                MyFunc.Quadrupla <int> Tempo = LastIndexes.Last();

                VertIndex.Set(Tempo.Primis);
                VisIndex.Set(Tempo.Secundus);

                BorderUp.Set(Tempo.Primis);
                BorderDown.Set(Tempo.Secundus);

                LastIndexes.RemoveAt(LastIndexes.Count - 1);

                /*
                 * VertIndex.Set(LastIndex.Primis);
                 * VisIndex.Set(LastIndex.Secundus);
                 *
                 * BorderUp.Set(LastBorders.Primis);
                 * BorderDown.Set(LastBorders.Secundus);
                 */
                IsUp = false;
            }

            //VisibleContent.NewContent(ref DirEntare, MainMarker.GetMin(), MainMarker.GetMax());
            //VisibleContent.NewContent(ref DirEntare, BorderUp.Get(), BorderDown.Get());
        }
示例#5
0
 static public void AddMarkPainterKoords(int VertIndex001, MyFunc.Quadrupla <int> HorizKoords001)
 {
     MarkIndexes.Add(VertIndex001);
     PaintBackGrHorizKoords = HorizKoords001;
 }