Example #1
0
 /// <summary>
 /// 设计器支持所需的方法 - 不要修改
 /// 使用代码编辑器修改此方法的内容。
 /// </summary>
 private void InitializeComponent()
 {
     System.Windows.Forms.DataVisualization.Charting.PolylineAnnotation polylineAnnotation1 = new System.Windows.Forms.DataVisualization.Charting.PolylineAnnotation();
     System.Windows.Forms.DataVisualization.Charting.ChartArea          chartArea1          = new System.Windows.Forms.DataVisualization.Charting.ChartArea();
     System.Windows.Forms.DataVisualization.Charting.Legend             legend1             = new System.Windows.Forms.DataVisualization.Charting.Legend();
     System.Windows.Forms.DataVisualization.Charting.Series             series1             = new System.Windows.Forms.DataVisualization.Charting.Series();
     System.Windows.Forms.DataVisualization.Charting.Series             series2             = new System.Windows.Forms.DataVisualization.Charting.Series();
     this.do配置             = new Utility.WindowsForm.U按钮();
     this.label2           = new System.Windows.Forms.Label();
     this.chart1           = new System.Windows.Forms.DataVisualization.Charting.Chart();
     this.flowLayoutPanel1 = new System.Windows.Forms.FlowLayoutPanel();
     this.outCPU占用率        = new System.Windows.Forms.Label();
     this.out内存占用率         = new System.Windows.Forms.Label();
     ((System.ComponentModel.ISupportInitialize)(this.chart1)).BeginInit();
     this.flowLayoutPanel1.SuspendLayout();
     this.SuspendLayout();
     //
     // do配置
     //
     this.do配置.Anchor                    = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
     this.do配置.BackColor                 = System.Drawing.Color.White;
     this.do配置.BackgroundImageLayout     = System.Windows.Forms.ImageLayout.Stretch;
     this.do配置.FlatAppearance.BorderSize = 0;
     this.do配置.FlatStyle                 = System.Windows.Forms.FlatStyle.Flat;
     this.do配置.ForeColor                 = System.Drawing.Color.FromArgb(((int)(((byte)(38)))), ((int)(((byte)(164)))), ((int)(((byte)(221)))));
     this.do配置.Location                  = new System.Drawing.Point(361, 3);
     this.do配置.Name     = "do配置";
     this.do配置.Size     = new System.Drawing.Size(52, 25);
     this.do配置.TabIndex = 75;
     this.do配置.Text     = "配置";
     this.do配置.UseVisualStyleBackColor = false;
     this.do配置.大小   = new System.Drawing.Size(52, 25);
     this.do配置.文字颜色 = System.Drawing.Color.FromArgb(((int)(((byte)(38)))), ((int)(((byte)(164)))), ((int)(((byte)(221)))));
     this.do配置.颜色   = System.Drawing.Color.White;
     //
     // label2
     //
     this.label2.AutoSize  = true;
     this.label2.ForeColor = System.Drawing.Color.Gray;
     this.label2.Location  = new System.Drawing.Point(3, 4);
     this.label2.Name      = "label2";
     this.label2.Size      = new System.Drawing.Size(32, 17);
     this.label2.TabIndex  = 74;
     this.label2.Text      = "资源";
     //
     // chart1
     //
     this.chart1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
                                                                 | System.Windows.Forms.AnchorStyles.Left)
                                                                | System.Windows.Forms.AnchorStyles.Right)));
     polylineAnnotation1.Name = "PolylineAnnotation1";
     this.chart1.Annotations.Add(polylineAnnotation1);
     this.chart1.BorderlineColor              = System.Drawing.Color.Gainsboro;
     this.chart1.BorderlineDashStyle          = System.Windows.Forms.DataVisualization.Charting.ChartDashStyle.Dash;
     chartArea1.AxisX.LabelStyle.Enabled      = false;
     chartArea1.AxisX.MajorGrid.LineColor     = System.Drawing.Color.DarkGray;
     chartArea1.AxisX.MajorGrid.LineDashStyle = System.Windows.Forms.DataVisualization.Charting.ChartDashStyle.Dash;
     chartArea1.AxisX.Maximum                 = 60D;
     chartArea1.AxisX.Minimum                 = 1D;
     chartArea1.AxisY.MajorGrid.LineColor     = System.Drawing.Color.DarkGray;
     chartArea1.AxisY.MajorGrid.LineDashStyle = System.Windows.Forms.DataVisualization.Charting.ChartDashStyle.Dash;
     chartArea1.AxisY.Maximum                 = 100D;
     chartArea1.AxisY.Minimum                 = 0D;
     chartArea1.Name = "ChartArea1";
     this.chart1.ChartAreas.Add(chartArea1);
     legend1.Name = "Legend1";
     this.chart1.Legends.Add(legend1);
     this.chart1.Location  = new System.Drawing.Point(6, 34);
     this.chart1.Name      = "chart1";
     series1.ChartArea     = "ChartArea1";
     series1.ChartType     = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.Spline;
     series1.Legend        = "Legend1";
     series1.LegendText    = "CPU";
     series1.LegendToolTip = "使用率";
     series1.Name          = "CPU";
     series2.ChartArea     = "ChartArea1";
     series2.ChartType     = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.Spline;
     series2.Legend        = "Legend1";
     series2.LegendText    = "内存";
     series2.LegendToolTip = "使用率";
     series2.Name          = "内存";
     this.chart1.Series.Add(series1);
     this.chart1.Series.Add(series2);
     this.chart1.Size     = new System.Drawing.Size(407, 66);
     this.chart1.TabIndex = 77;
     this.chart1.Text     = "chart1";
     //
     // flowLayoutPanel1
     //
     this.flowLayoutPanel1.Controls.Add(this.outCPU占用率);
     this.flowLayoutPanel1.Controls.Add(this.out内存占用率);
     this.flowLayoutPanel1.Location = new System.Drawing.Point(58, 4);
     this.flowLayoutPanel1.Name     = "flowLayoutPanel1";
     this.flowLayoutPanel1.Size     = new System.Drawing.Size(200, 24);
     this.flowLayoutPanel1.TabIndex = 78;
     //
     // outCPU占用率
     //
     this.outCPU占用率.AutoSize  = true;
     this.outCPU占用率.ForeColor = System.Drawing.Color.Red;
     this.outCPU占用率.Location  = new System.Drawing.Point(3, 0);
     this.outCPU占用率.Name      = "outCPU占用率";
     this.outCPU占用率.Size      = new System.Drawing.Size(71, 17);
     this.outCPU占用率.TabIndex  = 81;
     this.outCPU占用率.Text      = "CPU: 100%";
     //
     // out内存占用率
     //
     this.out内存占用率.AutoSize  = true;
     this.out内存占用率.ForeColor = System.Drawing.Color.Red;
     this.out内存占用率.Location  = new System.Drawing.Point(80, 0);
     this.out内存占用率.Name      = "out内存占用率";
     this.out内存占用率.Size      = new System.Drawing.Size(71, 17);
     this.out内存占用率.TabIndex  = 80;
     this.out内存占用率.Text      = "内存: 100%";
     //
     // F资源监控
     //
     this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
     this.Controls.Add(this.flowLayoutPanel1);
     this.Controls.Add(this.chart1);
     this.Controls.Add(this.do配置);
     this.Controls.Add(this.label2);
     this.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
     this.Name = "F资源监控";
     this.Size = new System.Drawing.Size(416, 103);
     ((System.ComponentModel.ISupportInitialize)(this.chart1)).EndInit();
     this.flowLayoutPanel1.ResumeLayout(false);
     this.flowLayoutPanel1.PerformLayout();
     this.ResumeLayout(false);
     this.PerformLayout();
 }
 /// <summary>
 /// Required method for Designer support - do not modify
 /// the contents of this method with the code editor.
 /// </summary>
 private void InitializeComponent()
 {
     System.Windows.Forms.DataVisualization.Charting.PolylineAnnotation polylineAnnotation1 = new System.Windows.Forms.DataVisualization.Charting.PolylineAnnotation();
     System.Windows.Forms.DataVisualization.Charting.ChartArea          chartArea1          = new System.Windows.Forms.DataVisualization.Charting.ChartArea();
     System.Windows.Forms.DataVisualization.Charting.Legend             legend1             = new System.Windows.Forms.DataVisualization.Charting.Legend();
     System.Windows.Forms.DataVisualization.Charting.Series             series1             = new System.Windows.Forms.DataVisualization.Charting.Series();
     System.Windows.Forms.DataVisualization.Charting.Series             series2             = new System.Windows.Forms.DataVisualization.Charting.Series();
     System.Windows.Forms.DataVisualization.Charting.DataPoint          dataPoint1          = new System.Windows.Forms.DataVisualization.Charting.DataPoint(20D, 0D);
     this.backgroundWorker1 = new System.ComponentModel.BackgroundWorker();
     this.button1           = new System.Windows.Forms.Button();
     this.label2            = new System.Windows.Forms.Label();
     this.label1            = new System.Windows.Forms.Label();
     this.textBox2          = new System.Windows.Forms.TextBox();
     this.textBox1          = new System.Windows.Forms.TextBox();
     this.chart1            = new System.Windows.Forms.DataVisualization.Charting.Chart();
     ((System.ComponentModel.ISupportInitialize)(this.chart1)).BeginInit();
     this.SuspendLayout();
     //
     // button1
     //
     this.button1.Location = new System.Drawing.Point(62, 163);
     this.button1.Margin   = new System.Windows.Forms.Padding(6);
     this.button1.Name     = "button1";
     this.button1.Size     = new System.Drawing.Size(141, 44);
     this.button1.TabIndex = 11;
     this.button1.Text     = "Check";
     this.button1.UseVisualStyleBackColor = true;
     this.button1.Click += new System.EventHandler(this.Button1_Click);
     //
     // label2
     //
     this.label2.AutoSize = true;
     this.label2.Location = new System.Drawing.Point(8, 88);
     this.label2.Margin   = new System.Windows.Forms.Padding(6, 0, 6, 0);
     this.label2.Name     = "label2";
     this.label2.Size     = new System.Drawing.Size(27, 25);
     this.label2.TabIndex = 10;
     this.label2.Text     = "Y";
     //
     // label1
     //
     this.label1.AutoSize = true;
     this.label1.Location = new System.Drawing.Point(8, 38);
     this.label1.Margin   = new System.Windows.Forms.Padding(6, 0, 6, 0);
     this.label1.Name     = "label1";
     this.label1.Size     = new System.Drawing.Size(26, 25);
     this.label1.TabIndex = 9;
     this.label1.Text     = "X";
     //
     // textBox2
     //
     this.textBox2.Location = new System.Drawing.Point(62, 82);
     this.textBox2.Margin   = new System.Windows.Forms.Padding(6);
     this.textBox2.Name     = "textBox2";
     this.textBox2.Size     = new System.Drawing.Size(141, 31);
     this.textBox2.TabIndex = 8;
     //
     // textBox1
     //
     this.textBox1.Location = new System.Drawing.Point(62, 32);
     this.textBox1.Margin   = new System.Windows.Forms.Padding(6);
     this.textBox1.Name     = "textBox1";
     this.textBox1.Size     = new System.Drawing.Size(141, 31);
     this.textBox1.TabIndex = 7;
     //
     // chart1
     //
     polylineAnnotation1.AxisXName = "ChartArea1\\rX";
     polylineAnnotation1.Name      = "PolylineAnnotation1";
     this.chart1.Annotations.Add(polylineAnnotation1);
     chartArea1.AxisX.Crossing               = 0D;
     chartArea1.AxisX.Interval               = 1D;
     chartArea1.AxisX.IntervalOffset         = -5D;
     chartArea1.AxisX.IntervalOffsetType     = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number;
     chartArea1.AxisX.IntervalType           = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number;
     chartArea1.AxisX.IsMarksNextToAxis      = false;
     chartArea1.AxisX.MajorGrid.IntervalType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number;
     chartArea1.AxisX.MajorGrid.LineColor    = System.Drawing.Color.Silver;
     chartArea1.AxisX.MajorTickMark.Size     = 3F;
     chartArea1.AxisX.Maximum             = 12D;
     chartArea1.AxisX.Minimum             = -8D;
     chartArea1.AxisX2.LineDashStyle      = System.Windows.Forms.DataVisualization.Charting.ChartDashStyle.NotSet;
     chartArea1.AxisX2.LineWidth          = 0;
     chartArea1.AxisY.Crossing            = 0D;
     chartArea1.AxisY.Interval            = 1D;
     chartArea1.AxisY.IsMarksNextToAxis   = false;
     chartArea1.AxisY.MajorGrid.LineColor = System.Drawing.Color.Silver;
     chartArea1.AxisY.Maximum             = 4D;
     chartArea1.AxisY.Minimum             = -4D;
     chartArea1.AxisY.TitleAlignment      = System.Drawing.StringAlignment.Near;
     chartArea1.Name = "ChartArea1";
     this.chart1.ChartAreas.Add(chartArea1);
     legend1.Name = "Legend1";
     this.chart1.Legends.Add(legend1);
     this.chart1.Location      = new System.Drawing.Point(270, 15);
     this.chart1.Margin        = new System.Windows.Forms.Padding(6);
     this.chart1.Name          = "chart1";
     series1.BorderWidth       = 2;
     series1.ChartArea         = "ChartArea1";
     series1.ChartType         = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.Line;
     series1.Color             = System.Drawing.Color.DodgerBlue;
     series1.Legend            = "Legend1";
     series1.Name              = "Chart";
     series2.BorderColor       = System.Drawing.Color.Red;
     series2.BorderWidth       = 3;
     series2.ChartArea         = "ChartArea1";
     series2.ChartType         = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.Point;
     series2.Color             = System.Drawing.Color.Red;
     series2.Legend            = "Legend1";
     series2.MarkerBorderColor = System.Drawing.Color.Red;
     series2.MarkerBorderWidth = 5;
     series2.Name              = "Point";
     series2.Points.Add(dataPoint1);
     this.chart1.Series.Add(series1);
     this.chart1.Series.Add(series2);
     this.chart1.Size     = new System.Drawing.Size(968, 413);
     this.chart1.TabIndex = 6;
     this.chart1.Text     = "chart1";
     //
     // Form3
     //
     this.AutoScaleDimensions = new System.Drawing.SizeF(12F, 25F);
     this.AutoScaleMode       = System.Windows.Forms.AutoScaleMode.Font;
     this.ClientSize          = new System.Drawing.Size(1276, 658);
     this.Controls.Add(this.button1);
     this.Controls.Add(this.label2);
     this.Controls.Add(this.label1);
     this.Controls.Add(this.textBox2);
     this.Controls.Add(this.textBox1);
     this.Controls.Add(this.chart1);
     this.MaximumSize   = new System.Drawing.Size(1302, 729);
     this.MinimumSize   = new System.Drawing.Size(1302, 729);
     this.Name          = "Form3";
     this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
     this.Text          = "Form3";
     this.Load         += new System.EventHandler(this.Form3_Load);
     ((System.ComponentModel.ISupportInitialize)(this.chart1)).EndInit();
     this.ResumeLayout(false);
     this.PerformLayout();
 }