Browse Source

Merge branch 'Release2.3' of http://36.129.163.148:10080/gaoshipeng/OTS2_0 into Release2.3

zhangjiaxin 3 years ago
parent
commit
da7ad520a2

+ 23 - 0
Bin/x64/Debug/Resources/XMLData/AppResource_ZH.xml

@@ -1589,4 +1589,27 @@
 	  <Control name="str17" text="最大" />
     </Controls>
  </Form>
+ <Form>
+    <Name>SlopFocus</Name>
+    <Controls>
+	  <Control name="SlopFocus" text="是否启用" />
+      <Control name="cB_enable" text="是否启用" />
+	  <Control name="groupBox1" text="第一点" />
+	  <Control name="label8" text="工作距离" />
+	  <Control name="bn_FirstPoint" text="获取" />
+	  <Control name="groupBox2" text="第二点" />
+	  <Control name="label6" text="工作距离" />
+	  <Control name="bn_SecondPoint" text="获取" />
+	  <Control name="groupBox3" text="第三点" />
+	  <Control name="label1" text="工作距离" />
+	  <Control name="bn_ThirdPoint" text="获取" />
+	  <Control name="bn_Cancel" text="取消" />
+	  <Control name="bn_OK" text="确定" />
+	  <Control name="str13" text="元素号" />
+	  <Control name="str14" text="原子数" />
+	  <Control name="str15" text="规则" />
+	  <Control name="str16" text="最小" />
+	  <Control name="str17" text="最大" />
+    </Controls>
+ </Form>
 </Resource>

+ 68 - 89
OTSIncAMeasureApp/5-OTSMeasureStatuImageFun/SlopFocus.Designer.cs

@@ -64,10 +64,9 @@ namespace OTSMeasureApp._5_OTSMeasureStatuImageFun
             // cB_enable
             // 
             this.cB_enable.AutoSize = true;
-            this.cB_enable.Location = new System.Drawing.Point(11, 13);
-            this.cB_enable.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.cB_enable.Location = new System.Drawing.Point(15, 15);
             this.cB_enable.Name = "cB_enable";
-            this.cB_enable.Size = new System.Drawing.Size(114, 17);
+            this.cB_enable.Size = new System.Drawing.Size(165, 19);
             this.cB_enable.TabIndex = 0;
             this.cB_enable.Text = "Whether to enable";
             this.cB_enable.UseVisualStyleBackColor = true;
@@ -75,45 +74,42 @@ namespace OTSMeasureApp._5_OTSMeasureStatuImageFun
             // label2
             // 
             this.label2.AutoSize = true;
-            this.label2.Location = new System.Drawing.Point(24, 35);
-            this.label2.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+            this.label2.Location = new System.Drawing.Point(32, 40);
             this.label2.Name = "label2";
-            this.label2.Size = new System.Drawing.Size(17, 13);
+            this.label2.Size = new System.Drawing.Size(23, 15);
             this.label2.TabIndex = 2;
             this.label2.Text = "X:";
             // 
             // tB_FirstPointX
             // 
-            this.tB_FirstPointX.Location = new System.Drawing.Point(51, 32);
-            this.tB_FirstPointX.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.tB_FirstPointX.Location = new System.Drawing.Point(68, 37);
             this.tB_FirstPointX.Name = "tB_FirstPointX";
-            this.tB_FirstPointX.Size = new System.Drawing.Size(76, 20);
+            this.tB_FirstPointX.ReadOnly = true;
+            this.tB_FirstPointX.Size = new System.Drawing.Size(100, 25);
             this.tB_FirstPointX.TabIndex = 3;
             // 
             // label3
             // 
             this.label3.AutoSize = true;
-            this.label3.Location = new System.Drawing.Point(147, 35);
-            this.label3.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+            this.label3.Location = new System.Drawing.Point(196, 40);
             this.label3.Name = "label3";
-            this.label3.Size = new System.Drawing.Size(17, 13);
+            this.label3.Size = new System.Drawing.Size(23, 15);
             this.label3.TabIndex = 4;
             this.label3.Text = "Y:";
             // 
             // tB_FirstPointY
             // 
