Ejemplo n.º 1
0
        public void Dispatch()
        {
            foreach (DataBindingList bindingList in this.CompInfomation)
            {
                Form frm = Application.OpenForms[bindingList.FormName];
                if (frm != null)
                {
                    object obj = FuncGeneral.GetControlByName(frm, bindingList.CompName);
                    if (obj != null)
                    {
                        string obj_type = obj.GetType().ToString();
                        if (obj_type == "Helper.Valve")
                        {
                            Valve obj_valve;
                            obj_valve = (Valve)obj;
                            if (bindingList.Propertie == "State")
                            {
                                obj_valve.State = FuncGeneral.GetState(Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString());
                            }
                            if (bindingList.Propertie == "Mode")
                            {
                                obj_valve.Mode = FuncGeneral.GetMode(Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString());
                            }
                            if (bindingList.Propertie == "Rotation")
                            {
                                double wert = 0.0;
                                double.TryParse(Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString(), out wert);
                                obj_valve.Rotation = wert;
                            }
                        }

                        if (obj_type == "Helper.LedRectangle")
                        {
                            CompLedRectangle obj_led_rectangle;
                            obj_led_rectangle = (CompLedRectangle)obj;
                            if (bindingList.Propertie == "State")
                            {
                                obj_led_rectangle.State = FuncGeneral.GetSateLED(Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString());
                            }
                        }

                        if (obj_type == "Helper.Pump")
                        {
                            Pump obj_pump;
                            obj_pump = (Pump)obj;
                            if (bindingList.Propertie == "State")
                            {
                                obj_pump.State = FuncGeneral.GetStatePump(Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString());
                            }
                        }


                        if (obj_type == "Helper.Lifter")
                        {
                            Lifter obj_lifter;
                            obj_lifter = (Lifter)obj;
                            if (bindingList.Propertie == "State")
                            {
                                obj_lifter.State = FuncGeneral.GetStateLift(Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString());
                            }
                        }

                        if (obj_type == "Helper.WaterTank")
                        {
                            WaterTank obj_water_tank;
                            obj_water_tank = (WaterTank)obj;
                            if (bindingList.Propertie == "Value")
                            {
                                double wert = 0.0;
                                double.TryParse(Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString(), out wert);
                                obj_water_tank.Value = wert;
                            }
                            if (bindingList.Propertie == "Error")
                            {
                                bool wert = false;
                                if (Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString() != "0")
                                {
                                    wert = true;
                                }
                                obj_water_tank.Error = wert;
                            }
                        }

                        if (obj_type == "Helper.LedRound")
                        {
                            CompLedRound obj_led_round;
                            obj_led_round = (CompLedRound)obj;
                            if (bindingList.Propertie == "State")
                            {
                                obj_led_round.State = FuncGeneral.GetSateLED(Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString());
                            }
                        }

                        //if (obj_type == "Helper.Pipe")
                        //{
                        //    CompPipe obj_pipe;
                        //    obj_pipe = (CompPipe)obj;
                        //    if (bindingList.Propertie == "Flow")
                        //    {
                        //        obj_pipe.Flow = FuncGeneral.GetSatePipe(Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString());
                        //    }
                        //}

                        if (obj_type == "Helper.ToggleSwitch")
                        {
                            CompToggleSwitch obj_toogle_switch;
                            obj_toogle_switch = (CompToggleSwitch)obj;
                            if (bindingList.Propertie == "State")
                            {
                                obj_toogle_switch.State = FuncGeneral.GetSateToggleSwitch(Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString());
                            }
                        }

                        if (obj_type == "Helper.TxtBox")
                        {
                            CompTxtBox obj_txt_box;
                            obj_txt_box = (CompTxtBox)obj;
                            if (bindingList.Propertie == "Text")
                            {
                                obj_txt_box.Text = Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString();
                            }
                        }

                        if (obj_type == "Helper.BitButton")
                        {
                            CompBitButton obj_bit_button;
                            obj_bit_button = (CompBitButton)obj;
                            if (bindingList.Propertie == "PictureNumber")
                            {
                                obj_bit_button.PictureNumber = Convert.ToInt32(Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString());
                            }
                        }

                        if (obj_type == "Helper.InputBox")
                        {
                            CompInputBox obj_input_box;
                            obj_input_box = (Helper.CompInputBox)obj;
                            if (bindingList.Propertie == "Text")
                            {
                                if (!obj_input_box.Focused)
                                {
                                    double wert   = 0.0;
                                    string format = "{0:" + obj_input_box.Format + "}";
                                    bool   testen = Double.TryParse(Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString(), out wert);
                                    if (testen)
                                    {
                                        obj_input_box.Text = String.Format(format, wert);
                                    }
                                    else
                                    {
                                        obj_input_box.Text = String.Format(format, wert);
                                    }
                                }
                            }
                        }

                        if (obj_type == "System.Windows.Forms.TextBox")
                        {
                            TextBox obj_text_box;
                            obj_text_box = (TextBox)obj;
                            if (bindingList.Propertie == "Text")
                            {
                                if (!obj_text_box.Focused)
                                {
                                    obj_text_box.Text = Glb_Plc.DatabasesValues[bindingList.SymbolName].ToString();
                                }
                            }
                        }
                    }
                }
            }
        }
