Browse Source

Adjust the display method of the particle list

cxs 1 month ago
parent
commit
a73164dd68

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

@@ -1579,6 +1579,11 @@
 	  <Control name="str34" text="硬度" />
 	  <Control name="str35" text="密度" />
 	  <Control name="str36" text="导电性" />
+	  <Control name="str37" text="XRay计数" />
+	  <Control name="str38" text="帧图id" />
+	  <Control name="str39" text="颗粒id" />
+	  <Control name="str19" text="帧图X轴坐标" />
+	  <Control name="str20" text="帧图Y轴坐标" />
     </Controls>
  </Form>
  <Form>

+ 1 - 1
Bin/x64/Debug/Resources/XMLData/ResourceForMeasureSourceGrid-ZH.xml

@@ -47,7 +47,7 @@
 		
 			<member itemKey="20032" itemName="" itemText="x-ray时间(毫秒)" description="输入分析x-ray时间。"/>
 			<member itemKey="20033" itemName="" itemText="扫描方式" comboContent="点扫描,面扫描,扩展扫描,子区域扫描" description="选择分析x-ray扫描方式。"/>
-			<member itemKey="20034" itemName="" itemText="期望计数" description="输入分析x-ray计数期望值。"/>
+			<member itemKey="20034" itemName="" itemText="期望计数" description="输入分析x-ray计数期望值。"/>
 			<member itemKey="20036" itemName="" itemText="分析阈值(等效圆直径/微米)" description="进行X-ray quantify 分析的最小颗粒尺寸"/>
 			<member itemKey="20037" itemName="" itemText="小颗粒x-ray时间(毫秒)" description="进行X-ray quantify 分析的最小颗粒尺寸"/>
 			<member itemKey="20038" itemName="" itemText="是否采集X-ray" comboContent="是,否" description="检测过程中是否对颗粒进行X-ray采集"/>

+ 91 - 24
OTSIncAReportApp/1-UI/Control_Grids/ParticlesGridDevidePage/ExcelExport.cs

@@ -11,11 +11,13 @@ using System.Drawing;
 using System.IO;
 using System.Linq;
 