-            this.tB_FirstPointY.Location = new System.Drawing.Point(174, 32);
-            this.tB_FirstPointY.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.tB_FirstPointY.Location = new System.Drawing.Point(232, 37);
             this.tB_FirstPointY.Name = "tB_FirstPointY";
-            this.tB_FirstPointY.Size = new System.Drawing.Size(76, 20);
+            this.tB_FirstPointY.ReadOnly = true;
+            this.tB_FirstPointY.Size = new System.Drawing.Size(100, 25);
             this.tB_FirstPointY.TabIndex = 5;
             // 
             // bn_FirstPoint
             // 
-            this.bn_FirstPoint.Location = new System.Drawing.Point(485, 32);
-            this.bn_FirstPoint.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.bn_FirstPoint.Location = new System.Drawing.Point(647, 37);
             this.bn_FirstPoint.Name = "bn_FirstPoint";
-            this.bn_FirstPoint.Size = new System.Drawing.Size(72, 22);
+            this.bn_FirstPoint.Size = new System.Drawing.Size(96, 25);
             this.bn_FirstPoint.TabIndex = 6;
             this.bn_FirstPoint.Text = "obtain";
             this.bn_FirstPoint.UseVisualStyleBackColor = true;
@@ -121,10 +117,9 @@ namespace OTSMeasureApp._5_OTSMeasureStatuImageFun
             // 
             // bn_SecondPoint
             // 
-            this.bn_SecondPoint.Location = new System.Drawing.Point(485, 30);
-            this.bn_SecondPoint.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.bn_SecondPoint.Location = new System.Drawing.Point(647, 35);
             this.bn_SecondPoint.Name = "bn_SecondPoint";
-            this.bn_SecondPoint.Size = new System.Drawing.Size(72, 22);
+            this.bn_SecondPoint.Size = new System.Drawing.Size(96, 25);
             this.bn_SecondPoint.TabIndex = 12;
             this.bn_SecondPoint.Text = "obtain";
             this.bn_SecondPoint.UseVisualStyleBackColor = true;
@@ -132,46 +127,43 @@ namespace OTSMeasureApp._5_OTSMeasureStatuImageFun
             // 
             // tB_SecondPointY
             // 
-            this.tB_SecondPointY.Location = new System.Drawing.Point(174, 33);
-            this.tB_SecondPointY.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.tB_SecondPointY.Location = new System.Drawing.Point(232, 38);
             this.tB_SecondPointY.Name = "tB_SecondPointY";
-            this.tB_SecondPointY.Size = new System.Drawing.Size(76, 20);
+            this.tB_SecondPointY.ReadOnly = true;
+            this.tB_SecondPointY.Size = new System.Drawing.Size(100, 25);
             this.tB_SecondPointY.TabIndex = 11;
             // 
             // label4
             // 
             this.label4.AutoSize = true;
-            this.label4.Location = new System.Drawing.Point(147, 36);
-            this.label4.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+            this.label4.Location = new System.Drawing.Point(196, 42);
             this.label4.Name = "label4";
-            this.label4.Size = new System.Drawing.Size(17, 13);
+            this.label4.Size = new System.Drawing.Size(23, 15);
             this.label4.TabIndex = 10;
             this.label4.Text = "Y:";
             // 
             // tB_SecondPointX
             // 
-            this.tB_SecondPointX.Location = new System.Drawing.Point(51, 33);
-            this.tB_SecondPointX.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.tB_SecondPointX.Location = new System.Drawing.Point(68, 38);
             this.tB_SecondPointX.Name = "tB_SecondPointX";
-            this.tB_SecondPointX.Size = new System.Drawing.Size(76, 20);
+            this.tB_SecondPointX.ReadOnly = true;
+            this.tB_SecondPointX.Size = new System.Drawing.Size(100, 25);
             this.tB_SecondPointX.TabIndex = 9;
             // 
             // label5
             // 
             this.label5.AutoSize = true;
-            this.label5.Location = new System.Drawing.Point(24, 36);
-            this.label5.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+            this.label5.Location = new System.Drawing.Point(32, 42);
             this.label5.Name = "label5";