Ejemplo n.º 2
0
        protected override void OnPaint(PaintEventArgs pe)
        {
            pe.Graphics.SmoothingMode = SmoothingMode.AntiAlias;
            Color  color = Color.Yellow;
            double rot   = 0.0;

            base.OnPaint(pe);
            Graphics g = pe.Graphics;

            if (m_State == PumpState.NotUsed)
            {
                color = Color.Gray;
            }
            if (m_State == PumpState.Ready)
            {
                color = Color.Yellow;
            }
            if (m_State == PumpState.Running)
            {
                color = Color.Lime;
            }
            if (m_State == PumpState.Error)
            {
                color = Color.Red;
            }

            if (m_FlowDirection == PumpFlowDirection.Right)
            {
                rot = 0.0;
            }

            if (m_FlowDirection == PumpFlowDirection.Down)
            {
                rot = 90.0;
            }
            if (m_FlowDirection == PumpFlowDirection.Left)
            {
                rot = 180.0;
            }
            if (m_FlowDirection == PumpFlowDirection.Up)
            {
                rot = 270.0;
            }
            int height = this.Height;
            int width  = this.Width;

            Point pointCenter = new Point();

            pointCenter.X = height / 2;
            pointCenter.Y = width / 2;

            int center = height / 2;

            double radius = height / 2.0;
            double a      = Math.Sqrt(Math.Pow(radius, 2.0) / 2.0);
            double y      = radius - a;
            int    y1     = Convert.ToInt32(y);
            int    x1     = y1;
            int    y2     = Convert.ToInt32(2.0 * a + y);
            int    x2     = y1;
            int    y3     = Convert.ToInt32(height / 2.0);
            int    x3     = width;



            Point[] point = { new Point(x1, y1), new Point(x2, y2), new Point(x3, y3) };


            point[0] = FuncGeneral.RotatePoint(point[0], pointCenter, rot);
            point[1] = FuncGeneral.RotatePoint(point[1], pointCenter, rot);
            point[2] = FuncGeneral.RotatePoint(point[2], pointCenter, rot);

            SolidBrush brush    = new SolidBrush(Color.White);
            int        penWidth = 3;
            Pen        pen      = new Pen(Color.White, penWidth);
            int        left     = penWidth / 2;
            int        top      = left;
            Rectangle  rec      = new Rectangle(left, top, width - penWidth, height - penWidth);

            pe.Graphics.DrawEllipse(pen, rec);
            pe.Graphics.FillEllipse(brush, rec);

            Pen        penTriangle   = new Pen(color);
            SolidBrush brushTriangle = new SolidBrush(color);

            pe.Graphics.DrawPolygon(penTriangle, point);
            pe.Graphics.FillPolygon(brushTriangle, point);

            Font         f         = new Font("Arial", 14f, FontStyle.Bold);
            StringFormat strFormat = new StringFormat();

            strFormat.Alignment     = StringAlignment.Center;
            strFormat.LineAlignment = StringAlignment.Center;


            g.DrawString(this.Caption, f, Brushes.Black, rec, strFormat);
        }
