Пример #1
0
        private void DrawNumbers(Graphics g, TypeNumbers type)
        {
            if (type == TypeNumbers.None)
            {
                return;
            }

            g.ResetTransform();
            g.TranslateTransform(xCenter, yCenter);


            g.DrawString(12.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), -(Radius / 10), -Radius + (Radius / 8));
            g.DrawString(6.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), -(Radius / 20), -(-Radius + (Radius / 3.5f)));
            g.DrawString(3.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), -(-Radius + (Radius / 3.5f)), -(Radius / 15));
            g.DrawString(9.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), -Radius + (Radius / 7f), -(Radius / 15));

            if (type == TypeNumbers.All)
            {
                g.DrawString(1.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), -(Radius / 10) + (Radius / 2.3f), -Radius + (Radius / 7) + (Radius / 15));
                g.DrawString(7.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), -(Radius / 20) - (Radius / 2.5f), -(-Radius + (Radius / 3.5f) + (Radius / 12)));
                g.DrawString(5.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), -(Radius / 20) + (Radius / 2.5f), -(-Radius + (Radius / 3.5f) + (Radius / 12)));
                g.DrawString(11.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), -(Radius / 10) - (Radius / 2.7f), -Radius + (Radius / 7) + (Radius / 14));

                g.DrawString(2.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), -(Radius / 10) + (Radius / 1.4f), -Radius + (Radius / 7) + (Radius / 2.8f));
                g.DrawString(10.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), -(Radius / 10) - (Radius / 1.5f), -Radius + (Radius / 6) + (Radius / 3f));
                g.DrawString(4.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), -(Radius / 20) + (Radius / 1.5f), -(-Radius + (Radius / 3.5f) + (Radius / 2.5f)));

                g.DrawString(8.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), -(Radius / 20) - (Radius / 1.5f), -(-Radius + (Radius / 3.5f) + (Radius / 2.5f)));
            }


            //double x = -(Radius / 1)- 50;
            //double y = -Radius + (Radius / 1);

            //double p = Math.Sqrt((x * x) + (y * y));

            ////MessageBox.Show(x.ToString() + " " + y.ToString() + " " + p.ToString());
            //p -= 100;
            //double angle = .35;
            //for (int i = 1; i < 13; i++)
            //{
            //    x = p * Math.Sin(angle);
            //    y = p * Math.Cos(angle);
            //    g.DrawString(i.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), (float)x, (float)-y);
            //    angle += .525;
            //}
            ////x = p * Math.Cos(angle);
            ////y = p * Math.Sin(angle);
            ////g.DrawString(12.ToString(), new Font("Arial", Radius / 10, FontStyle.Bold), new SolidBrush(NumbersColor), (float)x,(float)y);
        }
Пример #2
0
 public void SetErrorType()
 {
     SetErrorStatus();
     this.TypeNumber = TypeNumbers.Error;
 }
Пример #3
0
 public void SetWarningType()
 {
     SetErrorStatus();
     this.TypeNumber = TypeNumbers.Warning;
 }
Пример #4
0
 public void SetInfoType()
 {
     SetSuccessStatus();
     this.TypeNumber = TypeNumbers.Info;
 }
Пример #5
0
 public void SetSuccessType()
 {
     SetSuccessStatus();
     this.TypeNumber = TypeNumbers.Success;
 }
Пример #6
0
 public void SetNoneType()
 {
     SetSuccessStatus();
     this.TypeNumber = TypeNumbers.None;
 }