-            this.label5.Size = new System.Drawing.Size(17, 13);
+            this.label5.Size = new System.Drawing.Size(23, 15);
             this.label5.TabIndex = 8;
             this.label5.Text = "X:";
             // 
             // bn_ThirdPoint
             // 
-            this.bn_ThirdPoint.Location = new System.Drawing.Point(485, 32);
-            this.bn_ThirdPoint.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.bn_ThirdPoint.Location = new System.Drawing.Point(647, 37);
             this.bn_ThirdPoint.Name = "bn_ThirdPoint";
-            this.bn_ThirdPoint.Size = new System.Drawing.Size(72, 22);
+            this.bn_ThirdPoint.Size = new System.Drawing.Size(96, 25);
             this.bn_ThirdPoint.TabIndex = 18;
             this.bn_ThirdPoint.Text = "obtain";
             this.bn_ThirdPoint.UseVisualStyleBackColor = true;
@@ -179,37 +171,35 @@ namespace OTSMeasureApp._5_OTSMeasureStatuImageFun
             // 
             // tB_ThirdPointY
             // 
-            this.tB_ThirdPointY.Location = new System.Drawing.Point(174, 29);
-            this.tB_ThirdPointY.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.tB_ThirdPointY.Location = new System.Drawing.Point(232, 37);
             this.tB_ThirdPointY.Name = "tB_ThirdPointY";
-            this.tB_ThirdPointY.Size = new System.Drawing.Size(76, 20);
+            this.tB_ThirdPointY.ReadOnly = true;
+            this.tB_ThirdPointY.Size = new System.Drawing.Size(100, 25);
             this.tB_ThirdPointY.TabIndex = 17;
             // 
             // label7
             // 
             this.label7.AutoSize = true;
-            this.label7.Location = new System.Drawing.Point(147, 35);
-            this.label7.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+            this.label7.Location = new System.Drawing.Point(196, 40);
             this.label7.Name = "label7";
-            this.label7.Size = new System.Drawing.Size(17, 13);
+            this.label7.Size = new System.Drawing.Size(23, 15);
             this.label7.TabIndex = 16;
             this.label7.Text = "Y:";
             // 
             // tB_ThirdPointX
             // 
-            this.tB_ThirdPointX.Location = new System.Drawing.Point(51, 32);
-            this.tB_ThirdPointX.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.tB_ThirdPointX.Location = new System.Drawing.Point(68, 37);
             this.tB_ThirdPointX.Name = "tB_ThirdPointX";
-            this.tB_ThirdPointX.Size = new System.Drawing.Size(76, 20);
+            this.tB_ThirdPointX.ReadOnly = true;
+            this.tB_ThirdPointX.Size = new System.Drawing.Size(100, 25);
             this.tB_ThirdPointX.TabIndex = 15;
             // 
             // label9
             // 
             this.label9.AutoSize = true;
-            this.label9.Location = new System.Drawing.Point(24, 35);
-            this.label9.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+            this.label9.Location = new System.Drawing.Point(32, 40);
             this.label9.Name = "label9";
-            this.label9.Size = new System.Drawing.Size(17, 13);
+            this.label9.Size = new System.Drawing.Size(23, 15);
             this.label9.TabIndex = 13;
             this.label9.Text = "X:";
             // 
@@ -222,30 +212,27 @@ namespace OTSMeasureApp._5_OTSMeasureStatuImageFun
             this.groupBox1.Controls.Add(this.tB_FirstPointX);
             this.groupBox1.Controls.Add(this.label3);
             this.groupBox1.Controls.Add(this.tB_FirstPointY);
-            this.groupBox1.Location = new System.Drawing.Point(11, 51);
-            this.groupBox1.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.groupBox1.Location = new System.Drawing.Point(15, 59);
             this.groupBox1.Name = "groupBox1";
-            this.groupBox1.Padding = new System.Windows.Forms.Padding(2, 3, 2, 3);
-            this.groupBox1.Size = new System.Drawing.Size(562, 77);
+            this.groupBox1.Size = new System.Drawing.Size(749, 89);
             this.groupBox1.TabIndex = 19;
             this.groupBox1.TabStop = false;
             this.groupBox1.Text = "FirstPoint";
             // 
             // tB_FirstPointD
             // 