Ejemplo n.º 3
0
        protected override void OnPaint(PaintEventArgs pe)
        {
            base.OnPaint(pe);
            bool  drawObenUnten = false;
            float drehung       = 0.0F;

            Color colorOben;
            Color colorUnten;
            Color colorPfeil;
            Color colorBackground;


            colorBackground = Color.Transparent;
            colorOben       = Color.Yellow;
            colorUnten      = Color.Lime;
            colorPfeil      = Color.Gray;

            if (this.m_State == LifterState.Lifting)
            {
                drawObenUnten   = false;
                drehung         = 0.0F;
                colorBackground = Color.Transparent;
                colorOben       = Color.DarkGreen;
                colorUnten      = Color.Yellow;
                colorPfeil      = Color.Gray;
            }
            if (this.m_State == LifterState.Up)
            {
                drawObenUnten   = false;
                drehung         = 0.0F;
                colorBackground = Color.Transparent;
                colorOben       = Color.Yellow;
                colorUnten      = Color.Yellow;
                colorPfeil      = Color.Blue;
            }

            if (this.m_State == LifterState.Sinking)
            {
                drawObenUnten   = false;
                drehung         = 180.0F;
                colorBackground = Color.Transparent;
                colorOben       = Color.DarkGreen;
                colorUnten      = Color.Yellow;
                colorPfeil      = Color.Gray;
            }
            if (this.m_State == LifterState.Down)
            {
                drawObenUnten   = false;
                drehung         = 180.0F;
                colorBackground = Color.Transparent;
                colorOben       = Color.DarkGreen;
                colorUnten      = Color.DarkGreen;
                colorPfeil      = Color.Blue;
            }
            if (this.m_State == LifterState.Error)
            {
                drawObenUnten   = true;
                drehung         = 0.0F;
                colorBackground = Color.Red;
                colorOben       = Color.Gray;
                colorUnten      = Color.Gray;
                colorPfeil      = Color.Gray;
            }
            Graphics g = pe.Graphics;

            g.SmoothingMode = SmoothingMode.AntiAlias;

            this.BackColor = colorBackground;
            this.UrsprungsKoordinaden.Clear();
            this.AddUrsprungsKoordinaden(0.0F, 1.0F); //00
            this.AddUrsprungsKoordinaden(4.0F, 1.0F); //01
            this.AddUrsprungsKoordinaden(4.0F, 0.0F); //02
            this.AddUrsprungsKoordinaden(0.0F, 0.0F); //03

            penOutline.Color    = colorUnten;
            brushTriangle.Color = colorUnten;
            g.DrawPolygon(penOutline, this.UrsprungsKoordinaden.ToArray());
            g.FillPolygon(brushTriangle, this.UrsprungsKoordinaden.ToArray());

            this.UrsprungsKoordinaden.Clear();
            this.AddUrsprungsKoordinaden(0.0F, 12.0F); //00
            this.AddUrsprungsKoordinaden(4.0F, 12.0F); //01
            this.AddUrsprungsKoordinaden(4.0F, 11.0F); //02
            this.AddUrsprungsKoordinaden(0.0F, 11.0F); //03


            penOutline.Color    = colorOben;
            brushTriangle.Color = colorOben;
            g.DrawPolygon(penOutline, this.UrsprungsKoordinaden.ToArray());
            g.FillPolygon(brushTriangle, this.UrsprungsKoordinaden.ToArray());


            if (!drawObenUnten)
            {
                this.UrsprungsKoordinaden.Clear();
                this.AddUrsprungsKoordinaden(2.0F, 9.0F); //00
                this.AddUrsprungsKoordinaden(4.0F, 8.0F); //01
                this.AddUrsprungsKoordinaden(4.0F, 7.0F); //02
                this.AddUrsprungsKoordinaden(3.0F, 7.0F); //03
                this.AddUrsprungsKoordinaden(3.0F, 3.0F); //04
                this.AddUrsprungsKoordinaden(1.0F, 3.0F); //05
                this.AddUrsprungsKoordinaden(1.0F, 7.0F); //06
                this.AddUrsprungsKoordinaden(0.0F, 7.0F); //07
                this.AddUrsprungsKoordinaden(0.0F, 8.0F); //08
            }
            else
            {
                this.UrsprungsKoordinaden.Clear();
                this.AddUrsprungsKoordinaden(2.0F, 9.0F); //00
                this.AddUrsprungsKoordinaden(4.0F, 8.0F); //01
                this.AddUrsprungsKoordinaden(4.0F, 7.0F); //02
                this.AddUrsprungsKoordinaden(3.0F, 7.0F); //03
                this.AddUrsprungsKoordinaden(3.0F, 5.0F); //04
                this.AddUrsprungsKoordinaden(4.0F, 5.0F); //05
                this.AddUrsprungsKoordinaden(4.0F, 4.0F); //06
                this.AddUrsprungsKoordinaden(2.0F, 3.0F); //07
                this.AddUrsprungsKoordinaden(0.0F, 4.0F); //08
                this.AddUrsprungsKoordinaden(0.0F, 5.0F); //09
                this.AddUrsprungsKoordinaden(1.0F, 5.0F); //10
                this.AddUrsprungsKoordinaden(1.0F, 7.0F); //11
                this.AddUrsprungsKoordinaden(0.0F, 7.0F); //12
                this.AddUrsprungsKoordinaden(0.0F, 8.0F); //13
            }

            FuncGeneral.RotatePoints(ref this.UrsprungsKoordinaden, this.CentrePoint, drehung);

            penOutline.Color    = colorPfeil;
            brushTriangle.Color = colorPfeil;
            g.DrawPolygon(penOutline, this.UrsprungsKoordinaden.ToArray());
            g.FillPolygon(brushTriangle, this.UrsprungsKoordinaden.ToArray());
        }
