示例#1
0
        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);

            Alt.GUI.Temporary.Gwen.Control.NumericUpDown ctrl = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(this);
            ctrl.SetBounds(10, 10, 50, 20);
            ctrl.Value         = 50;
            ctrl.Max           = 100;
            ctrl.Min           = -100;
            ctrl.ValueChanged += OnValueChanged;
        }
示例#2
0
        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);


            //  GUI
            {
                m_TopLabel = new Alt.GUI.Temporary.Gwen.Control.Label(this);
                m_TopLabel.AutoSizeToContents = true;
                m_TopLabel.Text      = "Left click the image to draw passages (white), right click the image to draw walls (black).";
                m_TopLabel.Dock      = Pos.Top;
                m_TopLabel.TextColor = Color.Yellow;
                m_TopLabel.Margin    = new Margin(0, 5, 0, 5);


                m_ControlsPanel       = new Alt.GUI.Temporary.Gwen.Control.Base(this);
                m_ControlsPanel.Width = 139;
                m_ControlsPanel.Dock  = Pos.Right;


                pbTerrain              = new Alt.GUI.Temporary.Gwen.Control.PictureBox(this);
                pbTerrain.Dock         = Pos.Fill;
                pbTerrain.ErrorImage   = null;
                pbTerrain.Image        = Bitmap.FromFile("AltData/AForge/FuzzyAGV_BG.gif");
                pbTerrain.InitialImage = null;
                pbTerrain.SizeMode     = PictureBoxSizeMode.Normal;            // AutoSize;
                pbTerrain.MouseMove   += new GUI.MouseEventHandler(pbTerrain_MouseMove);
                pbTerrain.MouseDown   += new GUI.MouseEventHandler(pbTerrain_MouseDown);


                int groupBox_dy = -10;
                groupBox1 = new Alt.GUI.Temporary.Gwen.Control.GroupBox(m_ControlsPanel);
                {
                    groupBox1.Location = new PointI(0, 0);
                    groupBox1.Name     = "groupBox1";
                    groupBox1.Size     = new SizeI(139, 83);
                    groupBox1.Text     = "Sensor readings:";


                    lbl    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox1);
                    label2 = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox1);
                    label1 = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox1);

                    lbl.Location           = new PointI(0, 54 + groupBox_dy);
                    lbl.AutoSizeToContents = true;
                    lbl.Text = "Right (pixels):";

                    label2.Location           = new PointI(0, 35 + groupBox_dy);
                    label2.AutoSizeToContents = true;
                    label2.Text = "Left (pixels):";

                    label1.Location           = new PointI(0, 16 + groupBox_dy);
                    label1.AutoSizeToContents = true;
                    label1.Text = "Frontal (pixels):";


                    txtRight = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox1);
                    txtLeft  = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox1);
                    txtFront = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox1);

                    txtRight.Location           = new PointI(100, 54 + groupBox_dy);
                    txtRight.AutoSizeToContents = true;
                    txtRight.Text      = "0";
                    txtRight.TextAlign = ContentAlignment.MiddleLeft;

                    txtLeft.Location           = new PointI(100, 35 + groupBox_dy);
                    txtLeft.AutoSizeToContents = true;
                    txtLeft.Text      = "0";
                    txtLeft.TextAlign = ContentAlignment.MiddleLeft;

                    txtFront.Location           = new PointI(100, 16 + groupBox_dy);
                    txtFront.AutoSizeToContents = true;
                    txtFront.Text      = "0";
                    txtFront.TextAlign = ContentAlignment.MiddleLeft;
                }

                groupBox2 = new Alt.GUI.Temporary.Gwen.Control.GroupBox(m_ControlsPanel);
                {
                    groupBox2.Location = new PointI(0, 94);
                    groupBox2.Size     = new SizeI(139, 45);
                    groupBox2.Text     = "Output:";


                    label3   = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox2);
                    txtAngle = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox2);

                    label3.Location           = new PointI(0, 16 + groupBox_dy);
                    label3.AutoSizeToContents = true;
                    label3.Text = "Angle (degrees):";

                    txtAngle.Location           = new PointI(98, 16 + groupBox_dy);
                    txtAngle.AutoSizeToContents = true;
                    txtAngle.Text      = "0,00";
                    txtAngle.TextAlign = ContentAlignment.MiddleLeft;
                }

                gbComandos = new Alt.GUI.Temporary.Gwen.Control.GroupBox(m_ControlsPanel);
                {
                    gbComandos.Location = new PointI(0, 150);
                    gbComandos.Size     = new SizeI(139, 205);
                    gbComandos.Text     = "Tools:";


                    btnStep     = new Alt.GUI.Temporary.Gwen.Control.Button(gbComandos);
                    btnRun      = new Alt.GUI.Temporary.Gwen.Control.Button(gbComandos);
                    txtInterval = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(gbComandos);
                    cbLasers    = new Alt.GUI.Temporary.Gwen.Control.LabeledCheckBox(gbComandos);

                    cbTrajeto = new Alt.GUI.Temporary.Gwen.Control.LabeledCheckBox(gbComandos);
                    btnReset  = new Alt.GUI.Temporary.Gwen.Control.Button(gbComandos);
                    label4    = new Alt.GUI.Temporary.Gwen.Control.Label(gbComandos);

                    btnStep.Location        = new PointI(0, 109 + groupBox_dy);
                    btnStep.Size            = new SizeI(128, 23);
                    btnStep.Text            = "One Step";
                    btnStep.Click          += new System.EventHandler(button3_Click);
                    btnStep.NormalTextColor = Color.Blue;

                    btnRun.Location        = new PointI(0, 138 + groupBox_dy);
                    btnRun.Size            = new SizeI(128, 23);
                    btnRun.Text            = "Run";
                    btnRun.Click          += new System.EventHandler(btnRun_Click);
                    btnRun.NormalTextColor = Color.Green;

                    txtInterval.Location = new PointI(0, 83 + groupBox_dy);
                    txtInterval.Size     = new SizeI(127, 20);
                    txtInterval.Min      = 1;
                    txtInterval.Max      = 100;
                    txtInterval.Value    = 20;

                    cbLasers.IsChecked = true;
                    cbLasers.Location  = new PointI(0, 40 + groupBox_dy);
                    cbLasers.Text      = "Show Beams";

                    cbTrajeto.Location = new PointI(0, 16 + groupBox_dy);
                    cbTrajeto.Text     = "Track Path";

                    btnReset.Location        = new PointI(0, 167 + groupBox_dy);
                    btnReset.Size            = new SizeI(128, 23);
                    btnReset.Text            = "Restart";
                    btnReset.Click          += new System.EventHandler(btnReset_Click);
                    btnReset.NormalTextColor = Color.Red * 0.8;

                    label4.Location           = new PointI(0, 65 + groupBox_dy);
                    label4.AutoSizeToContents = true;
                    label4.Text = "Move Interval (ms):";
                }


                Bitmap robot = new Bitmap(10, 10);
                using (Graphics graphics = Graphics.FromImage(robot))
                {
                    graphics.FillCircle(Brushes.Blue, robot.PixelRectangle);
                }
                pbRobot       = new Alt.GUI.Temporary.Gwen.Control.PictureBox(pbTerrain);
                pbRobot.Image = robot;
                pbRobot.Size  = robot.PixelSize;
            }


            Angle       = 0;
            OriginalMap = new Bitmap(pbTerrain.Image);
            InitialMap  = new Bitmap(pbTerrain.Image);

            InitFuzzyEngine();
            FirstInference = true;
            pbRobot.Top    = InitialMap.PixelHeight - 55;
            pbRobot.Left   = 60;
            InitialPos     = pbRobot.Location;
            RunLabel       = btnRun.Text;
        }