+
 namespace OTSIncAReportGrids
 {
+    
+    
     public  class ExcelExport
     {
-
         private System.Windows.Forms.DataGridView dgV_ParticlesDevidePage;
         DataTable particlesFilter;
         ParticleData Particledata;
@@ -33,59 +35,67 @@ namespace OTSIncAReportGrids
             IWorkbook workbook = new NPOI.XSSF.UserModel.XSSFWorkbook();
             ISheet sheet = workbook.CreateSheet("Particles");
             ICellStyle cellStyle = CreateDefaultCellStyle(workbook);
-
             //设置颗粒名列宽
             sheet.SetColumnWidth(1, 30 * 256); //夹杂物名列宽
-            sheet.SetColumnWidth(2, 7 * 256);  //图像列宽
-
             //插入表头
             IRow headerRow = sheet.CreateRow(1);
             headerRow.Height = 30 * 20;
-
             for (int i = 0; i < dgV_ParticlesDevidePage.Columns.Count; i++)
             {
+                if(i < 2)
+                {
                 ICell cell = headerRow.CreateCell(i);
                 cell.CellStyle = cellStyle;
                 cell.SetCellValue(dgV_ParticlesDevidePage.Columns[i].HeaderText);
+                }
+                else if (i > 2)
+                {
+                    ICell cell = headerRow.CreateCell(i-1);
+                    cell.CellStyle = cellStyle;
+                    cell.SetCellValue(dgV_ParticlesDevidePage.Columns[i].HeaderText);
+                }
+                else if(sfd.IfExportPicture)
+                {
+                    ICell cell = headerRow.CreateCell(i);
+                    cell.CellStyle = cellStyle;
+                    cell.SetCellValue(dgV_ParticlesDevidePage.Columns[i].HeaderText);
+                    sheet.SetColumnWidth(2, 7 * 256);  //图像列宽
+                }
             }
-
             frm_userprogress?.SetProgressValueAndText(0, $"export: 0/total: {dgV_ParticlesDevidePage.Rows.Count}");
-
             ExportParticleData(workbook, sheet, cellStyle, sfd);
             ExportSpectrumData(workbook, cellStyle, sfd);
             ExportSpectrumConfirmation(workbook, cellStyle, sfd);
-
             //完成后,对Excel进行保存
             using (FileStream file = new FileStream(sfd.FileName, FileMode.Create))
             {
                 workbook.Write(file);
             }
-
             frm_userprogress?.SetProgressValueAndText(100,
                 $"export: {dgV_ParticlesDevidePage.Rows.Count}/total: {dgV_ParticlesDevidePage.Rows.Count}");
         }
-
         private ICellStyle CreateDefaultCellStyle(IWorkbook workbook)
         {
             ICellStyle cellStyle = workbook.CreateCellStyle();
             cellStyle.Alignment = HorizontalAlignment.Center;
             cellStyle.VerticalAlignment = VerticalAlignment.Center;
-
-            //设置边框
             cellStyle.BorderBottom = NPOI.SS.UserModel.BorderStyle.Thin;
             cellStyle.BorderTop = NPOI.SS.UserModel.BorderStyle.Thin;
             cellStyle.BorderLeft = NPOI.SS.UserModel.BorderStyle.Thin;
             cellStyle.BorderRight = NPOI.SS.UserModel.BorderStyle.Thin;
-
-            //设置字体
             IFont font = workbook.CreateFont();
             font.FontName = "黑体";
             font.FontHeightInPoints = 10;
             cellStyle.SetFont(font);
-
             return cellStyle;
         }
 
+        
+        
+
+
+
+
         private void ExportParticleData(IWorkbook workbook, ISheet sheet, ICellStyle cellStyle,
             OTSIncAReportApp._1_UI.Control_Grids.SpectrumExportConfirmation sfd)
         {
@@ -100,7 +110,21 @@ namespace OTSIncAReportGrids
 
                 for (int j = 0; j < dgV_ParticlesDevidePage.Columns.Count; j++)
                 {
-                    ExportCellData(workbook, sheet, patriarch, row, cellStyle, i, j, sfd);
+                    if (sfd.IfExportPicture)
+                    {
+                        ExportCellData(workbook, sheet, patriarch, row, cellStyle, i, j, sfd);
+                    }
+                    else
+                    {
+                        if(j<2)
+                        {
+                            ExportCellData(workbook, sheet, patriarch, row, cellStyle, i, j, sfd);
+                        }
+                        else if(j>2)
+                        {
+                            ExportCellData(workbook, sheet, patriarch, row, cellStyle, i, j-1, sfd);
+                        }
+                    }
                 }
             }
         }