Ejemplo n.º 4
0
        protected override void OnPaint(PaintEventArgs pe)
        {
            Color  color = Color.Yellow;
            double rot   = 0.0;

            base.OnPaint(pe);
            Graphics g             = pe.Graphics;
            double   valveRotation = 0.0;

            pe.Graphics.SmoothingMode = SmoothingMode.AntiAlias;


            if (m_SteeringMode == Helper.SteeringMode.Analog)
            {
                color = Color.Black;
                if (m_Rotation < 0.0)
                {
                    this.Rotation = 0.0;
                }
                if (m_Rotation > 100.0)
                {
                    this.Rotation = 100.0;
                }
                valveRotation = 90.0 / 100.0 * m_Rotation;
            }
            else
            {
                if (m_State == ValveState.Open)
                {
                    color         = Color.Black;
                    valveRotation = 0.0;
                }
                if (m_State == ValveState.Close)
                {
                    color         = Color.Black;
                    valveRotation = 90.0;
                }
                if (m_State == ValveState.Undefine)
                {
                    color         = Color.Black;
                    valveRotation = 45.0 + 90.0;
                }
            }
            if (m_State == ValveState.Error)
            {
                color         = Color.Red;
                valveRotation = 45.0;
            }

            if (m_FlowDirection == ValveDirection.Horizontal)
            {
                rot = 0.0;
            }

            if (m_FlowDirection == ValveDirection.Vertical)
            {
                rot = 90.0;
            }
            double heightBar = 10.0;

            if (m_Type == ValveType.Normal)
            {
                heightBar   = 10.0;
                this.Width  = 40;
                this.Height = 40;
            }
            if (m_Type == ValveType.Small)
            {
                heightBar   = 6.0;
                this.Width  = 30;
                this.Height = 30;
            }

            if (m_Type == ValveType.Big)
            {
                heightBar   = 12.0;
                this.Width  = 50;
                this.Height = 50;
            }

            rot = rot + valveRotation;
            int height = this.Height;
            int width  = this.Width;

            Point pointCenter = new Point();

            pointCenter.X = height / 2;
            pointCenter.Y = width / 2;

            int center = height / 2;



            double widthImage  = this.Width;
            double heightImage = this.Height;



            double radius = heightImage / 2.0;

            double x_1 = 0.0;
            double x_2 = 0.0;
            double x_3 = 0.0;
            double x_4 = 0.0;

            double y_1 = 0.0;
            double y_2 = 0.0;
            double y_3 = 0.0;
            double y_4 = 0.0;

            double widthBar = (Math.Sqrt((radius * radius) - (heightBar / 2.0 * heightBar / 2.0)));

            x_1 = radius - widthBar;
            y_1 = heightImage / 2.0 - heightBar / 2.0;

            x_2 = x_1;
            y_2 = y_1 + heightBar;

            x_3 = x_2 + widthBar * 2.0;
            y_3 = y_2;

            x_4 = x_3;
            y_4 = y_1;

            int x1 = Convert.ToInt32(x_1);
            int x2 = Convert.ToInt32(x_2);
            int x3 = Convert.ToInt32(x_3);
            int x4 = Convert.ToInt32(x_4);

            int y1 = Convert.ToInt32(y_1);
            int y2 = Convert.ToInt32(y_2 - 1);
            int y3 = Convert.ToInt32(y_3 - 1);
            int y4 = Convert.ToInt32(y_4);

            Point[] point = { new Point(x1, y1), new Point(x2, y2), new Point(x3, y3), new Point(x4, y4) };

            //rot = 10.0;
            point[0] = FuncGeneral.RotatePoint(point[0], pointCenter, rot);
            point[1] = FuncGeneral.RotatePoint(point[1], pointCenter, rot);
            point[2] = FuncGeneral.RotatePoint(point[2], pointCenter, rot);
            point[3] = FuncGeneral.RotatePoint(point[3], pointCenter, rot);

            Color colorValve = Color.White;

            if (this.m_Mode == ValveMode.Automatic)
            {
                colorValve = Color.White;
            }
            if (this.m_Mode == ValveMode.Manuell)
            {
                colorValve = Color.Gainsboro;
            }

            SolidBrush brush    = new SolidBrush(colorValve);
            int        penWidth = 3;
            Pen        pen      = new Pen(Color.Black, penWidth);
            int        left     = penWidth / 2;
            int        top      = left;
            Rectangle  rec      = new Rectangle(left, top, width - penWidth, height - penWidth);

            pe.Graphics.DrawEllipse(pen, rec);
            pe.Graphics.FillEllipse(brush, rec);

            Pen        penTriangle   = new Pen(color);
            SolidBrush brushTriangle = new SolidBrush(color);

            pe.Graphics.DrawPolygon(penTriangle, point);
            pe.Graphics.FillPolygon(brushTriangle, point);

            Font         f         = new Font("Arial", 14f, FontStyle.Bold);
            StringFormat strFormat = new StringFormat();

            strFormat.Alignment     = StringAlignment.Center;
            strFormat.LineAlignment = StringAlignment.Center;


            g.DrawString(this.Caption, f, Brushes.Black, rec, strFormat);
        }