示例#3
0
        public Example_Clipper(Base parent)
            : base(parent)
        {
            this.Margin = new Margin(0);


            //  Top Label
            m_TopLabel = new Alt.GUI.Temporary.Gwen.Control.Label(this);
            m_TopLabel.AutoSizeToContents = true;
            m_TopLabel.Text      = "Clipper Demo. Use the mouse-wheel (or +, -, 0) to adjust the offset of the solution polygons.";
            m_TopLabel.TextColor = Color.Yellow;
            m_TopLabel.Dock      = Pos.Top;
            m_TopLabel.Margin    = new Margin(0, 5, 0, 5);



            m_Splitter      = new VerticalSplitter(this);
            m_Splitter.Dock = Alt.GUI.Temporary.Gwen.Pos.Fill;


            //  UI Panel
            m_RightPanel      = new Base(m_Splitter);
            m_RightPanel.Dock = Pos.Fill;


            //  Geometry
            groupBox_Geometry        = new RadioButtonGroup(m_RightPanel, string.Empty);
            groupBox_Geometry.Text   = "Geometry:";
            groupBox_Geometry.Dock   = Pos.Top;
            groupBox_Geometry.Margin = new Margin(0,
#if WINDOWS_PHONE_7 || WINDOWS_PHONE_71
                                                  5,
#else
                                                  GUI.Config.Logo.PixelHeight,
#endif
                                                  5, 0);

            rbGeometry1        = groupBox_Geometry.AddOption("Triangles");
            rbGeometry1.Margin = new Margin(0, 5, 0, 0);
            rbGeometry2        = groupBox_Geometry.AddOption("Geo - Circles");

            rbGeometry2.Select();

            groupBox_Geometry.SelectionChanged += new GwenEventHandler(groupBox_Geometry_SelectionChanged);


            //  Boolean Op
            groupBox_BooleanOperation        = new RadioButtonGroup(m_RightPanel, string.Empty);
            groupBox_BooleanOperation.Text   = "Boolean Operation:";
            groupBox_BooleanOperation.Dock   = Pos.Top;
            groupBox_BooleanOperation.Margin = new Margin(0, 15, 5, 0);

            rbIntersect        = groupBox_BooleanOperation.AddOption("Intersect");
            rbIntersect.Margin = new Margin(0, 5, 0, 0);
            rbUnion            = groupBox_BooleanOperation.AddOption("Union");
            rbDifference       = groupBox_BooleanOperation.AddOption("Difference");
            //NoNeed	rbXor =
            groupBox_BooleanOperation.AddOption("XOR");
            rbNone        = groupBox_BooleanOperation.AddOption("None");
            rbNone.Margin = new Margin(0, 0, 0, 7);

            rbIntersect.Select();

            groupBox_BooleanOperation.SelectionChanged += new GwenEventHandler(RefreshWORecreating);


            //  Options
            groupBox_Options      = new Alt.GUI.Temporary.Gwen.Control.RadioButtonGroup(m_RightPanel, string.Empty);
            groupBox_Options.Text = "Options:";
            groupBox_Options.Dock = Pos.Top;
            groupBox_Options.AutoSizeToContents = true;
            groupBox_Options.Margin             = new Margin(0, 15, 5, 0);

            rbEvenOdd        = groupBox_Options.AddOption("EvenOdd");
            rbEvenOdd.Margin = new Margin(0, 5, 0, 0);
            rbNonZero        = groupBox_Options.AddOption("NonZero");

            rbNonZero.Select();

            groupBox_Options.SelectionChanged += new GwenEventHandler(RefreshWORecreating);

            //  Vertex Count
            lblCount = new Alt.GUI.Temporary.Gwen.Control.Label(m_RightPanel);            //groupBox_Options);
            lblCount.AutoSizeToContents = true;
            lblCount.Text   = "Vertex Count:";
            lblCount.Dock   = Pos.Top;
            lblCount.Margin = new Margin(0, 17, 5, 7);
            //groupBox_Options.AddChild(lblCount);

            nudCount         = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(m_RightPanel);    //groupBox_Options);
            nudCount.Dock    = Pos.Top;
            nudCount.Minimum = 3;
            nudCount.Maximum = 100;
            nudCount.Value   = 50;
            nudCount.Margin  = new Margin(0, 0, 5, 7);
            //groupBox_Options.AddChild(nudCount);

            nudCount.ValueChanged += new GwenEventHandler(nudCount_ValueChanged);

            //  Offset
            Alt.GUI.Temporary.Gwen.Control.Label label = new Alt.GUI.Temporary.Gwen.Control.Label(m_RightPanel);            //groupBox_Options);
            label.AutoSizeToContents = true;
            label.Text   = "Offset:";
            label.Dock   = Pos.Top;
            label.Margin = new Margin(0, 0, 5, 7);
            //groupBox_Options.AddChild(label);

            nudOffset               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(m_RightPanel);//groupBox_Options);
            nudOffset.Dock          = Pos.Top;
            nudOffset.Minimum       = -10;
            nudOffset.Maximum       = 10;
            nudOffset.Value         = 0;
            nudOffset.DecimalPlaces =
#if WINDOWS_PHONE_7 || WINDOWS_PHONE_71
                0;
#else
                1;
#endif
            nudOffset.Margin = new Margin(0, 0, 5, 7);
            //groupBox_Options.AddChild(nudOffset);

            nudOffset.ValueChanged += new GwenEventHandler(RefreshWORecreating);
        }
        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);


            //  GUI
            {
                m_TopPanel = new Base(this);
                {
                    m_TopPanel.Dock   = Pos.Top;
                    m_TopPanel.Height = 30;

                    Alt.GUI.Temporary.Gwen.Control.Label label = new Alt.GUI.Temporary.Gwen.Control.Label(m_TopPanel);
                    label.Location           = new PointI(0, 2);
                    label.AutoSizeToContents = true;
                    label.TextColor          = Color.LightGreen;
                    label.Text = "Map";


                    label1            = new Alt.GUI.Temporary.Gwen.Control.Label(m_TopPanel);
                    citiesCountBox    = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(m_TopPanel);
                    generateMapButton = new Alt.GUI.Temporary.Gwen.Control.Button(m_TopPanel);

                    label1.Location           = new PointI(33, 2);
                    label1.Text               = "Cities:";
                    label1.AutoSizeToContents = true;

                    citiesCountBox.Location  = new PointI(75, 1);
                    citiesCountBox.Width     = 50;
                    citiesCountBox.Min       = 5;
                    citiesCountBox.Max       = 50;
                    citiesCountBox.Increment = 10;

                    generateMapButton.Location           = new PointI(135, 0);
                    generateMapButton.Text               = "Generate";
                    generateMapButton.AutoSizeToContents = true;
                    generateMapButton.Click             += new System.EventHandler(generateMapButton_Click);
                    generateMapButton.NormalTextColor    = Color.Blue;
                }


                m_RightPanel = new Alt.GUI.Temporary.Gwen.Control.Base(this);
                {
                    m_RightPanel.Dock   = Pos.Right;
                    m_RightPanel.Width  = 140;
                    m_RightPanel.Margin = new Margin(5, 0, 0, 0);

                    groupBox2 = new Alt.GUI.Temporary.Gwen.Control.GroupBox(m_RightPanel);
                    {
                        groupBox2.Location = new PointI(0, 0);
                        groupBox2.Size     = new SizeI(140, 273);
                        groupBox2.Text     = "Neural Network";


                        Alt.GUI.Temporary.Gwen.Control.Label label = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox2);
                        label.Location           = new PointI(0, 10);
                        label.AutoSizeToContents = true;
                        label.Text = "Neurons:";

                        neuronsBox          = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox2);
                        neuronsBox.Location = new PointI(0, 30);
                        neuronsBox.Width    = 130;


                        label                    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox2);
                        label.Location           = new PointI(0, 65);
                        label.AutoSizeToContents = true;
                        label.Text               = "Iteraions:";

                        iterationsBox          = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox2);
                        iterationsBox.Location = new PointI(0, 85);
                        iterationsBox.Width    = 130;

                        label                    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox2);
                        label.Location           = new PointI(0, 110);
                        label.AutoSizeToContents = true;
                        label.Text               = "Initial learning rate:";

                        rateBox          = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox2);
                        rateBox.Location = new PointI(0, 130);
                        rateBox.Width    = 130;

                        label                    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox2);
                        label.Location           = new PointI(0, 155);
                        label.AutoSizeToContents = true;
                        label.Text               = "Learning radius:";

                        radiusBox          = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox2);
                        radiusBox.Location = new PointI(0, 175);
                        radiusBox.Width    = 130;


                        label                    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox2);
                        label.Location           = new PointI(0, 210);
                        label.AutoSizeToContents = true;
                        label.Text               = "Current iteration:";

                        currentIterationBox          = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox2);
                        currentIterationBox.Location = new PointI(0, 230);
                        currentIterationBox.Width    = 130;
                        currentIterationBox.ReadOnly = true;
                    }


                    startButton = new Alt.GUI.Temporary.Gwen.Control.Button(m_RightPanel);
                    stopButton  = new Alt.GUI.Temporary.Gwen.Control.Button(m_RightPanel);

                    startButton.Location        = new PointI(5, 300);
                    startButton.Width           = 130;
                    startButton.Text            = "Start";
                    startButton.Click          += new System.EventHandler(startButton_Click);
                    startButton.NormalTextColor = Color.Green;

                    stopButton.Enabled         = false;
                    stopButton.Location        = new PointI(5, 325);
                    stopButton.Width           = 130;
                    stopButton.Text            = "Stop";
                    stopButton.Click          += new System.EventHandler(stopButton_Click);
                    stopButton.NormalTextColor = Color.Red * 0.8;
                }


                chart      = new Chart(this);
                chart.Dock = Pos.Fill;
            }


            // initialize chart
            chart.AddDataSeries("cities", Color.Red, Chart.SeriesType.Dots, 5, false);
            chart.AddDataSeries("path", Color.Blue, Chart.SeriesType.Line, 1, false);
            chart.RangeX = new Range(0, 1000);
            chart.RangeY = new Range(0, 1000);

            //
            UpdateSettings();
            GenerateMap();
        }
        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);


            Alt.GUI.Temporary.Gwen.Control.Label label;