-            this.tB_FirstPointD.Location = new System.Drawing.Point(378, 32);
-            this.tB_FirstPointD.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.tB_FirstPointD.Location = new System.Drawing.Point(504, 37);
             this.tB_FirstPointD.Name = "tB_FirstPointD";
-            this.tB_FirstPointD.Size = new System.Drawing.Size(83, 20);
+            this.tB_FirstPointD.ReadOnly = true;
+            this.tB_FirstPointD.Size = new System.Drawing.Size(109, 25);
             this.tB_FirstPointD.TabIndex = 8;
             // 
             // label8
             // 
             this.label8.AutoSize = true;
-            this.label8.Location = new System.Drawing.Point(301, 35);
-            this.label8.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+            this.label8.Location = new System.Drawing.Point(401, 40);
             this.label8.Name = "label8";
-            this.label8.Size = new System.Drawing.Size(52, 13);
+            this.label8.Size = new System.Drawing.Size(79, 15);
             this.label8.TabIndex = 7;
             this.label8.Text = "Distance:";
             // 
@@ -258,30 +245,27 @@ namespace OTSMeasureApp._5_OTSMeasureStatuImageFun
             this.groupBox2.Controls.Add(this.tB_SecondPointX);
             this.groupBox2.Controls.Add(this.label4);
             this.groupBox2.Controls.Add(this.bn_SecondPoint);
-            this.groupBox2.Location = new System.Drawing.Point(11, 157);
-            this.groupBox2.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.groupBox2.Location = new System.Drawing.Point(15, 181);
             this.groupBox2.Name = "groupBox2";
-            this.groupBox2.Padding = new System.Windows.Forms.Padding(2, 3, 2, 3);
-            this.groupBox2.Size = new System.Drawing.Size(562, 82);
+            this.groupBox2.Size = new System.Drawing.Size(749, 95);
             this.groupBox2.TabIndex = 7;
             this.groupBox2.TabStop = false;
             this.groupBox2.Text = "SecondPoint";
             // 
             // tB_SecondPointD
             // 
-            this.tB_SecondPointD.Location = new System.Drawing.Point(378, 33);
-            this.tB_SecondPointD.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.tB_SecondPointD.Location = new System.Drawing.Point(504, 38);
             this.tB_SecondPointD.Name = "tB_SecondPointD";
-            this.tB_SecondPointD.Size = new System.Drawing.Size(76, 20);
+            this.tB_SecondPointD.ReadOnly = true;
+            this.tB_SecondPointD.Size = new System.Drawing.Size(100, 25);
             this.tB_SecondPointD.TabIndex = 23;
             // 
             // label6
             // 
             this.label6.AutoSize = true;
-            this.label6.Location = new System.Drawing.Point(301, 36);
-            this.label6.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+            this.label6.Location = new System.Drawing.Point(401, 42);
             this.label6.Name = "label6";
-            this.label6.Size = new System.Drawing.Size(52, 13);
+            this.label6.Size = new System.Drawing.Size(79, 15);
             this.label6.TabIndex = 22;
             this.label6.Text = "Distance:";
             // 
@@ -294,39 +278,35 @@ namespace OTSMeasureApp._5_OTSMeasureStatuImageFun
             this.groupBox3.Controls.Add(this.tB_ThirdPointX);
             this.groupBox3.Controls.Add(this.tB_ThirdPointY);
             this.groupBox3.Controls.Add(this.label7);
-            this.groupBox3.Location = new System.Drawing.Point(11, 270);
-            this.groupBox3.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.groupBox3.Location = new System.Drawing.Point(15, 312);
             this.groupBox3.Name = "groupBox3";
-            this.groupBox3.Padding = new System.Windows.Forms.Padding(2, 3, 2, 3);
-            this.groupBox3.Size = new System.Drawing.Size(562, 81);
+            this.groupBox3.Size = new System.Drawing.Size(749, 93);
             this.groupBox3.TabIndex = 13;
             this.groupBox3.TabStop = false;
             this.groupBox3.Text = "ThirdPoint";
             // 
             // tB_ThirdPointD
             // 