Ejemplo n.º 5
0
        protected override void OnPaint(PaintEventArgs pe)
        {
            base.OnPaint(pe);
            Graphics g = pe.Graphics;

            pe.Graphics.SmoothingMode = SmoothingMode.AntiAlias;


            int nr           = 0;
            int startPosX    = 40;
            int startPosY    = 20;
            int hoeheBalken  = 20;
            int breiteBalken = 40;

            int radiusKreis = 15;



            this.SetXY(startPosX, startPosY, true);

            m_PointRotate.Y = m_Points[0].Y - 10;
            m_PointRotate.X = m_Points[0].X;

            int LinksKreis = m_PointRotate.X - radiusKreis;
            int ObenKreis  = m_PointRotate.Y - radiusKreis;

            this.m_Rec.X      = LinksKreis - 1;
            this.m_Rec.Y      = ObenKreis - 1;
            this.m_Rec.Width  = radiusKreis * 2;
            this.m_Rec.Height = radiusKreis * 2;


            m_Pen.Color = Color.White;

            for (int i = 0; i < 7; i++)
            {
                this.SetXY(startPosX + nr * breiteBalken, startPosY, true);
                this.SetXY(startPosX + nr * breiteBalken, startPosY + hoeheBalken);
                this.SetXY(startPosX + nr * breiteBalken + breiteBalken, startPosY + hoeheBalken);
                this.SetXY(startPosX + nr * breiteBalken + breiteBalken, startPosY);



                m_Points[0] = FuncGeneral.RotatePoint(m_Points[0], m_PointRotate, m_rotation);
                m_Points[1] = FuncGeneral.RotatePoint(m_Points[1], m_PointRotate, m_rotation);
                m_Points[2] = FuncGeneral.RotatePoint(m_Points[2], m_PointRotate, m_rotation);
                m_Points[3] = FuncGeneral.RotatePoint(m_Points[3], m_PointRotate, m_rotation);

                double asd = i % 2;
                if (i % 2 == 0)
                {
                    m_Pen.Color = Color.Red;
                }
                else
                {
                    m_Pen.Color = Color.White;
                }

                m_Brush.Color = m_Pen.Color;
                g.DrawPolygon(m_Pen, m_Points.ToArray());
                g.FillPolygon(m_Brush, m_Points.ToArray());

                nr++;
                this.m_Pen.Color = Color.Black;
                m_Brush.Color    = m_Pen.Color;

                g.DrawEllipse(m_Pen, m_Rec);
                g.FillEllipse(m_Brush, m_Rec);
            }
        }