#if SILVERLIGHT || UNITY_WEBPLAYER
            label = new Alt.GUI.Temporary.Gwen.Control.Label(this);
            label.AutoSizeToContents = true;
            label.Text = //Description + "\n" + "(This example is not available in this Demo, please download SDK)";
                         "THIS EXAMPLE IS NOT AVAILABLE IN THIS DEMO,\nPLEASE DOWNLOAD AltGUI SDK";
            label.TextColor = Color.Orange * 1.2;
            label.Dock      = Pos.Top;
            label.Margin    = new Margin(0, 0, 0, 5);
            label.Font      = Example_NotAvailable_ScreenShot.Font;
#endif


            //  GUI
            {
                m_TopPanel = new Base(this);
                {
                    m_TopPanel.Dock   = Pos.Top;
                    m_TopPanel.Height = 30;

                    label                    = new Alt.GUI.Temporary.Gwen.Control.Label(m_TopPanel);
                    label.Location           = new PointI(0, 2);
                    label.AutoSizeToContents = true;
                    label.TextColor          = Color.LightGreen;
                    label.Text               = "Map";


                    label1            = new Alt.GUI.Temporary.Gwen.Control.Label(m_TopPanel);
                    citiesCountBox    = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(m_TopPanel);
                    generateMapButton = new Alt.GUI.Temporary.Gwen.Control.Button(m_TopPanel);

                    label1.Location           = new PointI(33, 2);
                    label1.Text               = "Cities:";
                    label1.AutoSizeToContents = true;

                    citiesCountBox.Location  = new PointI(75, 1);
                    citiesCountBox.Width     = 50;
                    citiesCountBox.Min       = 5;
                    citiesCountBox.Max       = 50;
                    citiesCountBox.Increment = 10;

                    generateMapButton.Location           = new PointI(135, 0);
                    generateMapButton.Text               = "Generate";
                    generateMapButton.AutoSizeToContents = true;
                    generateMapButton.Click             += new System.EventHandler(generateMapButton_Click);
                    generateMapButton.NormalTextColor    = Color.Blue;
                }


                m_RightPanel = new Base(this);
                {
                    m_RightPanel.Dock   = Pos.Right;
                    m_RightPanel.Width  = 140;
                    m_RightPanel.Margin = new Margin(5, 0, 0, 0);

                    groupBox2 = new Alt.GUI.Temporary.Gwen.Control.GroupBox(m_RightPanel);
                    {
                        groupBox2.Location = new PointI(0, 0);
                        groupBox2.Size     = new SizeI(140, 223);
                        groupBox2.Text     = "Settings";

                        greedyCrossoverBox = new Alt.GUI.Temporary.Gwen.Control.LabeledCheckBox(groupBox2);
                        label5             = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox2);
                        iterationsBox      = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox2);
                        label4             = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox2);
                        selectionBox       = new Alt.GUI.Temporary.Gwen.Control.ComboBox(groupBox2);
                        label3             = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox2);
                        populationSizeBox  = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox2);
                        label2             = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox2);


                        label2.Location           = new PointI(0, 10);
                        label2.AutoSizeToContents = true;
                        label2.Text = "Population size:";

                        populationSizeBox.Location  = new PointI(0, 30);
                        populationSizeBox.Width     = 130;
                        populationSizeBox.Min       = 10;
                        populationSizeBox.Max       = 100;
                        populationSizeBox.Increment = 10;


                        label3.Location           = new PointI(0, 60);
                        label3.AutoSizeToContents = true;
                        label3.Text = "Selection method:";

                        selectionBox.AddItem("Elite").UserData    = 0;
                        selectionBox.AddItem("Rank").UserData     = 1;
                        selectionBox.AddItem("Roulette").UserData = 2;
                        selectionBox.Location = new PointI(0, 80);
                        selectionBox.Width    = 130;


                        greedyCrossoverBox.Location = new PointI(0, 115);
                        greedyCrossoverBox.Text     = "Greedy crossover";


                        label4.Location = new PointI(0, 145);
                        label4.Size     = new SizeI(60, 16);
                        label4.Text     = "Iterations:";

                        iterationsBox.Location  = new PointI(0, 165);
                        iterationsBox.Width     = 130;
                        iterationsBox.Min       = 0;
                        iterationsBox.Max       = 100000;
                        iterationsBox.Increment = 100;

                        label5.Location           = new PointI(0, 185);
                        label5.AutoSizeToContents = true;
                        label5.Text = "( 0 - inifinity )";
                    }


                    groupBox3 = new Alt.GUI.Temporary.Gwen.Control.GroupBox(m_RightPanel);
                    {
                        groupBox3.Location = new PointI(0, 230);
                        groupBox3.Size     = new SizeI(140, 122);
                        groupBox3.Text     = "Current iteration";

                        pathLengthBox       = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox3);
                        label7              = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox3);
                        currentIterationBox = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox3);
                        label6              = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox3);


                        label6.Location           = new PointI(0, 10);
                        label6.AutoSizeToContents = true;
                        label6.Text = "Iteration:";

                        currentIterationBox.Location = new PointI(0, 30);
                        currentIterationBox.ReadOnly = true;
                        currentIterationBox.Width    = 130;
                        currentIterationBox.Text     = "";


                        label7.Location           = new PointI(0, 60);
                        label7.AutoSizeToContents = true;
                        label7.Text = "Path length:";

                        pathLengthBox.Location = new PointI(0, 80);
                        pathLengthBox.ReadOnly = true;
                        pathLengthBox.Width    = 130;
                        pathLengthBox.Text     = "";
                    }


                    startButton = new Alt.GUI.Temporary.Gwen.Control.Button(m_RightPanel);
                    stopButton  = new Alt.GUI.Temporary.Gwen.Control.Button(m_RightPanel);

                    startButton.Location        = new PointI(5, 370);
                    startButton.Width           = 130;
                    startButton.Text            = "Start";
                    startButton.Click          += new System.EventHandler(startButton_Click);
                    startButton.NormalTextColor = Color.Green;

                    stopButton.Enabled         = false;
                    stopButton.Location        = new PointI(5, 395);
                    stopButton.Width           = 130;
                    stopButton.Text            = "Stop";
                    stopButton.Click          += new System.EventHandler(stopButton_Click);
                    stopButton.NormalTextColor = Color.Red * 0.8;
                }


                mapControl      = new Chart(this);
                mapControl.Dock = Pos.Fill;
            }


            // set up map control
            mapControl.RangeX = new Range(0, 1000);
            mapControl.RangeY = new Range(0, 1000);
            mapControl.AddDataSeries("map", Color.Red, Chart.SeriesType.Dots, 5, false);
            mapControl.AddDataSeries("path", Color.Blue, Chart.SeriesType.Line, 1, false);


            //
            greedyCrossoverBox.IsChecked = greedyCrossover;
            UpdateSettings();
            GenerateMap();
        }