@@ -119,21 +143,63 @@ namespace OTSIncAReportGrids
             IRow row, ICellStyle cellStyle, int rowIndex, int colIndex,
             OTSIncAReportApp._1_UI.Control_Grids.SpectrumExportConfirmation sfd)
         {
-            ICell cell = row.CreateCell(colIndex);
-            cell.CellStyle = cellStyle;
-
             if (dgV_ParticlesDevidePage[colIndex, rowIndex].Value == null) return;
-
-            if (colIndex == 2 && sfd.IfExportPicture) //图像列
+            if (sfd.IfExportPicture)
             {
-                ExportImageCell(workbook, sheet, patriarch, cell, rowIndex, colIndex);
+                if (colIndex == 2) //图像列
+                {
+                    ICell cell = row.CreateCell(colIndex);
+                    cell.CellStyle = cellStyle;
+                    ExportImageCell(workbook, sheet, patriarch, cell, rowIndex, colIndex);
+                }
+                else //非图像列
+                {
+                    ICell cell = row.CreateCell(colIndex);
+                    cell.CellStyle = cellStyle;
+                    ExportDataCell(cell, rowIndex, colIndex);
+                }
             }
-            else //非图像列
+            else
             {
-                ExportDataCell(cell, rowIndex, colIndex);
+                if (colIndex < 2) //前两列
+                {
+                    ICell cell = row.CreateCell(colIndex);
+                    cell.CellStyle = cellStyle;
+                    ExportDataCell(cell, rowIndex, colIndex);
+                }
+                else if (colIndex >= 2) //后面列
+                {
+                    ICell cell = row.CreateCell(colIndex);
+                    cell.CellStyle = cellStyle;
+                    ExportDataCell(cell, rowIndex, colIndex+1);
+                }
             }
         }
 
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
         private void ExportImageCell(IWorkbook workbook, ISheet sheet, IDrawing patriarch,
             ICell cell, int rowIndex, int colIndex)
         {
@@ -172,6 +238,7 @@ namespace OTSIncAReportGrids
             if (!sfd.IfExportSpectrumData) return;
 
             ISheet sheet = workbook.CreateSheet("Peak spectrum Data");
+            
             IRow headerRow = sheet.CreateRow(1);
             headerRow.Height = 30 * 20;
 

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

@@ -183,6 +183,11 @@ namespace OTSIncAReportGrids
 
             ReportFun = new OTSImageDisHelp(result);
 
+            
+            
+            
+            
+            
             //设置窗体的双缓冲,以保证大数据时拖动不卡
             this.SetStyle(ControlStyles.OptimizedDoubleBuffer | ControlStyles.ResizeRedraw | ControlStyles.AllPaintingInWmPaint, true);
             this.UpdateStyles();
@@ -291,14 +296,7 @@ namespace OTSIncAReportGrids
             var keyValues = new Dictionary<string, string>
             {
                 ["rowid"] = table["str4"].ToString(),
-                ["TypeName"] = table["str6"].ToString(),
-                ["ParticleImage"] = table["str5"].ToString(),
-                ["FieldId"] = "FieldId",
-                ["ParticleId"] = "ParticleId",
-
-
-                ["SEMPosX"] = "SEMPosX",
-                ["SEMPosY"] = "SEMPosY"
+                ["TypeName"] = table["str6"].ToString()
             };
 
 
@@ -306,9 +304,23 @@ namespace OTSIncAReportGrids
             {
                 switch (str)
                 {
+
+                    case "ParticleImage":
+                        keyValues["ParticleImage"] = table["str5"].ToString();
+                        break;
+                    case "FieldId":
+                        keyValues["FieldId"] = table["str38"].ToString();
+                        break;
+                    case "ParticleId":
+                        keyValues["ParticleId"] = table["str39"].ToString();
+                        break;
+                    case "FieldPos":
+                        keyValues["SEMPosX"] = table["str19"].ToString();
+                        keyValues["SEMPosY"] = table["str20"].ToString();
+                        break;
                     case "ParticleCoordinate":
-                        keyValues["AbPosX"] = "PosX";
-                        keyValues["AbPosY"] = "PosY"; break;
+                        keyValues["AbPosX"] = "颗粒X轴坐标";
+                        keyValues["AbPosY"] = "颗粒Y轴坐标"; break;
                     case "Area":
                         keyValues["Area"] = table["str21"].ToString();
                         break;
@@ -353,7 +365,7 @@ namespace OTSIncAReportGrids
                         keyValues["ORIENTATION"] = table["str33"].ToString();
                         break;
                     case "XRayDataCount":
-                        keyValues["XRayDataCount"] = "XRay计数";
+                        keyValues["XRayDataCount"] = table["str37"].ToString();
                         break;
                 }
 
@@ -1194,13 +1206,8 @@ namespace OTSIncAReportGrids
                 }
                 else
                 {
-                    Bitmap ls_bp = (Bitmap)dgvr.Cells[2].Value;
-                    List<string> list_str = (List<string>)ls_bp.Tag;
-                    if (list_str != null)
-                    {
-                        i_ls_fieldid = Convert.ToInt32(list_str[0]);
-                        i_ls_particleid = Convert.ToInt32(list_str[1]);
-                    }
+                        i_ls_fieldid = Convert.ToInt32(dgvr.Cells["particleId"].Value.ToString());
+                        i_ls_particleid = Convert.ToInt32(dgvr.Cells["fieldid"].Value.ToString());
                 }
                 foreach (Particle item in particles)
                 {
@@ -1839,8 +1846,11 @@ namespace OTSIncAReportGrids
                 if (SelectRows.Count == 1)
                 {
                     DataGridViewRow dgvr = SelectRows[0];
-                    Bitmap ls_bp = (Bitmap)dgvr.Cells[2].Value;
+                    
                     uint[] Analysis_xray = new uint[2000];
+                    
+                    
+                    
                     Particle particle = new Particle();
                     string str = " particleId= " + dgvr.Cells["particleId"].Value.ToString() + " and fieldid = " + dgvr.Cells["fieldid"].Value.ToString();
                     DataRow[] drs = particlesFilter.Select(str);

+ 83 - 22
OTSIncAReportApp/1-UI/Control_Grids/ParticlesGridDevidePage/ParticlesGridDevidePageShowConfig.Designer.cs

@@ -30,6 +30,10 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
         private void InitializeComponent()
         {
             this.groupBox2 = new System.Windows.Forms.GroupBox();
+            this.cB_fieldPos = new System.Windows.Forms.CheckBox();
+            this.cB_particleImage = new System.Windows.Forms.CheckBox();
+            this.cB_particleid = new System.Windows.Forms.CheckBox();
+            this.cB_fieldid = new System.Windows.Forms.CheckBox();
             this.btn_auto = new System.Windows.Forms.Button();
             this.cB_XRayDataCount = new System.Windows.Forms.CheckBox();
             this.label_help = new System.Windows.Forms.Label();
@@ -61,6 +65,10 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // 
             // groupBox2
             // 
+            this.groupBox2.Controls.Add(this.cB_fieldPos);
+            this.groupBox2.Controls.Add(this.cB_particleImage);
+            this.groupBox2.Controls.Add(this.cB_particleid);
+            this.groupBox2.Controls.Add(this.cB_fieldid);
             this.groupBox2.Controls.Add(this.btn_auto);
             this.groupBox2.Controls.Add(this.cB_XRayDataCount);
             this.groupBox2.Controls.Add(this.label_help);
@@ -89,15 +97,64 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             this.groupBox2.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.groupBox2.Name = "groupBox2";
             this.groupBox2.Padding = new System.Windows.Forms.Padding(2, 1, 2, 1);
-            this.groupBox2.Size = new System.Drawing.Size(514, 189);
+            this.groupBox2.Size = new System.Drawing.Size(524, 256);
             this.groupBox2.TabIndex = 130;
             this.groupBox2.TabStop = false;
             this.groupBox2.Text = "显示信息设置";
             // 
+            // cB_fieldPos
+            // 
+            this.cB_fieldPos.AutoSize = true;
+            this.cB_fieldPos.Location = new System.Drawing.Point(248, 173);
+            this.cB_fieldPos.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
+            this.cB_fieldPos.Name = "cB_fieldPos";
+            this.cB_fieldPos.Size = new System.Drawing.Size(72, 16);
+            this.cB_fieldPos.TabIndex = 138;
+            this.cB_fieldPos.Text = "帧图坐标";
+            this.cB_fieldPos.UseVisualStyleBackColor = true;
+            // 
+            // cB_particleImage
+            // 
+            this.cB_particleImage.AutoSize = true;
+            this.cB_particleImage.Enabled = false;
+            this.cB_particleImage.Location = new System.Drawing.Point(97, 172);
+            this.cB_particleImage.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
+            this.cB_particleImage.Name = "cB_particleImage";
+            this.cB_particleImage.Size = new System.Drawing.Size(84, 16);
+            this.cB_particleImage.TabIndex = 135;
+            this.cB_particleImage.Text = "颗粒缩略图";
+            this.cB_particleImage.UseVisualStyleBackColor = true;
+            // 
+            // cB_particleid
+            // 
+            this.cB_particleid.AutoSize = true;
+            this.cB_particleid.Enabled = false;
+            this.cB_particleid.Location = new System.Drawing.Point(248, 226);
+            this.cB_particleid.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
+            this.cB_particleid.Name = "cB_particleid";
+            this.cB_particleid.Size = new System.Drawing.Size(60, 16);
+            this.cB_particleid.TabIndex = 134;
+            this.cB_particleid.Text = "颗粒id";
+            this.cB_particleid.UseVisualStyleBackColor = true;
+            this.cB_particleid.Visible = false;
+            // 
+            // cB_fieldid
+            // 
+            this.cB_fieldid.AutoSize = true;
+            this.cB_fieldid.Enabled = false;
+            this.cB_fieldid.Location = new System.Drawing.Point(97, 226);
+            this.cB_fieldid.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
+            this.cB_fieldid.Name = "cB_fieldid";
+            this.cB_fieldid.Size = new System.Drawing.Size(60, 16);
+            this.cB_fieldid.TabIndex = 133;
+            this.cB_fieldid.Text = "帧图id";
+            this.cB_fieldid.UseVisualStyleBackColor = true;
+            this.cB_fieldid.Visible = false;
+            // 
             // btn_auto
             // 
             this.btn_auto.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
-            this.btn_auto.Location = new System.Drawing.Point(472, 19);
+            this.btn_auto.Location = new System.Drawing.Point(482, 19);
             this.btn_auto.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.btn_auto.Name = "btn_auto";
             this.btn_auto.Size = new System.Drawing.Size(38, 21);
@@ -109,7 +166,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cB_XRayDataCount
             // 
             this.cB_XRayDataCount.AutoSize = true;
-            this.cB_XRayDataCount.Location = new System.Drawing.Point(372, 146);
+            this.cB_XRayDataCount.Location = new System.Drawing.Point(377, 147);
             this.cB_XRayDataCount.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cB_XRayDataCount.Name = "cB_XRayDataCount";
             this.cB_XRayDataCount.Size = new System.Drawing.Size(72, 16);
@@ -140,7 +197,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cb_ParticleCoordinate
             // 
             this.cb_ParticleCoordinate.AutoSize = true;
-            this.cb_ParticleCoordinate.Location = new System.Drawing.Point(225, 146);
+            this.cb_ParticleCoordinate.Location = new System.Drawing.Point(248, 147);
             this.cb_ParticleCoordinate.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cb_ParticleCoordinate.Name = "cb_ParticleCoordinate";
             this.cb_ParticleCoordinate.Size = new System.Drawing.Size(72, 16);
@@ -151,7 +208,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // btn_xsys
             // 
             this.btn_xsys.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
-            this.btn_xsys.Location = new System.Drawing.Point(406, 19);
+            this.btn_xsys.Location = new System.Drawing.Point(416, 19);
             this.btn_xsys.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.btn_xsys.Name = "btn_xsys";
             this.btn_xsys.Size = new System.Drawing.Size(62, 21);
@@ -163,7 +220,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cB_Electrical_conductivity
             // 
             this.cB_Electrical_conductivity.AutoSize = true;
-            this.cB_Electrical_conductivity.Location = new System.Drawing.Point(97, 169);
+            this.cB_Electrical_conductivity.Location = new System.Drawing.Point(377, 172);
             this.cB_Electrical_conductivity.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cB_Electrical_conductivity.Name = "cB_Electrical_conductivity";
             this.cB_Electrical_conductivity.Size = new System.Drawing.Size(60, 16);
@@ -184,7 +241,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cB_Density
             // 
             this.cB_Density.AutoSize = true;
-            this.cB_Density.Location = new System.Drawing.Point(372, 169);
+            this.cB_Density.Location = new System.Drawing.Point(248, 199);
             this.cB_Density.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cB_Density.Name = "cB_Density";
             this.cB_Density.Size = new System.Drawing.Size(48, 16);
@@ -203,7 +260,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cB_Hardness
             // 
             this.cB_Hardness.AutoSize = true;
-            this.cB_Hardness.Location = new System.Drawing.Point(225, 169);
+            this.cB_Hardness.Location = new System.Drawing.Point(97, 199);
             this.cB_Hardness.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cB_Hardness.Name = "cB_Hardness";
             this.cB_Hardness.Size = new System.Drawing.Size(48, 16);
@@ -225,7 +282,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cb_ELONG
             // 
             this.cb_ELONG.AutoSize = true;
-            this.cb_ELONG.Location = new System.Drawing.Point(372, 74);
+            this.cb_ELONG.Location = new System.Drawing.Point(377, 74);
             this.cb_ELONG.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cb_ELONG.Name = "cb_ELONG";
             this.cb_ELONG.Size = new System.Drawing.Size(84, 16);
@@ -247,7 +304,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cb_PERI
             // 
             this.cb_PERI.AutoSize = true;
-            this.cb_PERI.Location = new System.Drawing.Point(225, 98);
+            this.cb_PERI.Location = new System.Drawing.Point(248, 98);
             this.cb_PERI.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cb_PERI.Name = "cb_PERI";
             this.cb_PERI.Size = new System.Drawing.Size(60, 16);
@@ -258,7 +315,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cb_MinDiameter
             // 
             this.cb_MinDiameter.AutoSize = true;
-            this.cb_MinDiameter.Location = new System.Drawing.Point(225, 50);
+            this.cb_MinDiameter.Location = new System.Drawing.Point(248, 50);
             this.cb_MinDiameter.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cb_MinDiameter.Name = "cb_MinDiameter";
             this.cb_MinDiameter.Size = new System.Drawing.Size(84, 16);
@@ -291,7 +348,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cb_ASPECT_ELONG
             // 
             this.cb_ASPECT_ELONG.AutoSize = true;
-            this.cb_ASPECT_ELONG.Location = new System.Drawing.Point(372, 123);
+            this.cb_ASPECT_ELONG.Location = new System.Drawing.Point(377, 123);
             this.cb_ASPECT_ELONG.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cb_ASPECT_ELONG.Name = "cb_ASPECT_ELONG";
             this.cb_ASPECT_ELONG.Size = new System.Drawing.Size(84, 16);
@@ -302,7 +359,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cb_FerretDiameter
             // 
             this.cb_FerretDiameter.AutoSize = true;
-            this.cb_FerretDiameter.Location = new System.Drawing.Point(225, 74);
+            this.cb_FerretDiameter.Location = new System.Drawing.Point(248, 74);
             this.cb_FerretDiameter.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cb_FerretDiameter.Name = "cb_FerretDiameter";
             this.cb_FerretDiameter.Size = new System.Drawing.Size(96, 16);
@@ -313,7 +370,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cb_Orientation
             // 
             this.cb_Orientation.AutoSize = true;
-            this.cb_Orientation.Location = new System.Drawing.Point(225, 122);
+            this.cb_Orientation.Location = new System.Drawing.Point(248, 122);
             this.cb_Orientation.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cb_Orientation.Name = "cb_Orientation";
             this.cb_Orientation.Size = new System.Drawing.Size(84, 16);
@@ -324,7 +381,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cb_PERP
             // 
             this.cb_PERP.AutoSize = true;
-            this.cb_PERP.Location = new System.Drawing.Point(372, 50);
+            this.cb_PERP.Location = new System.Drawing.Point(377, 50);
             this.cb_PERP.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cb_PERP.Name = "cb_PERP";
             this.cb_PERP.Size = new System.Drawing.Size(84, 16);
@@ -335,7 +392,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cb_MEAN
             // 
             this.cb_MEAN.AutoSize = true;
-            this.cb_MEAN.Location = new System.Drawing.Point(97, 146);
+            this.cb_MEAN.Location = new System.Drawing.Point(97, 147);
             this.cb_MEAN.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cb_MEAN.Name = "cb_MEAN";
             this.cb_MEAN.Size = new System.Drawing.Size(108, 16);
@@ -346,7 +403,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // cb_INSCR
             // 
             this.cb_INSCR.AutoSize = true;
-            this.cb_INSCR.Location = new System.Drawing.Point(372, 98);
+            this.cb_INSCR.Location = new System.Drawing.Point(377, 98);
             this.cb_INSCR.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.cb_INSCR.Name = "cb_INSCR";
             this.cb_INSCR.Size = new System.Drawing.Size(96, 16);
@@ -356,7 +413,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // 
             // btn_ybcsqx
             // 
-            this.btn_ybcsqx.Location = new System.Drawing.Point(457, 201);
+            this.btn_ybcsqx.Location = new System.Drawing.Point(464, 268);
             this.btn_ybcsqx.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.btn_ybcsqx.Name = "btn_ybcsqx";
             this.btn_ybcsqx.Size = new System.Drawing.Size(67, 23);
@@ -367,7 +424,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // 
             // btn_ybcsbc
             // 
-            this.btn_ybcsbc.Location = new System.Drawing.Point(386, 201);
+            this.btn_ybcsbc.Location = new System.Drawing.Point(393, 268);
             this.btn_ybcsbc.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.btn_ybcsbc.Name = "btn_ybcsbc";
             this.btn_ybcsbc.Size = new System.Drawing.Size(67, 23);
@@ -380,13 +437,13 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
-            this.ClientSize = new System.Drawing.Size(536, 225);
+            this.ClientSize = new System.Drawing.Size(546, 292);
             this.Controls.Add(this.btn_ybcsqx);
             this.Controls.Add(this.btn_ybcsbc);
             this.Controls.Add(this.groupBox2);
             this.MaximizeBox = false;
-            this.MaximumSize = new System.Drawing.Size(552, 264);
-            this.MinimumSize = new System.Drawing.Size(552, 264);
+            this.MaximumSize = new System.Drawing.Size(562, 331);
+            this.MinimumSize = new System.Drawing.Size(562, 331);
             this.Name = "ParticlesGridDevidePageShowConfig";
             this.ShowIcon = false;
             this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
@@ -427,5 +484,9 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
         private System.Windows.Forms.Label label_help;
         private System.Windows.Forms.CheckBox cB_XRayDataCount;
         private System.Windows.Forms.Button btn_auto;
+        private System.Windows.Forms.CheckBox cB_fieldPos;
+        private System.Windows.Forms.CheckBox cB_particleImage;
+        private System.Windows.Forms.CheckBox cB_particleid;
+        private System.Windows.Forms.CheckBox cB_fieldid;
     }
 }

+ 51 - 24
OTSIncAReportApp/1-UI/Control_Grids/ParticlesGridDevidePage/ParticlesGridDevidePageShowConfig.cs

@@ -128,18 +128,35 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
         {
             string str_ret = "";
 
+
+            if (cB_particleImage.Checked == true)
+            {
+                str_ret = str_ret + "ParticleImage" + ",";
+            }
+            if (cB_fieldid.Checked == true)
+            {
+                str_ret = str_ret + "FieldId" + ",";
+            }
+            if (cB_particleid.Checked == true)
+            {
+                str_ret = str_ret + "ParticleId" + ",";
+            }
+            if (cB_fieldPos.Checked == true)
+            {
+                str_ret = str_ret + "FieldPos" + ",";
+            }
+
+
             //帧图坐标
             if (cb_ParticleCoordinate.Checked == true)
             {
                 str_ret = str_ret + "ParticleCoordinate" + ",";
             }
-
             //面积
             if (cb_Area.Checked == true)
             {
                 str_ret = str_ret + "Area" + ",";
             }
-
             //等效圆直径
             if (cb_EquivalentCircleDiameter.Checked == true)
             {
@@ -151,19 +168,16 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             {
                 str_ret = str_ret + "MaxDiameter" + ",";
             }
-
             //最短直径
             if (cb_MinDiameter.Checked == true)
             {
                 str_ret = str_ret + "MinDiameter" + ",";
             }
-
             //长短直径比
             if (cb_DiameterRatio.Checked == true)
             {
                 str_ret = str_ret + "DiameterRatio" + ",";
             }
-
             //费雷特直径
             if (cb_FerretDiameter.Checked == true)
             {
@@ -171,6 +185,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
             }
 
 
+            
             //正交直径
             if (cb_PERP.Checked == true)
             {
@@ -234,6 +249,7 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
                 str_ret = str_ret + "XRayDataCount" + ",";
             }
 
+
             if (str_ret.Length > 0)
             {
                 str_ret = str_ret.Substring(0, str_ret.Length - 1);
@@ -395,24 +411,13 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
 
         private void SetShowColumnsListStr(string in_str)
         {
-            cb_Area.Checked = false;
-            cb_EquivalentCircleDiameter.Checked = false;
-            cb_MaxDiameter.Checked = false;
-            cb_MinDiameter.Checked = false;
-            cb_DiameterRatio.Checked = false;
-            cb_FerretDiameter.Checked = false;
-            cb_PERP.Checked = false;
-            cb_PERI.Checked = false;
-            cb_INSCR.Checked = false;
-            cb_MEAN.Checked = false;
-            cb_ELONG.Checked = false;
-            cb_ASPECT_ELONG.Checked = false;
-            cb_Orientation.Checked = false;
-            cb_ParticleCoordinate.Checked = false;
-            cB_Hardness.Checked = false;
-            cB_Density.Checked = false;
-            cB_Electrical_conductivity.Checked = false;
-
+            foreach(Control control in groupBox2.Controls)
+            {
+                if (control is CheckBox)
+                {
+                    (control as CheckBox).Checked = false;
+                }
+            }
 
             //面积
             if (in_str.IndexOf("Area") > -1)
@@ -492,17 +497,39 @@ namespace OTSIncAReportApp._1_UI.Control_Grids.ParticlesGridDevidePage
                 cb_Orientation.Checked = true;
             }
 
+
+
+
+
+
+
             //帧图坐标
             if (in_str.IndexOf("ParticleCoordinate") > -1)
             {
                 cb_ParticleCoordinate.Checked = true;
             }
-
             if (in_str.IndexOf("XRayDataCount") > -1)
             {
                 cB_XRayDataCount.Checked = true;
             }
 
+            if (in_str.IndexOf("ParticleImage") > -1)
+            {
+                cB_particleImage.Checked = true;
+            }
+            if (in_str.IndexOf("FieldId") > -1)
+            {
+                cB_fieldid.Checked = true;
+            }
+            if (in_str.IndexOf("ParticleId") > -1)
+            {
+                cB_particleid.Checked = true;
+            }
+
+            if (in_str.IndexOf("FieldPos") > -1)
+            {
+                cB_fieldPos.Checked = true;
+            }
             if (systype == OTS_SysType_ID.TCCleannessA|| systype == OTS_SysType_ID.BatteryCleannessA)
             {
                 cB_Hardness.Enabled = true;