Ejemplo n.º 6
0
        protected override void OnPaint(PaintEventArgs pe)
        {
            base.OnPaint(pe);
            float drehung = (float)this.m_Direction;

            Color colorOutline;
            Color colorInLine;
            Color colorBackground;

            colorBackground = Color.Transparent;
            colorOutline    = Color.White;
            colorInLine     = this.m_ColorCross;

            Graphics g = pe.Graphics;

            g.SmoothingMode = SmoothingMode.AntiAlias;

            this.BackColor = colorBackground;
            this.UrsprungsKoordinaden.Clear();

            if (this.m_State == CrossState.StandStill)
            {
                this.AddUrsprungsKoordinaden(4.0F, 8.0F); // 0
                this.AddUrsprungsKoordinaden(6.0F, 7.0F); // 1
                this.AddUrsprungsKoordinaden(5.0F, 7.0F); // 2
                this.AddUrsprungsKoordinaden(5.0F, 5.0F); // 3
                this.AddUrsprungsKoordinaden(7.0F, 5.0F); // 4
                this.AddUrsprungsKoordinaden(7.0F, 6.0F); // 5
                this.AddUrsprungsKoordinaden(8.0F, 4.0F); // 6
                this.AddUrsprungsKoordinaden(7.0F, 2.0F); // 7
                this.AddUrsprungsKoordinaden(7.0F, 3.0F); // 8
                this.AddUrsprungsKoordinaden(5.0F, 3.0F); // 9
                this.AddUrsprungsKoordinaden(5.0F, 1.0F); //10
                this.AddUrsprungsKoordinaden(6.0F, 1.0F); //11
                this.AddUrsprungsKoordinaden(4.0F, 0.0F); //12
                this.AddUrsprungsKoordinaden(2.0F, 1.0F); //13
                this.AddUrsprungsKoordinaden(3.0F, 1.0F); //14
                this.AddUrsprungsKoordinaden(3.0F, 3.0F); //15
                this.AddUrsprungsKoordinaden(1.0F, 3.0F); //16
                this.AddUrsprungsKoordinaden(1.0F, 2.0F); //17
                this.AddUrsprungsKoordinaden(0.0F, 4.0F); //18
                this.AddUrsprungsKoordinaden(1.0F, 6.0F); //19
                this.AddUrsprungsKoordinaden(1.0F, 5.0F); //20
                this.AddUrsprungsKoordinaden(3.0F, 5.0F); //21
                this.AddUrsprungsKoordinaden(3.0F, 7.0F); //22
                this.AddUrsprungsKoordinaden(2.0F, 7.0F); //23
            }

            if (this.m_State == CrossState.Moving)
            {
                this.AddUrsprungsKoordinaden(4.0F, 7.0F); // 0
                this.AddUrsprungsKoordinaden(7.0F, 5.0F); // 1
                this.AddUrsprungsKoordinaden(5.0F, 5.0F); // 2
                this.AddUrsprungsKoordinaden(5.0F, 1.0F); // 3
                this.AddUrsprungsKoordinaden(3.0F, 1.0F); // 4
                this.AddUrsprungsKoordinaden(3.0F, 5.0F); // 5
                this.AddUrsprungsKoordinaden(1.0F, 5.0F); // 6
                FuncGeneral.RotatePoints(ref this.UrsprungsKoordinaden, this.CentrePoint, drehung);
            }

            penOutline.Width = 3;

            penOutline.Color    = colorOutline;
            brushTriangle.Color = colorInLine;
            g.DrawPolygon(penOutline, this.UrsprungsKoordinaden.ToArray());
            g.FillPolygon(brushTriangle, this.UrsprungsKoordinaden.ToArray());

            this.UrsprungsKoordinaden.Clear();
            this.AddUrsprungsKoordinaden(0.5F, 0.5F); // 0
            this.AddUrsprungsKoordinaden(7.0F, 7.0F); // 0

            float x    = this.UrsprungsKoordinaden[0].X;
            float y    = this.UrsprungsKoordinaden[0].Y;
            float widh = this.UrsprungsKoordinaden[1].X;
        }