示例#6
0
        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);


            m_panelDrawing = new PieChartControl(this);
            //m_panelDrawing.DoubleBuffered = false;
            m_panelDrawing.Dock            = Pos.Fill;
            m_panelDrawing.ClientBackColor = Color.FromArgb(0, 128, 128, 128);// Color.Transparent;// WhiteSmoke;
            m_panelDrawing.TextColor       = Color.Black;
            //m_panelDrawing.DrawBorder = true;
            //m_panelDrawing.BorderColor = Color.DodgerBlue;
            m_panelDrawing.Margin   = new Margin(8, 8, 8, 8);
            m_panelDrawing.ToolTips = null;


            groupBox6          = new Alt.GUI.Temporary.Gwen.Control.GroupBox(m_ControlsPanel);
            groupBox6.Location = new PointI(8, 8);
            groupBox6.Size     = new SizeI(320, 248);
            groupBox6.Text     = "Pie slices";

            int inGroupBoxOffset   = -12;
            int numericUpDownWidth = 45;

            Alt.GUI.Temporary.Gwen.Control.Label label = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox6);
            label.Location           = new PointI(32, 20 + inGroupBoxOffset);
            label.Text               = "Value";
            label.TextAlign          = ContentAlignment.MiddleLeft;
            label.AutoSizeToContents = true;

            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox6);
            label.Location           = new PointI(80, 20 + inGroupBoxOffset);
            label.Text               = "Offset";
            label.TextAlign          = ContentAlignment.MiddleLeft;
            label.AutoSizeToContents = true;

            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox6);
            label.Location           = new PointI(128, 20 + inGroupBoxOffset);
            label.Text               = "Color";
            label.TextAlign          = ContentAlignment.MiddleCenter;
            label.AutoSizeToContents = true;

            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox6);
            label.Location           = new PointI(168, 20 + inGroupBoxOffset);
            label.Text               = "Text";
            label.TextAlign          = ContentAlignment.MiddleLeft;
            label.AutoSizeToContents = true;

            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox6);
            label.Location           = new PointI(248, 20 + inGroupBoxOffset);
            label.Text               = "ToolTip";
            label.TextAlign          = ContentAlignment.MiddleLeft;
            label.AutoSizeToContents = true;



            int checkBoxOffset = 4;

            checkBox1                 = new Alt.GUI.Temporary.Gwen.Control.CheckBox(groupBox6);
            checkBox1.IsChecked       = true;
            checkBox1.Location        = new PointI(8, 38 + inGroupBoxOffset + checkBoxOffset);
            checkBox1.CheckedChanged += new System.EventHandler(checkBox1_CheckedChanged);

            checkBox2                 = new Alt.GUI.Temporary.Gwen.Control.CheckBox(groupBox6);
            checkBox2.IsChecked       = true;
            checkBox2.Location        = new PointI(8, 73 + inGroupBoxOffset + checkBoxOffset);
            checkBox2.CheckedChanged += new System.EventHandler(checkBox2_CheckedChanged);

            checkBox3                 = new Alt.GUI.Temporary.Gwen.Control.CheckBox(groupBox6);
            checkBox3.IsChecked       = true;
            checkBox3.Location        = new PointI(8, 108 + inGroupBoxOffset + checkBoxOffset);
            checkBox3.CheckedChanged += new System.EventHandler(checkBox3_CheckedChanged);

            checkBox4                 = new Alt.GUI.Temporary.Gwen.Control.CheckBox(groupBox6);
            checkBox4.IsChecked       = true;
            checkBox4.Location        = new PointI(8, 143 + inGroupBoxOffset + checkBoxOffset);
            checkBox4.CheckedChanged += new System.EventHandler(checkBox4_CheckedChanged);

            checkBox5                 = new Alt.GUI.Temporary.Gwen.Control.CheckBox(groupBox6);
            checkBox5.IsChecked       = true;
            checkBox5.Location        = new PointI(8, 178 + inGroupBoxOffset + checkBoxOffset);
            checkBox5.CheckedChanged += new System.EventHandler(checkBox5_CheckedChanged);

            checkBox6                 = new Alt.GUI.Temporary.Gwen.Control.CheckBox(groupBox6);
            checkBox6.IsChecked       = true;
            checkBox6.Location        = new PointI(8, 213 + inGroupBoxOffset + checkBoxOffset);
            checkBox6.CheckedChanged += new System.EventHandler(checkBox6_CheckedChanged);


            numericUpDownValue1               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox6);
            numericUpDownValue1.Width         = numericUpDownWidth;
            numericUpDownValue1.Location      = new PointI(32, 40 + inGroupBoxOffset);
            numericUpDownValue1.Value         = 10;
            numericUpDownValue1.ValueChanged += new GwenEventHandler(numericUpDownValue_ValueChanged);

            numericUpDownValue2               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox6);
            numericUpDownValue2.Width         = numericUpDownWidth;
            numericUpDownValue2.Location      = new PointI(32, 75 + inGroupBoxOffset);
            numericUpDownValue2.Value         = 15;
            numericUpDownValue2.ValueChanged += new GwenEventHandler(numericUpDownValue_ValueChanged);

            numericUpDownValue3               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox6);
            numericUpDownValue3.Width         = numericUpDownWidth;
            numericUpDownValue3.Location      = new PointI(32, 110 + inGroupBoxOffset);
            numericUpDownValue3.Value         = 20;
            numericUpDownValue3.ValueChanged += new GwenEventHandler(numericUpDownValue_ValueChanged);

            numericUpDownValue4               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox6);
            numericUpDownValue4.Width         = numericUpDownWidth;
            numericUpDownValue4.Location      = new PointI(32, 145 + inGroupBoxOffset);
            numericUpDownValue4.Value         = 60;
            numericUpDownValue4.ValueChanged += new GwenEventHandler(numericUpDownValue_ValueChanged);

            numericUpDownValue5               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox6);
            numericUpDownValue5.Width         = numericUpDownWidth;
            numericUpDownValue5.Location      = new PointI(32, 180 + inGroupBoxOffset);
            numericUpDownValue5.Value         = 25;
            numericUpDownValue5.ValueChanged += new GwenEventHandler(numericUpDownValue_ValueChanged);

            numericUpDownValue6               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox6);
            numericUpDownValue6.Width         = numericUpDownWidth;
            numericUpDownValue6.Location      = new PointI(32, 215 + inGroupBoxOffset);
            numericUpDownValue6.Value         = 25;
            numericUpDownValue6.ValueChanged += new GwenEventHandler(numericUpDownValue_ValueChanged);


            numericUpDownDisplacement1               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox6);
            numericUpDownDisplacement1.Width         = numericUpDownWidth;
            numericUpDownDisplacement1.DecimalPlaces = 2;
            numericUpDownDisplacement1.Increment     = 0.05f;
            numericUpDownDisplacement1.Location      = new PointI(80, 40 + inGroupBoxOffset);
            numericUpDownDisplacement1.Maximum       = 1;
            numericUpDownDisplacement1.Minimum       = 0;
            numericUpDownDisplacement1.Value         = 0.2f;
            numericUpDownDisplacement1.ValueChanged += new GwenEventHandler(numericUpDownDisplacement_ValueChanged);

            numericUpDownDisplacement2               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox6);
            numericUpDownDisplacement2.Width         = numericUpDownWidth;
            numericUpDownDisplacement2.DecimalPlaces = 2;
            numericUpDownDisplacement2.Increment     = 0.05f;
            numericUpDownDisplacement2.Location      = new PointI(80, 75 + inGroupBoxOffset);
            numericUpDownDisplacement2.Maximum       = 1;
            numericUpDownDisplacement2.Minimum       = 0;
            numericUpDownDisplacement2.Value         = 0.05f;
            numericUpDownDisplacement2.ValueChanged += new GwenEventHandler(numericUpDownDisplacement_ValueChanged);

            numericUpDownDisplacement3               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox6);
            numericUpDownDisplacement3.Width         = numericUpDownWidth;
            numericUpDownDisplacement3.DecimalPlaces = 2;
            numericUpDownDisplacement3.Increment     = 0.05f;
            numericUpDownDisplacement3.Location      = new PointI(80, 110 + inGroupBoxOffset);
            numericUpDownDisplacement3.Maximum       = 1;
            numericUpDownDisplacement3.Minimum       = 0;
            numericUpDownDisplacement3.Value         = 0.05f;
            numericUpDownDisplacement3.ValueChanged += new GwenEventHandler(numericUpDownDisplacement_ValueChanged);

            numericUpDownDisplacement4               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox6);
            numericUpDownDisplacement4.Width         = numericUpDownWidth;
            numericUpDownDisplacement4.DecimalPlaces = 2;
            numericUpDownDisplacement4.Increment     = 0.05f;
            numericUpDownDisplacement4.Location      = new PointI(80, 145 + inGroupBoxOffset);
            numericUpDownDisplacement4.Maximum       = 1;
            numericUpDownDisplacement4.Minimum       = 0;
            numericUpDownDisplacement4.Value         = 0.05f;
            numericUpDownDisplacement4.ValueChanged += new GwenEventHandler(numericUpDownDisplacement_ValueChanged);

            numericUpDownDisplacement5               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox6);
            numericUpDownDisplacement5.Width         = numericUpDownWidth;
            numericUpDownDisplacement5.DecimalPlaces = 2;
            numericUpDownDisplacement5.Increment     = 0.05f;
            numericUpDownDisplacement5.Location      = new PointI(80, 180 + inGroupBoxOffset);
            numericUpDownDisplacement5.Maximum       = 1;
            numericUpDownDisplacement5.Minimum       = 0;
            numericUpDownDisplacement5.Value         = 0.05f;
            numericUpDownDisplacement5.ValueChanged += new GwenEventHandler(numericUpDownDisplacement_ValueChanged);

            numericUpDownDisplacement6               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox6);
            numericUpDownDisplacement6.Width         = numericUpDownWidth;
            numericUpDownDisplacement6.DecimalPlaces = 2;
            numericUpDownDisplacement6.Increment     = 0.05f;
            numericUpDownDisplacement6.Location      = new PointI(80, 215 + inGroupBoxOffset);
            numericUpDownDisplacement6.Maximum       = 1;
            numericUpDownDisplacement6.Minimum       = 0;
            numericUpDownDisplacement6.Value         = 0.05f;
            numericUpDownDisplacement6.ValueChanged += new GwenEventHandler(numericUpDownDisplacement_ValueChanged);


            buttonColor1          = new ColorButton(groupBox6);
            buttonColor1.Color    = Color.Red;
            buttonColor1.Location = new PointI(136, 40 + inGroupBoxOffset);
            buttonColor1.Size     = new SizeI(20, 20);
            buttonColor1.Click   += new System.EventHandler(buttonColor1_Click);

            buttonColor2          = new ColorButton(groupBox6);
            buttonColor2.Color    = Color.LimeGreen;
            buttonColor2.Location = new PointI(136, 75 + inGroupBoxOffset);
            buttonColor2.Size     = new SizeI(20, 20);
            buttonColor2.Click   += new System.EventHandler(buttonColor2_Click);

            buttonColor3          = new ColorButton(groupBox6);
            buttonColor3.Color    = Color.Blue;
            buttonColor3.Location = new PointI(136, 110 + inGroupBoxOffset);
            buttonColor3.Size     = new SizeI(20, 20);
            buttonColor3.Click   += new System.EventHandler(buttonColor3_Click);

            buttonColor4          = new ColorButton(groupBox6);
            buttonColor4.Color    = Color.Yellow;
            buttonColor4.Location = new PointI(136, 145 + inGroupBoxOffset);
            buttonColor4.Size     = new SizeI(20, 20);
            buttonColor4.Click   += new System.EventHandler(buttonColor4_Click);

            buttonColor5          = new ColorButton(groupBox6);
            buttonColor5.Color    = Color.Firebrick;
            buttonColor5.Location = new PointI(136, 180 + inGroupBoxOffset);
            buttonColor5.Size     = new SizeI(20, 20);
            buttonColor5.Click   += new System.EventHandler(buttonColor5_Click);

            buttonColor6          = new ColorButton(groupBox6);
            buttonColor6.Color    = Color.DeepSkyBlue;
            buttonColor6.Location = new PointI(136, 215 + inGroupBoxOffset);
            buttonColor6.Size     = new SizeI(20, 20);
            buttonColor6.Click   += new System.EventHandler(buttonColor6_Click);


            textBoxText1              = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox6);
            textBoxText1.Location     = new PointI(168, 40 + inGroupBoxOffset);
            textBoxText1.Size         = new SizeI(72, 20);
            textBoxText1.Text         = "red";
            textBoxText1.TextChanged += new GwenEventHandler(textBoxText_TextChanged);

            textBoxText2              = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox6);
            textBoxText2.Location     = new PointI(168, 75 + inGroupBoxOffset);
            textBoxText2.Size         = new SizeI(72, 20);
            textBoxText2.Text         = "green";
            textBoxText2.TextChanged += new GwenEventHandler(textBoxText_TextChanged);

            textBoxText3              = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox6);
            textBoxText3.Location     = new PointI(168, 110 + inGroupBoxOffset);
            textBoxText3.Size         = new SizeI(72, 20);
            textBoxText3.Text         = "blue";
            textBoxText3.TextChanged += new GwenEventHandler(textBoxText_TextChanged);

            textBoxText4              = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox6);
            textBoxText4.Location     = new PointI(168, 145 + inGroupBoxOffset);
            textBoxText4.Size         = new SizeI(72, 20);
            textBoxText4.Text         = "yellow";
            textBoxText4.TextChanged += new GwenEventHandler(textBoxText_TextChanged);

            textBoxText5              = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox6);
            textBoxText5.Location     = new PointI(168, 180 + inGroupBoxOffset);
            textBoxText5.Size         = new SizeI(72, 20);
            textBoxText5.Text         = "brown";
            textBoxText5.TextChanged += new GwenEventHandler(textBoxText_TextChanged);

            textBoxText6              = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox6);
            textBoxText6.Location     = new PointI(168, 215 + inGroupBoxOffset);
            textBoxText6.Size         = new SizeI(72, 20);
            textBoxText6.Text         = "cyan";
            textBoxText6.TextChanged += new GwenEventHandler(textBoxText_TextChanged);


            textBoxToolTip1              = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox6);
            textBoxToolTip1.Location     = new PointI(248, 40 + inGroupBoxOffset);
            textBoxToolTip1.Size         = new SizeI(64, 20);
            textBoxToolTip1.Text         = "";
            textBoxToolTip1.TextChanged += new GwenEventHandler(textBoxToolTip_TextChanged);

            textBoxToolTip2              = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox6);
            textBoxToolTip2.Location     = new PointI(248, 75 + inGroupBoxOffset);
            textBoxToolTip2.Size         = new SizeI(64, 20);
            textBoxToolTip2.Text         = "";
            textBoxToolTip2.TextChanged += new GwenEventHandler(textBoxToolTip_TextChanged);

            textBoxToolTip3              = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox6);
            textBoxToolTip3.Location     = new PointI(248, 110 + inGroupBoxOffset);
            textBoxToolTip3.Size         = new SizeI(64, 20);
            textBoxToolTip3.Text         = "";
            textBoxToolTip3.TextChanged += new GwenEventHandler(textBoxToolTip_TextChanged);

            textBoxToolTip4              = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox6);
            textBoxToolTip4.Location     = new PointI(248, 145 + inGroupBoxOffset);
            textBoxToolTip4.Size         = new SizeI(64, 20);
            textBoxToolTip4.Text         = "";
            textBoxToolTip4.TextChanged += new GwenEventHandler(textBoxToolTip_TextChanged);

            textBoxToolTip5              = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox6);
            textBoxToolTip5.Location     = new PointI(248, 180 + inGroupBoxOffset);
            textBoxToolTip5.Size         = new SizeI(64, 20);
            textBoxToolTip5.Text         = "";
            textBoxToolTip5.TextChanged += new GwenEventHandler(textBoxToolTip_TextChanged);

            textBoxToolTip6              = new Alt.GUI.Temporary.Gwen.Control.TextBox(groupBox6);
            textBoxToolTip6.Location     = new PointI(248, 215 + inGroupBoxOffset);
            textBoxToolTip6.Size         = new SizeI(64, 20);
            textBoxToolTip6.Text         = "";
            textBoxToolTip6.TextChanged += new GwenEventHandler(textBoxToolTip_TextChanged);



            groupBox4          = new Alt.GUI.Temporary.Gwen.Control.GroupBox(m_ControlsPanel);
            groupBox4.Location = new PointI(336, 8);
            groupBox4.Size     = new SizeI(248, 72);
            groupBox4.Text     = "Margins";

            inGroupBoxOffset = -15;


            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox4);
            label.Location           = new PointI(12, 22 + inGroupBoxOffset);
            label.Size               = new SizeI(40, 16);
            label.Text               = "Left:";
            label.AutoSizeToContents = true;

            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox4);
            label.Location           = new PointI(12, 46 + inGroupBoxOffset);
            label.Size               = new SizeI(40, 16);
            label.Text               = "Right:";
            label.AutoSizeToContents = true;

            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox4);
            label.Location           = new PointI(132, 22 + inGroupBoxOffset);
            label.Size               = new SizeI(40, 16);
            label.Text               = "Top:";
            label.AutoSizeToContents = true;

            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(groupBox4);
            label.Location           = new PointI(132, 46 + inGroupBoxOffset);
            label.Size               = new SizeI(44, 16);
            label.Text               = "Bottom:";
            label.AutoSizeToContents = true;


            numericUpDownLeftMargin               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox4);
            numericUpDownLeftMargin.Location      = new PointI(64, 20 + inGroupBoxOffset);
            numericUpDownLeftMargin.Maximum       = 20;
            numericUpDownLeftMargin.Size          = new SizeI(48, 20);
            numericUpDownLeftMargin.Value         = 10;
            numericUpDownLeftMargin.ValueChanged += new GwenEventHandler(numericUpDownLeftMargin_ValueChanged);

            numericUpDownRightMargin               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox4);
            numericUpDownRightMargin.Location      = new PointI(64, 44 + inGroupBoxOffset);
            numericUpDownRightMargin.Maximum       = 20;
            numericUpDownRightMargin.Size          = new SizeI(48, 20);
            numericUpDownRightMargin.Value         = 10;
            numericUpDownRightMargin.ValueChanged += new GwenEventHandler(numericUpDownRightMargin_ValueChanged);

            numericUpDownTopMargin               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox4);
            numericUpDownTopMargin.Location      = new PointI(188, 20 + inGroupBoxOffset);
            numericUpDownTopMargin.Maximum       = 20;
            numericUpDownTopMargin.Size          = new SizeI(48, 20);
            numericUpDownTopMargin.Value         = 10;
            numericUpDownTopMargin.ValueChanged += new GwenEventHandler(numericUpDownTopMargin_ValueChanged);

            numericUpDownBottomMargin               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(groupBox4);
            numericUpDownBottomMargin.Location      = new PointI(188, 44 + inGroupBoxOffset);
            numericUpDownBottomMargin.Maximum       = 20;
            numericUpDownBottomMargin.Size          = new SizeI(48, 20);
            numericUpDownBottomMargin.Value         = 10;
            numericUpDownBottomMargin.ValueChanged += new GwenEventHandler(numericUpDownBottomMargin_ValueChanged);



            checkBoxFitChart                 = new Alt.GUI.Temporary.Gwen.Control.LabeledCheckBox(m_ControlsPanel);
            checkBoxFitChart.Location        = new PointI(336, 88);
            checkBoxFitChart.Text            = "Fit chart to panel";
            checkBoxFitChart.CheckedChanged += new System.EventHandler(checkBoxFitChart_CheckedChanged);



            groupBox1          = new Alt.GUI.Temporary.Gwen.Control.RadioButtonGroup(m_ControlsPanel, "Shadow style");
            groupBox1.Location = new PointI(485, 95); //84);
            groupBox1.Size     = new SizeI(104, 62);  //82);


            radioButtonShadowStyleNone                 = groupBox1.AddOption("None");
            radioButtonShadowStyleNone.Tag             = "";
            radioButtonShadowStyleNone.CheckedChanged += new System.EventHandler(radioButtonShadowStyle_Changed);

            radioButtonShadowStyleUniform = groupBox1.AddOption("Uniform");
            radioButtonShadowStyleUniform.Select();
            radioButtonShadowStyleUniform.Tag             = "";
            radioButtonShadowStyleUniform.CheckedChanged += new System.EventHandler(radioButtonShadowStyle_Changed);

            /*TEMP
             * radioButtonShadowStyleGradual = groupBox1.AddOption("Gradual");
             * //radioButtonShadowStyleGradual.Select();
             * radioButtonShadowStyleGradual.Tag = "";
             * radioButtonShadowStyleGradual.CheckedChanged += new System.EventHandler(radioButtonShadowStyle_Changed);*/



            numericUpDownPieHeight = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(m_ControlsPanel);
            numericUpDownPieHeight.DecimalPlaces = 2;
            numericUpDownPieHeight.Increment     = 0.05f;
            numericUpDownPieHeight.Location      = new PointI(408, 114);
            numericUpDownPieHeight.Maximum       = 0.5f;
            numericUpDownPieHeight.Size          = new SizeI(48, 20);
            numericUpDownPieHeight.Value         = 0.25f;
            numericUpDownPieHeight.ValueChanged += new GwenEventHandler(numericUpDownPieHeight_ValueChanged);


            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(m_ControlsPanel);
            label.Location           = new PointI(336, 116);
            label.Size               = new SizeI(72, 16);
            label.Text               = "Pie Height:";
            label.TextAlign          = ContentAlignment.MiddleLeft;
            label.AutoSizeToContents = true;


            numericUpDownAngle               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(m_ControlsPanel);
            numericUpDownAngle.Increment     = 10;
            numericUpDownAngle.Location      = new PointI(408, 144);
            numericUpDownAngle.Maximum       = 400;
            numericUpDownAngle.Minimum       = -360;
            numericUpDownAngle.Size          = new SizeI(48, 20);
            numericUpDownAngle.Value         = -30;
            numericUpDownAngle.ValueChanged += new GwenEventHandler(numericUpDownAngle_ValueChanged);


            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(m_ControlsPanel);
            label.Location           = new PointI(336, 146);
            label.Size               = new SizeI(72, 16);
            label.Text               = "Initial angle:";
            label.AutoSizeToContents = true;



            comboBoxEdgeType               = new Alt.GUI.Temporary.Gwen.Control.ComboBox(m_ControlsPanel);
            comboBoxEdgeType.Location      = new PointI(408, 178);
            comboBoxEdgeType.Size          = new SizeI(176, 21);
            comboBoxEdgeType.ItemSelected += new GwenEventHandler(comboBoxEdgeType_SelectedIndexChanged);


            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(m_ControlsPanel);
            label.Location           = new PointI(336, 180);
            label.Size               = new SizeI(72, 16);
            label.Text               = "Edge color:";
            label.AutoSizeToContents = true;



            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(m_ControlsPanel);
            label.Location           = new PointI(336, 208);
            label.Size               = new SizeI(72, 16);
            label.Text               = "Edge width:";
            label.AutoSizeToContents = true;


            numericUpDownEdgeLineWidth = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(m_ControlsPanel);
            numericUpDownEdgeLineWidth.DecimalPlaces = 1;
            numericUpDownEdgeLineWidth.Increment     = 0.5f;
            numericUpDownEdgeLineWidth.Location      = new PointI(408, 206);
            numericUpDownEdgeLineWidth.Maximum       = 5;
            numericUpDownEdgeLineWidth.Size          = new SizeI(48, 20);
            numericUpDownEdgeLineWidth.Value         = 3;
            numericUpDownEdgeLineWidth.ValueChanged += new GwenEventHandler(numericUpDownEdgeLineWidth_ValueChanged);


            label                    = new Alt.GUI.Temporary.Gwen.Control.Label(m_ControlsPanel);
            label.Location           = new PointI(336, 236);
            label.Size               = new SizeI(48, 16);
            label.Text               = "Alpha:";
            label.AutoSizeToContents = true;


            m_numericUpDownAlpha               = new Alt.GUI.Temporary.Gwen.Control.NumericUpDown(m_ControlsPanel);
            m_numericUpDownAlpha.Increment     = 5;
            m_numericUpDownAlpha.Location      = new PointI(408, 234);
            m_numericUpDownAlpha.Maximum       = 255;
            m_numericUpDownAlpha.Size          = new SizeI(48, 20);
            m_numericUpDownAlpha.Value         = 130;
            m_numericUpDownAlpha.ValueChanged += new GwenEventHandler(m_numericUpDownAlpha_ValueChanged);



            FillEdgeColorTypeListBox();

            InitializeChart();
        }