-            this.tB_ThirdPointD.Location = new System.Drawing.Point(378, 32);
-            this.tB_ThirdPointD.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.tB_ThirdPointD.Location = new System.Drawing.Point(504, 37);
             this.tB_ThirdPointD.Name = "tB_ThirdPointD";
-            this.tB_ThirdPointD.Size = new System.Drawing.Size(76, 20);
+            this.tB_ThirdPointD.ReadOnly = true;
+            this.tB_ThirdPointD.Size = new System.Drawing.Size(100, 25);
             this.tB_ThirdPointD.TabIndex = 22;
             // 
             // label1
             // 
             this.label1.AutoSize = true;
-            this.label1.Location = new System.Drawing.Point(301, 35);
-            this.label1.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+            this.label1.Location = new System.Drawing.Point(401, 40);
             this.label1.Name = "label1";
-            this.label1.Size = new System.Drawing.Size(63, 13);
+            this.label1.Size = new System.Drawing.Size(86, 15);
             this.label1.TabIndex = 21;
             this.label1.Text = "DiStance:";
             // 
             // bn_OK
             // 
-            this.bn_OK.Location = new System.Drawing.Point(500, 371);
-            this.bn_OK.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.bn_OK.Location = new System.Drawing.Point(667, 428);
             this.bn_OK.Name = "bn_OK";
-            this.bn_OK.Size = new System.Drawing.Size(73, 28);
+            this.bn_OK.Size = new System.Drawing.Size(97, 32);
             this.bn_OK.TabIndex = 20;
             this.bn_OK.Text = "OK";
             this.bn_OK.UseVisualStyleBackColor = true;
@@ -334,10 +314,9 @@ namespace OTSMeasureApp._5_OTSMeasureStatuImageFun
             // 
             // bn_Cancel
             // 
-            this.bn_Cancel.Location = new System.Drawing.Point(403, 371);
-            this.bn_Cancel.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
+            this.bn_Cancel.Location = new System.Drawing.Point(537, 428);
             this.bn_Cancel.Name = "bn_Cancel";
-            this.bn_Cancel.Size = new System.Drawing.Size(68, 28);
+            this.bn_Cancel.Size = new System.Drawing.Size(91, 32);
             this.bn_Cancel.TabIndex = 21;
             this.bn_Cancel.Text = "Cancel";
             this.bn_Cancel.UseVisualStyleBackColor = true;
@@ -345,22 +324,22 @@ namespace OTSMeasureApp._5_OTSMeasureStatuImageFun
             // 
             // SlopFocus
             // 
-            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
+            this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
-            this.ClientSize = new System.Drawing.Size(581, 425);
+            this.ClientSize = new System.Drawing.Size(772, 481);
             this.Controls.Add(this.bn_Cancel);
             this.Controls.Add(this.bn_OK);
             this.Controls.Add(this.groupBox3);
             this.Controls.Add(this.groupBox2);
             this.Controls.Add(this.groupBox1);
             this.Controls.Add(this.cB_enable);
-            this.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
             this.MaximizeBox = false;
-            this.MaximumSize = new System.Drawing.Size(597, 464);
-            this.MinimumSize = new System.Drawing.Size(597, 464);
+            this.MaximumSize = new System.Drawing.Size(790, 528);
+            this.MinimumSize = new System.Drawing.Size(790, 528);
             this.Name = "SlopFocus";
             this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
             this.Text = "SlopFocus";
+            this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.SlopFocus_FormClosing);
             this.Load += new System.EventHandler(this.SlopFocus_Load);
             this.groupBox1.ResumeLayout(false);
             this.groupBox1.PerformLayout();

+ 14 - 0
OTSIncAMeasureApp/5-OTSMeasureStatuImageFun/SlopFocus.cs

@@ -2,6 +2,7 @@
 using OTSDataType;
 using OTSMeasureApp._0_OTSModel.OTSDataType;
 using System;
+using System.Collections;
 using System.Collections.Generic;
 using System.ComponentModel;
 using System.Data;
@@ -20,10 +21,17 @@ namespace OTSMeasureApp._5_OTSMeasureStatuImageFun
         bool m_result=false;
         OTSSamplespaceWindow oTSSamplespaceWindow;
         public bool result {get => m_result; set => m_result = value; }
+        //国际化
+        OTSSysMgrTools.Language lan;
+        Hashtable table;
+
         public SlopFocus(OTSSamplespaceWindow a_oTSSamplespaceWindow)
         {
             InitializeComponent();
             oTSSamplespaceWindow = a_oTSSamplespaceWindow;
+            //国际化
+            lan = new OTSSysMgrTools.Language(this);
+            table = lan.GetNameTable(this.Name);
         }
         public CSlopFocusParam GetCSlopFocusParam()
         {
@@ -142,5 +150,11 @@ namespace OTSMeasureApp._5_OTSMeasureStatuImageFun
             m_result = false;
             this.Hide();
         }
+
+        private void SlopFocus_FormClosing(object sender, FormClosingEventArgs e)
+        {
+            e.Cancel = true;
+            this.Hide();
+        }
     }
 }

+ 1 - 1
OTSIncAReportApp/1-UI/Control_Grids/ParticlesGridDevidePage.cs

@@ -658,7 +658,7 @@ namespace OTSIncAReportGrids
                                 double xs = pixw / ScanFieldSize;
 
                                 particleM = particleM + "," + subt;
-                                Bitmap bmap = Particledata.GetBitmapForBig(subt, xs, result.FilePath);
+                                Bitmap bmap = Particledata.GetBitmapForBig(subt, xs, result.FilePath, tempbit.Height, tempbit.Width);
                                 if (bmap != null)
                                 {
                                     string[] str = subt.Split(',');

+ 2 - 2
OTSIncAReportApp/1-UI/OTSTemplateDesigner/Export_ReportTemplate.cs

@@ -383,7 +383,7 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
                         Bitmap tempbit = fielddata.ReadImageFile(str_imagePath);
                         int pixw = tempbit.Width;
                         double xs = pixw / ScanFieldSize;
-                        bp_particle = fielddata.GetBitmapForBig(str_subparticles, xs, str_resultPath);
+                        bp_particle = fielddata.GetBitmapForBig(str_subparticles, xs, str_resultPath, tempbit.Height, tempbit.Width);
                     }
                     else
                     {
@@ -753,7 +753,7 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
                         Bitmap tempbit = fielddata.ReadImageFile(str_imagePath);
                         int pixw = tempbit.Width;
                         double xs = pixw / ScanFieldSize;
-                        bp_particle = fielddata.GetBitmapForBig(str_subparticles, xs, str_resultPath);
+                        bp_particle = fielddata.GetBitmapForBig(str_subparticles, xs, str_resultPath, tempbit.Height, tempbit.Width);
                     }
                     else
                     {

+ 3 - 3
OTSIncAReportApp/3-ServiceCenter/DataOperation/DataAccess/ParticleData.cs

@@ -457,7 +457,7 @@ namespace OTSIncAReportApp.DataOperation.DataAccess
             return DT;
         }
 
-        public Bitmap GetBitmapForBig(string sub, double xs, string path)
+        public Bitmap GetBitmapForBig(string sub, double xs, string path,int picHeight,int picWidth)
         {
             string vs = "," + sub.Replace(':', '-') + ",";
 
@@ -519,8 +519,8 @@ namespace OTSIncAReportApp.DataOperation.DataAccess
                     MIN_Y = lrfttopYH;
                 }
             }
-            int WIDTH = Convert.ToInt32(MAX_X - MIN_X) + 1024;
-            int HEIGHT = Convert.ToInt32(MAX_Y - MIN_Y) + 768;
+            int WIDTH = Convert.ToInt32(MAX_X - MIN_X) + picWidth;
+            int HEIGHT = Convert.ToInt32(MAX_Y - MIN_Y) + picHeight;
             //构造最终的图片白板
             Bitmap tableChartImage = new Bitmap(WIDTH, HEIGHT);
             Graphics graph = Graphics.FromImage(tableChartImage);