diff --git a/src/PBAnaly/Module/BioanalysisMannage.cs b/src/PBAnaly/Module/BioanalysisMannage.cs index 176eff8..ddd5bc5 100644 --- a/src/PBAnaly/Module/BioanalysisMannage.cs +++ b/src/PBAnaly/Module/BioanalysisMannage.cs @@ -1,22 +1,12 @@ -using AntdUI; -using Aspose.Pdf; -using Aspose.Pdf.AI; -using Aspose.Pdf.Drawing; -using MetroFramework.Drawing.Html; -using OpenCvSharp.Flann; +using MiniExcelLibs; using PBAnaly.UI; using PBBiologyVC; -using ScottPlot.Panels; -using ScottPlot.Plottables; using SixLabors.ImageSharp; using SixLabors.ImageSharp.PixelFormats; using System; -using System.Collections; using System.Collections.Generic; using System.Drawing; using System.IO; -using System.Net; -using System.Runtime.ConstrainedExecution; using System.Threading; using System.Windows.Forms; @@ -60,6 +50,11 @@ namespace PBAnaly.Module public System.Drawing.Point Radius { get; set; } public Pseudo_infoVC pdinfovc; } + private struct PolygonAndInfo + { + public List points; + public Pseudo_infoVC pdinfovc; + } #endregion #region 变量 private Dictionary bioanalysisMannages; @@ -102,6 +97,7 @@ namespace PBAnaly.Module private bool CircleOn = false; private bool rectOn = false; + private bool linepolygonON = false; private bool isRecDragging = false; private List rectangles = new List(); // 存储所有绘制完成的矩形 private System.Drawing.Rectangle? currentRectangle = null; // 当前正在绘制的矩形 @@ -121,6 +117,12 @@ namespace PBAnaly.Module private int cirDragStartIndex = -1; private CirceAndInfo cireOriginalCire; + private bool drawpolygon = false; + private List PolygonAndInfoList = new List(); + private PolygonAndInfo curPolygonAndInfoList = new PolygonAndInfo(); + private System.Drawing.Point curStartPolygonPoint = new System.Drawing.Point(0, 0); + private System.Drawing.Point curPolygonPoint = new System.Drawing.Point(0, 0); + private System.Drawing.Point startPoint = new System.Drawing.Point(-10, 0); private System.Drawing.Point endPoint = new System.Drawing.Point(-10, 0); @@ -211,15 +213,15 @@ namespace PBAnaly.Module if (algAttribute.colorValue > imagePaletteForm.nud_colorMin.Value) { - imagePaletteForm.nud_colorMin.Maximum = algAttribute.colorValue; - imagePaletteForm.dtb_colorMin.Maximum = algAttribute.colorValue; + imagePaletteForm.nud_colorMin.Maximum = algAttribute.colorValue - 1; + imagePaletteForm.dtb_colorMin.Maximum = algAttribute.colorValue - 1; fix = true; } else if(algAttribute.colorValue < imagePaletteForm.nud_colorMin.Value) { - imagePaletteForm.nud_colorMin.Maximum = algAttribute.colorValue; - imagePaletteForm.dtb_colorMin.Maximum = algAttribute.colorValue; - imagePaletteForm.nud_colorMin.Value = algAttribute.colorValue; + imagePaletteForm.nud_colorMin.Maximum = algAttribute.colorValue - 1; + imagePaletteForm.dtb_colorMin.Maximum = algAttribute.colorValue - 1; + imagePaletteForm.nud_colorMin.Value = algAttribute.colorValue - 1; fix |= true; } @@ -331,7 +333,7 @@ namespace PBAnaly.Module algAttribute. colorValue = 65534; algAttribute. colorMinValue = 5999; - algAttribute. colorMin = 0; + algAttribute. colorMin = 2; algAttribute. colorMax = 65535; algAttribute.scientificON = false; @@ -383,10 +385,10 @@ namespace PBAnaly.Module imagePaletteForm.nud_colorMax.Minimum= algAttribute.colorMin; imagePaletteForm.nud_colorMax.Value= algAttribute.colorValue; - imagePaletteForm.dtb_colorMin.Maximum = algAttribute.colorMin; - imagePaletteForm.dtb_colorMin.Maximum = algAttribute.colorValue; - imagePaletteForm.dtb_colorMin.Value = algAttribute.colorValue; - imagePaletteForm.nud_colorMin.Maximum = algAttribute.colorValue; + imagePaletteForm.dtb_colorMin.Maximum = algAttribute.colorValue-1; + imagePaletteForm.dtb_colorMin.Value = algAttribute.colorMinValue; + imagePaletteForm.dtb_colorMin.Minimum = 0; + imagePaletteForm.nud_colorMin.Maximum = algAttribute.colorValue-1; imagePaletteForm.nud_colorMin.Minimum = algAttribute.colorMin; imagePaletteForm.nud_colorMin.Value= algAttribute.colorMinValue; imagePaletteForm.cb_colortable.SelectedIndex = algAttribute.colorIndex; @@ -417,9 +419,11 @@ namespace PBAnaly.Module imagePanel.wdb_title.MouseDown += Wdb_title_Click; imagePanel.FormClosing += ImagePanel_FormClosing; imagePanel.FormClosed += ImagePanel_FormClosed; + imagePanel.ava_saveReport.Click += Ava_saveReport_Click; imagePaletteForm.hpb_rect.Click += hpb_rect_Click; imagePaletteForm.hpb_circe.Click += Hpb_circe_Click; - + imagePaletteForm.hpb_xianduan.Click += Hpb_xianduan_Click; + imagePaletteForm.fb_fixSetting.Click += Fb_fixSetting_Click; } @@ -673,7 +677,27 @@ namespace PBAnaly.Module return false; } + private bool IsPointInPolygon(System.Drawing.Point testPoint, PolygonAndInfo polygon) + { + if (polygon.points == null) return false; ; + var points = polygon.points; + bool result = false; + int j = points.Count - 1; // The last vertex is the 'previous' one to the first + for (int i = 0; i < points.Count; i++) + { + if (points[i].Y < testPoint.Y && points[j].Y >= testPoint.Y || points[j].Y < testPoint.Y && points[i].Y >= testPoint.Y) + { + if (points[i].X + (testPoint.Y - points[i].Y) / (points[j].Y - points[i].Y) * (points[j].X - points[i].X) < testPoint.X) + { + result = !result; + } + } + j = i; // j is previous vertex to i + } + + return result; + } #endregion @@ -906,8 +930,75 @@ namespace PBAnaly.Module e.Graphics.DrawEllipse(Pens.Red, curCirCenterPoint.X - radius, curCirCenterPoint.Y - radius, radius * 2, radius * 2); ImageProcess.DrawCircle(g, new System.Drawing.Point(curCirRadioPoint.X, curCirRadioPoint.Y), CircleRadius, Pens.Blue, Brushes.LightBlue); } - - + + index = 0; + if (PolygonAndInfoList != null) + { + int isStart = 0; + System.Drawing.Point point = new System.Drawing.Point(); + foreach (var item1 in PolygonAndInfoList) + { + foreach (var item in item1.points) + { + if (isStart == 0) + { + point = ImageProcess.ConvertRealToPictureBox( item,imagePanel.image_pl); + } + System.Drawing.Point curpoint = ImageProcess.ConvertRealToPictureBox(item, imagePanel.image_pl); + ImageProcess.DrawCircle(g, curpoint, CircleRadius, Pens.Blue, Brushes.LightBlue); + g.DrawLine(Pens.Red, curpoint, point); + point = curpoint; + isStart++; + } + + } + + if (drawpolygon) + { + + point = ImageProcess.ConvertRealToPictureBox( curPolygonAndInfoList.points[curPolygonAndInfoList.points.Count - 1], imagePanel.image_pl); + var p1 = ImageProcess.ConvertRealToPictureBox(curPolygonPoint, imagePanel.image_pl); + g.DrawLine(Pens.Red, p1, point); + foreach (var item in curPolygonAndInfoList.points) + { + if (isStart == 0) + { + point = ImageProcess.ConvertRealToPictureBox(item, imagePanel.image_pl); + } + System.Drawing.Point curpoint = ImageProcess.ConvertRealToPictureBox( item, imagePanel.image_pl); + ImageProcess.DrawCircle(g, curpoint, CircleRadius, Pens.Blue, Brushes.LightBlue); + g.DrawLine(Pens.Red, curpoint, point); + point = curpoint; + isStart++; + } + } + else + { + if (curPolygonAndInfoList.pdinfovc != null) + { + + string labelText = ""; + if (algAttribute.scientificON) + { + + + labelText = $"ROI:{index+1},AOD:{util.GetscientificNotation(curPolygonAndInfoList.pdinfovc.AOD)},IOD:{util.GetscientificNotation(curPolygonAndInfoList.pdinfovc.IOD)}," + + $"\r\nmaxOD:{util.GetscientificNotation(curPolygonAndInfoList.pdinfovc.maxOD)},minOD:{util.GetscientificNotation(curPolygonAndInfoList.pdinfovc.minOD)},Count:{util.GetscientificNotation(curPolygonAndInfoList.pdinfovc.Count)}"; + } + else + { + labelText = $"ROI:{index + 1},AOD:{curPolygonAndInfoList.pdinfovc.AOD},IOD:{curPolygonAndInfoList.pdinfovc.IOD}," + + $"\r\nmaxOD:{curPolygonAndInfoList.pdinfovc.maxOD},minOD:{curPolygonAndInfoList.pdinfovc.minOD},Count:{curPolygonAndInfoList.pdinfovc.Count}"; // 标签编号 + } + Font font = new Font("Arial", 8); // 字体 + Brush brush = Brushes.Red; // 字体颜色 + System.Drawing.Point curpoint = ImageProcess.ConvertRealToPictureBox( curPolygonAndInfoList.points[0], imagePanel.image_pl); + g.DrawString(labelText, font, brush, curpoint.X - 10, curpoint.Y - 15); + } + } + index++; + } + } private void Image_pl_MouseUp(object sender, MouseEventArgs e) @@ -958,14 +1049,11 @@ namespace PBAnaly.Module } if (curpdinfovc != null) rab.pdinfovc = curpdinfovc; + imagePaletteForm.SetInfo = "w:" + rab.rect.Width.ToString() + "h:" + rab.rect.Height.ToString(); // 完成绘制并保存矩形 rectangles.Add(rab); currentRectangle = null; drawRect = false; - - - - imagePanel.image_pl.Invalidate(); } @@ -980,25 +1068,13 @@ namespace PBAnaly.Module rab.center = circleCenter; rab.Radius = circleRadio; - if (CircleAndInfoList.Count == 0) - { - imagePaletteForm.CIRCLE_R = (int)Math.Sqrt(Math.Pow(rab.center.X - rab.Radius.X, 2) + Math.Pow(rab.center.Y - rab.Radius.Y, 2)); - - } - else - { - - double angleInRadians = 90 * Math.PI / 180; // Convert degrees to radians - double x = rab.center.X + imagePaletteForm.CIRCLE_R * Math.Cos(angleInRadians); - double y = rab.center.Y + imagePaletteForm.CIRCLE_R * Math.Sin(angleInRadians); - - rab.Radius = new System.Drawing.Point((int)x, (int)y); - } // 计算光子数并展示出来 float _max = algAttribute.colorValue; float _min = algAttribute.colorMinValue; int radius = (int)Math.Sqrt(Math.Pow(rab.center.X - rab.Radius.X, 2) + Math.Pow(rab.center.Y - rab.Radius.Y, 2)); + + imagePaletteForm.SetInfo = "radio:" + radius.ToString(); Pseudo_infoVC curpdinfovc = null; unsafe { @@ -1039,7 +1115,9 @@ namespace PBAnaly.Module } if (curpdinfovc != null) rattb.pdinfovc = curpdinfovc; + rectangles[rectDragStartIndex] = rattb; + imagePaletteForm.SetInfo = "w:" + recDragRect.Width.ToString() + "h:" + recDragRect.Height.ToString(); isRecDragging = false; rectActiveCorner = Corner.None; rectDragStartIndex = -1; @@ -1068,7 +1146,7 @@ namespace PBAnaly.Module } } circeAndInfo.pdinfovc = curpdinfovc; - + imagePaletteForm.SetInfo = "radio:" + radius.ToString(); CircleAndInfoList[cirDragStartIndex] = circeAndInfo; isCirDragging = false; cirDragStartIndex = -1; @@ -1103,6 +1181,11 @@ namespace PBAnaly.Module circleRadio = readLoction; imagePanel.image_pl.Invalidate(); } + else if (drawpolygon && linepolygonON) + { + curPolygonPoint = readLoction; + imagePanel.image_pl.Invalidate(); + } else if (isDragging && e.Button == MouseButtons.Left) { int deltaX = e.X - mouseDownPosition.X; @@ -1168,11 +1251,11 @@ namespace PBAnaly.Module } imagePanel.image_pl.Invalidate(); // 触发重绘 } - else if (isCirDragging) + else if (isCirDragging) { - if (rectActiveCorner != Corner.None) + if (rectActiveCorner != Corner.None) { - if (rectActiveCorner == Corner.drawMouse) + if (rectActiveCorner == Corner.drawMouse) { // 计算鼠标位置与起始拖拽点的偏移量 int offsetX = readLoction.X - cirDragStart.X; @@ -1186,7 +1269,7 @@ namespace PBAnaly.Module // 重新设置起始拖拽点为当前鼠标位置,以便下一次计算 cirDragStart = readLoction; - + } else @@ -1225,7 +1308,55 @@ namespace PBAnaly.Module private void Image_pl_DoubleClick(object sender, System.EventArgs e) { - + if (linepolygonON && drawpolygon) + { + + if (curPolygonAndInfoList.points != null) + { + System.Drawing.Point firstPoint = curPolygonAndInfoList.points[0]; + System.Drawing.Point lastPoint = curPolygonAndInfoList.points[curPolygonAndInfoList.points.Count - 1]; + firstPoint = ImageProcess.ConvertRealToPictureBoxCoordinates(imagePanel.image_pl, firstPoint); + lastPoint = ImageProcess.ConvertRealToPictureBoxCoordinates(imagePanel.image_pl, lastPoint); + double deltaX = lastPoint.X - firstPoint.X; + double deltaY = lastPoint.Y - firstPoint.Y; + var value = Math.Sqrt(deltaX * deltaX + deltaY * deltaY); + if (value <= 5) + { + lastPoint = firstPoint; + drawpolygon = false; + linepolygonON = false; + imagePanel.image_pl.Invalidate(); + + // 计算光子量 + + float _max = algAttribute.colorValue; + float _min = algAttribute.colorMinValue; + List curVclist = new List(); + Pseudo_infoVC curpdinfovc = null; + foreach (var item in curPolygonAndInfoList.points) + { + Point_VC pvc = new Point_VC(item.X, item.Y); + curVclist.Add(pvc); + + } + unsafe + { + fixed (byte* pseu_16_byte_src = image_org_byte) + { + curpdinfovc = pbpvc.get_pseudo_info_polygon_vc(pseu_16_byte_src, 16, + (ushort)image_org_L16.Width, (ushort)image_org_L16.Height, _max, _min, curVclist); + + } + } + curPolygonAndInfoList.pdinfovc = curpdinfovc; + + PolygonAndInfoList.Add(curPolygonAndInfoList); + + } + + imagePanel.image_pl.Invalidate(); + } + } } private void Image_pl_MouseDown(object sender, MouseEventArgs e) @@ -1245,13 +1376,23 @@ namespace PBAnaly.Module leftTopPoint = readLoction; currentRectangle = new System.Drawing.Rectangle(readLoction.X, readLoction.Y, 0, 0); } - else if (CircleOn) + else if (CircleOn) { //开始绘制圆形 drawCircle = true; circleRadio = readLoction; circleCenter = readLoction; } + else if (linepolygonON) + { + drawpolygon = true; + if (curPolygonAndInfoList.points == null) + { + curPolygonAndInfoList.points = new List(); + } + System.Drawing.Point curPoint = readLoction; + curPolygonAndInfoList.points.Add(curPoint); + } else if (imagePanel.IsImageLargerThanPanel()) { isDragging = true; @@ -1318,6 +1459,13 @@ namespace PBAnaly.Module rectangles.RemoveAt(index); imagePanel.image_pl.Invalidate(); } + else if (drawpolygon==false && IsPointInPolygon(readLoction, curPolygonAndInfoList)) + { + PolygonAndInfoList.Clear(); + curPolygonAndInfoList.points.Clear(); + curPolygonAndInfoList.pdinfovc = null; + imagePanel.image_pl.Invalidate(); + } } } @@ -1340,6 +1488,133 @@ namespace PBAnaly.Module this.bioanalysisMannages[path] = null; this.bioanalysisMannages.Remove(path); } + + private void Ava_saveReport_Click(object sender, EventArgs e) + { + using (SaveFileDialog saveFileDialog = new SaveFileDialog()) + { + saveFileDialog.Title = "保存Panel图像"; + saveFileDialog.Filter = "Excel 文件 (*.xlsx)|*.xlsx"; + if (saveFileDialog.ShowDialog() + == DialogResult.OK) + { + // 保存光子数到xlsx里 先保存矩形的 + if (algAttribute.scientificON) + { + var records = new List(); + int index = 0; + foreach (var item in rectangles) + { + index++; + if (algAttribute.scientificON) + { + DataRecordString dr = new DataRecordString(); + dr.index = index; + + dr.IOD = util.GetscientificNotation(item.pdinfovc.IOD); + dr.AOD = util.GetscientificNotation(item.pdinfovc.AOD); + dr.max = util.GetscientificNotation(item.pdinfovc.maxOD); + dr.min = util.GetscientificNotation(item.pdinfovc.minOD); + dr.Count = util.GetscientificNotation(item.pdinfovc.Count); + records.Add(dr); + } + + } + + foreach (var item in CircleAndInfoList) + { + index++; + + DataRecordString dr = new DataRecordString(); + dr.index = index; + + dr.IOD = util.GetscientificNotation(item.pdinfovc.IOD); + dr.AOD = util.GetscientificNotation(item.pdinfovc.AOD); + dr.max = util.GetscientificNotation(item.pdinfovc.maxOD); + dr.min = util.GetscientificNotation(item.pdinfovc.minOD); + dr.Count = util.GetscientificNotation(item.pdinfovc.Count); + records.Add(dr); + } + + if (records.Count > 0) + { + string directoryPath = System.IO.Path.GetDirectoryName(saveFileDialog.FileName); + string fileNameWithoutExtension = System.IO.Path.GetFileNameWithoutExtension(saveFileDialog.FileName); + string path = directoryPath + "\\" + fileNameWithoutExtension + ".xlsx"; + if (File.Exists(path)) + { + try + { + File.Delete(path); + } + catch (Exception) + { + + MessageBox.Show("文件被占用,无法删除!!!"); + return; + } + } + MiniExcel.SaveAs(path, records); + } + } + else + { + var records = new List(); + + // 目前只保存矩形下的光子数 + int index = 0; + foreach (var item in rectangles) + { + index++; + + DataRecord dr = new DataRecord(); + dr.index = index; + dr.IOD = item.pdinfovc.IOD; + dr.AOD = item.pdinfovc.AOD; + dr.max = item.pdinfovc.maxOD; + dr.min = item.pdinfovc.minOD; + dr.Count = item.pdinfovc.Count; + records.Add(dr); + } + foreach (var item in CircleAndInfoList) + { + index++; + + DataRecord dr = new DataRecord(); + dr.index = index; + dr.IOD = item.pdinfovc.IOD; + dr.AOD = item.pdinfovc.AOD; + dr.max = item.pdinfovc.maxOD; + dr.min = item.pdinfovc.minOD; + dr.Count = item.pdinfovc.Count; + records.Add(dr); + } + + if (records.Count > 0) + { + string directoryPath = System.IO.Path.GetDirectoryName(saveFileDialog.FileName); + string fileNameWithoutExtension = System.IO.Path.GetFileNameWithoutExtension(saveFileDialog.FileName); + string path = directoryPath + "\\" + fileNameWithoutExtension + ".xlsx"; + if (File.Exists(path)) + { + try + { + File.Delete(path); + } + catch (Exception) + { + + MessageBox.Show("文件被占用,无法删除!!!"); + return; + } + } + MiniExcel.SaveAs(path, records); + } + } + + } + } + } #endregion #region imagePaletteForm private void Hpb_line_Click(object sender, EventArgs e) @@ -1355,6 +1630,42 @@ namespace PBAnaly.Module { CircleOn = true; } + private void Hpb_xianduan_Click(object sender, EventArgs e) + { + linepolygonON = true; + } + private void Fb_fixSetting_Click(object sender, EventArgs e) + { + + // 将矩形和圆形按照大小进行统一设定 + for (int i = 0; i < rectangles.Count; i++) + { + RectAttribute rattb = new RectAttribute(); + rattb.rect = rectangles[i].rect; + rattb.rect.Width = imagePaletteForm.ROI_W; + rattb.rect.Height = imagePaletteForm.ROI_H; + rattb.pdinfovc = rectangles[i].pdinfovc; + + rectangles[i] = rattb; + } + + + + for (int i = 0; i < CircleAndInfoList.Count; i++) + { + CirceAndInfo circeAndInfo = new CirceAndInfo(); + circeAndInfo.pdinfovc = CircleAndInfoList[i].pdinfovc; + double angleInRadians = 90 * Math.PI / 180; // Convert degrees to radians + double x = CircleAndInfoList[i].center.X + imagePaletteForm.CIRCLE_R * Math.Cos(angleInRadians); + double y = CircleAndInfoList[i].center.Y + imagePaletteForm.CIRCLE_R * Math.Sin(angleInRadians); + circeAndInfo.Radius = new System.Drawing.Point((int)x, (int)y); + circeAndInfo.center = CircleAndInfoList[i].center; + + CircleAndInfoList[i] = circeAndInfo; + + } + imagePanel.image_pl.Invalidate(); + } #endregion #endregion #region 对外接口 diff --git a/src/PBAnaly/PBAnaly.csproj b/src/PBAnaly/PBAnaly.csproj index 97d8e44..bf2bbb2 100644 --- a/src/PBAnaly/PBAnaly.csproj +++ b/src/PBAnaly/PBAnaly.csproj @@ -399,6 +399,8 @@ + + diff --git a/src/PBAnaly/Properties/Resources.Designer.cs b/src/PBAnaly/Properties/Resources.Designer.cs index 2727968..7a10cb9 100644 --- a/src/PBAnaly/Properties/Resources.Designer.cs +++ b/src/PBAnaly/Properties/Resources.Designer.cs @@ -460,6 +460,26 @@ namespace PBAnaly.Properties { } } + /// + /// 查找 System.Drawing.Bitmap 类型的本地化资源。 + /// + internal static System.Drawing.Bitmap 数据报告 { + get { + object obj = ResourceManager.GetObject("数据报告", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + + /// + /// 查找 System.Drawing.Bitmap 类型的本地化资源。 + /// + internal static System.Drawing.Bitmap 数据报告__1_ { + get { + object obj = ResourceManager.GetObject("数据报告 (1)", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// 查找 System.Drawing.Bitmap 类型的本地化资源。 /// diff --git a/src/PBAnaly/Properties/Resources.resx b/src/PBAnaly/Properties/Resources.resx index f5f6e82..d99c8af 100644 --- a/src/PBAnaly/Properties/Resources.resx +++ b/src/PBAnaly/Properties/Resources.resx @@ -121,9 +121,6 @@ ..\Resources\Black_Blue_0.bmp;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\Black_Yley_1.bmp;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\Resources\计数器.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -142,8 +139,14 @@ ..\Resources\线段.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\饼干.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\YellowHot_1.bmp;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\蛋白质-01.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\重置.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\Resources\Black_Green_1.bmp;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -178,8 +181,11 @@ ..\Resources\圖片_20240731174523.jpg;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\重置.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\图片管理.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\圆形.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\Resources\Black_Red_0.bmp;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -187,6 +193,9 @@ ..\Resources\京仪科技定稿_画板 1 副本2.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\数据报告.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\Resources\zoom-out.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -214,6 +223,9 @@ ..\Resources\窗口最大化_操作_jurassic.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\魔术棒,魔法,魔术,一键.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\Resources\YellowHot_0.bmp;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -223,14 +235,11 @@ ..\Resources\C.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\图片管理.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\前台.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\圆形.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\Resources\圆形.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\线段 (1).png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\Resources\主页面-图像编辑-正反片.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -238,8 +247,8 @@ ..\Resources\缩小.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\黑白平衡.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\Black_Yley_1.bmp;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\Resources\導出.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -253,37 +262,34 @@ ..\Resources\10矩形.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\放大.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\Resources\Black_Green_0.bmp;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\YellowHot_1.bmp;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\Resources\蛋白质-01.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\Resources\壁纸.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\Resources\執行日誌紀錄.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\饼干.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\壁纸.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\圆形.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\黑白平衡.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\Resources\Black_SDS_1.bmp;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\前台.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\放大.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\Resources\波形图.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\魔术棒,魔法,魔术,一键.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\Resources\线段 (1).png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\数据报告 (1).png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a \ No newline at end of file diff --git a/src/PBAnaly/Resources/数据报告 (1).png b/src/PBAnaly/Resources/数据报告 (1).png new file mode 100644 index 0000000..98c3938 Binary files /dev/null and b/src/PBAnaly/Resources/数据报告 (1).png differ diff --git a/src/PBAnaly/Resources/数据报告.png b/src/PBAnaly/Resources/数据报告.png new file mode 100644 index 0000000..88a4b9f Binary files /dev/null and b/src/PBAnaly/Resources/数据报告.png differ diff --git a/src/PBAnaly/UI/BioanalyImagePanel.Designer.cs b/src/PBAnaly/UI/BioanalyImagePanel.Designer.cs index 0dcc044..a27a088 100644 --- a/src/PBAnaly/UI/BioanalyImagePanel.Designer.cs +++ b/src/PBAnaly/UI/BioanalyImagePanel.Designer.cs @@ -36,6 +36,7 @@ this.label1 = new AntdUI.Label(); this.cb_scientific = new AntdUI.Checkbox(); this.flowPanel1 = new AntdUI.FlowPanel(); + this.ava_saveReport = new AntdUI.Avatar(); this.ava_save = new AntdUI.Avatar(); this.ava_zoom_out = new AntdUI.Avatar(); this.ava__zoom_in = new AntdUI.Avatar(); @@ -67,11 +68,11 @@ this.wdb_title.Dock = System.Windows.Forms.DockStyle.Top; this.wdb_title.ForeColor = System.Drawing.SystemColors.ButtonFace; this.wdb_title.IsMax = false; - this.wdb_title.Location = new System.Drawing.Point(4, 4); - this.wdb_title.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.wdb_title.Location = new System.Drawing.Point(3, 3); + this.wdb_title.MinimizeBox = false; this.wdb_title.Name = "wdb_title"; this.wdb_title.ShowIcon = false; - this.wdb_title.Size = new System.Drawing.Size(469, 29); + this.wdb_title.Size = new System.Drawing.Size(352, 23); this.wdb_title.TabIndex = 0; this.wdb_title.Text = " "; this.wdb_title.UseSystemStyleColor = true; @@ -80,30 +81,29 @@ // this.panel1.Controls.Add(this.tableLayoutPanel1); this.panel1.Dock = System.Windows.Forms.DockStyle.Top; - this.panel1.Location = new System.Drawing.Point(4, 33); - this.panel1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.panel1.Location = new System.Drawing.Point(3, 26); this.panel1.Name = "panel1"; - this.panel1.Size = new System.Drawing.Size(469, 29); + this.panel1.Size = new System.Drawing.Size(352, 23); this.panel1.TabIndex = 1; this.panel1.Text = "panel1"; // // tableLayoutPanel1 // this.tableLayoutPanel1.ColumnCount = 4; - this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 175F)); - this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 92F)); + this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 131F)); + this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 69F)); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 167F)); + this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 125F)); this.tableLayoutPanel1.Controls.Add(this.panel2, 0, 0); this.tableLayoutPanel1.Controls.Add(this.cb_scientific, 1, 0); this.tableLayoutPanel1.Controls.Add(this.flowPanel1, 3, 0); + this.tableLayoutPanel1.Controls.Add(this.ava_auto, 2, 0); this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill; this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0); - this.tableLayoutPanel1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); this.tableLayoutPanel1.Name = "tableLayoutPanel1"; this.tableLayoutPanel1.RowCount = 1; this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tableLayoutPanel1.Size = new System.Drawing.Size(469, 29); + this.tableLayoutPanel1.Size = new System.Drawing.Size(352, 23); this.tableLayoutPanel1.TabIndex = 0; // // panel2 @@ -114,7 +114,7 @@ this.panel2.Location = new System.Drawing.Point(0, 0); this.panel2.Margin = new System.Windows.Forms.Padding(0); this.panel2.Name = "panel2"; - this.panel2.Size = new System.Drawing.Size(175, 29); + this.panel2.Size = new System.Drawing.Size(131, 23); this.panel2.TabIndex = 0; this.panel2.Text = "panel2"; // @@ -126,68 +126,75 @@ "merge", "mark", "pseudocolor"}); - this.cbb_mode.Location = new System.Drawing.Point(60, 1); - this.cbb_mode.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.cbb_mode.Location = new System.Drawing.Point(45, 1); this.cbb_mode.Name = "cbb_mode"; - this.cbb_mode.Size = new System.Drawing.Size(109, 23); + this.cbb_mode.Size = new System.Drawing.Size(83, 20); this.cbb_mode.TabIndex = 1; // // label1 // this.label1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left))); - this.label1.Location = new System.Drawing.Point(4, 0); - this.label1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.label1.Location = new System.Drawing.Point(3, 0); this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(48, 29); + this.label1.Size = new System.Drawing.Size(36, 23); this.label1.TabIndex = 0; this.label1.Text = "模式:"; // // cb_scientific // this.cb_scientific.AutoCheck = true; - this.cb_scientific.Location = new System.Drawing.Point(179, 4); - this.cb_scientific.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.cb_scientific.Location = new System.Drawing.Point(134, 3); this.cb_scientific.Name = "cb_scientific"; - this.cb_scientific.Size = new System.Drawing.Size(84, 21); + this.cb_scientific.Size = new System.Drawing.Size(63, 17); this.cb_scientific.TabIndex = 1; this.cb_scientific.Text = "光子数"; // // flowPanel1 // + this.flowPanel1.Controls.Add(this.ava_saveReport); this.flowPanel1.Controls.Add(this.ava_save); this.flowPanel1.Controls.Add(this.ava_zoom_out); this.flowPanel1.Controls.Add(this.ava__zoom_in); - this.flowPanel1.Controls.Add(this.ava_auto); this.flowPanel1.Dock = System.Windows.Forms.DockStyle.Fill; - this.flowPanel1.Location = new System.Drawing.Point(302, 0); + this.flowPanel1.Location = new System.Drawing.Point(227, 0); this.flowPanel1.Margin = new System.Windows.Forms.Padding(0); this.flowPanel1.Name = "flowPanel1"; - this.flowPanel1.Size = new System.Drawing.Size(167, 29); + this.flowPanel1.Size = new System.Drawing.Size(125, 23); this.flowPanel1.TabIndex = 2; this.flowPanel1.Text = "flowPanel1"; // + // ava_saveReport + // + this.ava_saveReport.Cursor = System.Windows.Forms.Cursors.Hand; + this.ava_saveReport.Image = global::PBAnaly.Properties.Resources.数据报告__1_; + this.ava_saveReport.ImageFit = AntdUI.TFit.Contain; + this.ava_saveReport.Location = new System.Drawing.Point(96, 3); + this.ava_saveReport.Name = "ava_saveReport"; + this.ava_saveReport.Size = new System.Drawing.Size(21, 17); + this.ava_saveReport.TabIndex = 7; + this.ava_saveReport.Text = "a"; + // // ava_save // this.ava_save.Cursor = System.Windows.Forms.Cursors.Hand; this.ava_save.Image = global::PBAnaly.Properties.Resources.保存图片; this.ava_save.ImageFit = AntdUI.TFit.Contain; - this.ava_save.Location = new System.Drawing.Point(127, 4); - this.ava_save.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.ava_save.Location = new System.Drawing.Point(65, 3); this.ava_save.Name = "ava_save"; - this.ava_save.Size = new System.Drawing.Size(33, 21); + this.ava_save.Size = new System.Drawing.Size(25, 17); this.ava_save.TabIndex = 6; this.ava_save.Text = "a"; + this.ava_save.Click += new System.EventHandler(this.ava_save_Click); // // ava_zoom_out // this.ava_zoom_out.Cursor = System.Windows.Forms.Cursors.Hand; this.ava_zoom_out.Image = global::PBAnaly.Properties.Resources.缩小; this.ava_zoom_out.ImageFit = AntdUI.TFit.Contain; - this.ava_zoom_out.Location = new System.Drawing.Point(86, 4); - this.ava_zoom_out.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.ava_zoom_out.Location = new System.Drawing.Point(34, 3); this.ava_zoom_out.Name = "ava_zoom_out"; - this.ava_zoom_out.Size = new System.Drawing.Size(33, 21); + this.ava_zoom_out.Size = new System.Drawing.Size(25, 17); this.ava_zoom_out.TabIndex = 5; this.ava_zoom_out.Text = "a"; this.ava_zoom_out.Click += new System.EventHandler(this.ava_zoom_out_Click); @@ -197,10 +204,9 @@ this.ava__zoom_in.Cursor = System.Windows.Forms.Cursors.Hand; this.ava__zoom_in.Image = global::PBAnaly.Properties.Resources.放大; this.ava__zoom_in.ImageFit = AntdUI.TFit.Contain; - this.ava__zoom_in.Location = new System.Drawing.Point(45, 4); - this.ava__zoom_in.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.ava__zoom_in.Location = new System.Drawing.Point(3, 3); this.ava__zoom_in.Name = "ava__zoom_in"; - this.ava__zoom_in.Size = new System.Drawing.Size(33, 21); + this.ava__zoom_in.Size = new System.Drawing.Size(25, 17); this.ava__zoom_in.TabIndex = 4; this.ava__zoom_in.Text = ""; this.ava__zoom_in.Click += new System.EventHandler(this.ava__zoom_in_Click); @@ -211,10 +217,9 @@ this.ava_auto.HandCursor = System.Windows.Forms.Cursors.IBeam; this.ava_auto.Image = global::PBAnaly.Properties.Resources.全屏; this.ava_auto.ImageFit = AntdUI.TFit.Contain; - this.ava_auto.Location = new System.Drawing.Point(4, 4); - this.ava_auto.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.ava_auto.Location = new System.Drawing.Point(203, 3); this.ava_auto.Name = "ava_auto"; - this.ava_auto.Size = new System.Drawing.Size(33, 21); + this.ava_auto.Size = new System.Drawing.Size(21, 17); this.ava_auto.TabIndex = 3; this.ava_auto.Text = "a"; this.ava_auto.Click += new System.EventHandler(this.ava_auto_Click); @@ -223,10 +228,9 @@ // this.panel3.Controls.Add(this.lb_size); this.panel3.Dock = System.Windows.Forms.DockStyle.Bottom; - this.panel3.Location = new System.Drawing.Point(4, 365); - this.panel3.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.panel3.Location = new System.Drawing.Point(3, 292); this.panel3.Name = "panel3"; - this.panel3.Size = new System.Drawing.Size(469, 16); + this.panel3.Size = new System.Drawing.Size(352, 13); this.panel3.TabIndex = 2; this.panel3.Text = "panel3"; // @@ -237,7 +241,7 @@ this.lb_size.Location = new System.Drawing.Point(0, 0); this.lb_size.Margin = new System.Windows.Forms.Padding(0); this.lb_size.Name = "lb_size"; - this.lb_size.Size = new System.Drawing.Size(469, 16); + this.lb_size.Size = new System.Drawing.Size(352, 13); this.lb_size.TabIndex = 0; this.lb_size.Text = "800x600"; this.lb_size.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -246,17 +250,16 @@ // this.tableLayoutPanel2.ColumnCount = 2; this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 88F)); + this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 66F)); this.tableLayoutPanel2.Controls.Add(this.pl_panel_image, 0, 0); this.tableLayoutPanel2.Controls.Add(this.tableLayoutPanel3, 1, 0); this.tableLayoutPanel2.Dock = System.Windows.Forms.DockStyle.Fill; - this.tableLayoutPanel2.Location = new System.Drawing.Point(4, 62); - this.tableLayoutPanel2.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.tableLayoutPanel2.Location = new System.Drawing.Point(3, 49); this.tableLayoutPanel2.Name = "tableLayoutPanel2"; this.tableLayoutPanel2.RowCount = 1; this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F)); - this.tableLayoutPanel2.Size = new System.Drawing.Size(469, 303); + this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 243F)); + this.tableLayoutPanel2.Size = new System.Drawing.Size(352, 243); this.tableLayoutPanel2.TabIndex = 3; // // pl_panel_image @@ -264,10 +267,9 @@ this.pl_panel_image.Back = System.Drawing.Color.FromArgb(((int)(((byte)(6)))), ((int)(((byte)(6)))), ((int)(((byte)(6))))); this.pl_panel_image.Controls.Add(this.pl_bg_panel); this.pl_panel_image.Dock = System.Windows.Forms.DockStyle.Fill; - this.pl_panel_image.Location = new System.Drawing.Point(4, 4); - this.pl_panel_image.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.pl_panel_image.Location = new System.Drawing.Point(3, 3); this.pl_panel_image.Name = "pl_panel_image"; - this.pl_panel_image.Size = new System.Drawing.Size(373, 295); + this.pl_panel_image.Size = new System.Drawing.Size(280, 237); this.pl_panel_image.TabIndex = 0; this.pl_panel_image.Text = "panel4"; // @@ -275,9 +277,8 @@ // this.pl_bg_panel.Controls.Add(this.image_pl); this.pl_bg_panel.Location = new System.Drawing.Point(0, 0); - this.pl_bg_panel.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); this.pl_bg_panel.Name = "pl_bg_panel"; - this.pl_bg_panel.Size = new System.Drawing.Size(297, 231); + this.pl_bg_panel.Size = new System.Drawing.Size(223, 185); this.pl_bg_panel.TabIndex = 0; this.pl_bg_panel.Text = "panel4"; // @@ -285,9 +286,8 @@ // this.image_pl.Dock = System.Windows.Forms.DockStyle.Fill; this.image_pl.Location = new System.Drawing.Point(0, 0); - this.image_pl.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); this.image_pl.Name = "image_pl"; - this.image_pl.Size = new System.Drawing.Size(297, 231); + this.image_pl.Size = new System.Drawing.Size(223, 185); this.image_pl.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage; this.image_pl.TabIndex = 0; this.image_pl.TabStop = false; @@ -299,23 +299,22 @@ this.tableLayoutPanel3.Controls.Add(this.lb_wh, 0, 1); this.tableLayoutPanel3.Controls.Add(this.image_pr, 0, 0); this.tableLayoutPanel3.Dock = System.Windows.Forms.DockStyle.Fill; - this.tableLayoutPanel3.Location = new System.Drawing.Point(381, 0); + this.tableLayoutPanel3.Location = new System.Drawing.Point(286, 0); this.tableLayoutPanel3.Margin = new System.Windows.Forms.Padding(0); this.tableLayoutPanel3.Name = "tableLayoutPanel3"; this.tableLayoutPanel3.RowCount = 2; this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 78F)); - this.tableLayoutPanel3.Size = new System.Drawing.Size(88, 303); + this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 62F)); + this.tableLayoutPanel3.Size = new System.Drawing.Size(66, 243); this.tableLayoutPanel3.TabIndex = 1; // // lb_wh // this.lb_wh.Dock = System.Windows.Forms.DockStyle.Fill; this.lb_wh.Font = new System.Drawing.Font("Microsoft Sans Serif", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - this.lb_wh.Location = new System.Drawing.Point(4, 229); - this.lb_wh.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.lb_wh.Location = new System.Drawing.Point(3, 184); this.lb_wh.Name = "lb_wh"; - this.lb_wh.Size = new System.Drawing.Size(80, 70); + this.lb_wh.Size = new System.Drawing.Size(60, 56); this.lb_wh.TabIndex = 3; this.lb_wh.Text = "Color Scale\r\nMin = 1\r\nMax= 2"; this.lb_wh.TextAlign = System.Drawing.ContentAlignment.TopCenter; @@ -325,28 +324,27 @@ this.image_pr.Dock = System.Windows.Forms.DockStyle.Fill; this.image_pr.Duration = 0; this.image_pr.ImageFit = AntdUI.TFit.Fill; - this.image_pr.Location = new System.Drawing.Point(4, 4); - this.image_pr.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.image_pr.Location = new System.Drawing.Point(3, 3); this.image_pr.Name = "image_pr"; - this.image_pr.Size = new System.Drawing.Size(80, 217); + this.image_pr.Size = new System.Drawing.Size(60, 175); this.image_pr.Speed = 1; this.image_pr.TabIndex = 1; this.image_pr.Text = "image3D1"; // // BioanalyImagePanel // - this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F); + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(477, 385); + this.ClientSize = new System.Drawing.Size(358, 308); this.Controls.Add(this.tableLayoutPanel2); this.Controls.Add(this.panel3); this.Controls.Add(this.panel1); this.Controls.Add(this.wdb_title); this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; - this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); this.Name = "BioanalyImagePanel"; - this.Padding = new System.Windows.Forms.Padding(4, 4, 4, 4); + this.Padding = new System.Windows.Forms.Padding(3); this.Text = "BioanalyImagePanel"; + this.SizeChanged += new System.EventHandler(this.BioanalyImagePanel_SizeChanged); this.MouseEnter += new System.EventHandler(this.BioanalyImagePanel_MouseEnter); this.panel1.ResumeLayout(false); this.tableLayoutPanel1.ResumeLayout(false); @@ -375,7 +373,6 @@ public System.Windows.Forms.ComboBox cbb_mode; private AntdUI.Image3D image_pr; public AntdUI.Checkbox cb_scientific; - public AntdUI.Avatar ava_save; public AntdUI.Avatar ava_zoom_out; public AntdUI.Avatar ava__zoom_in; public AntdUI.Panel pl_bg_panel; @@ -384,5 +381,7 @@ public AntdUI.Label lb_wh; public System.Windows.Forms.PictureBox image_pl; public AntdUI.WindowBar wdb_title; + public AntdUI.Avatar ava_saveReport; + private AntdUI.Avatar ava_save; } } \ No newline at end of file diff --git a/src/PBAnaly/UI/BioanalyImagePanel.cs b/src/PBAnaly/UI/BioanalyImagePanel.cs index 69ce018..738eb0b 100644 --- a/src/PBAnaly/UI/BioanalyImagePanel.cs +++ b/src/PBAnaly/UI/BioanalyImagePanel.cs @@ -200,6 +200,45 @@ namespace PBAnaly.UI ZoomPictureBox(1 / ZoomFactor); } } + + private void ava_save_Click(object sender, EventArgs e) + { + // 创建一个位图,其大小与panel相同 + Bitmap bitmap = new Bitmap(this.Width, this.Height); + + // 将panel的视图渲染到位图上 + this.DrawToBitmap(bitmap, new System.Drawing.Rectangle(0, 0, this.Width, this.Height)); + + // 弹出保存文件对话框 + using (SaveFileDialog saveFileDialog = new SaveFileDialog()) + { + saveFileDialog.Title = "保存Panel图像"; + saveFileDialog.Filter = "PNG 图片|*.png|JPEG 图片|*.jpg|BMP 图片|*.bmp"; + if (saveFileDialog.ShowDialog() + == DialogResult.OK) + { + // 根据文件扩展名选择格式 + System.Drawing.Imaging.ImageFormat format = System.Drawing.Imaging.ImageFormat.Bmp; + switch (System.IO.Path.GetExtension(saveFileDialog.FileName).ToLower()) + { + case ".jpg": + format = System.Drawing.Imaging.ImageFormat.Jpeg; + break; + case ".bmp": + format = System.Drawing.Imaging.ImageFormat.Bmp; + break; + } + bitmap.Save(saveFileDialog.FileName, format); // 保存图像到文件 + } + } + } + private void BioanalyImagePanel_SizeChanged(object sender, EventArgs e) + { + pl_bg_panel.Location = new System.Drawing.Point(pl_panel_image.Location.X, pl_panel_image.Location.Y); + pl_bg_panel.Width = pl_panel_image.Width; + pl_bg_panel.Height = pl_panel_image.Height; + CenterPictureBox(); + } #endregion #region 方法 diff --git a/src/PBAnaly/UI/BioanayImagePaletteForm.Designer.cs b/src/PBAnaly/UI/BioanayImagePaletteForm.Designer.cs index 55fcb04..8ae6028 100644 --- a/src/PBAnaly/UI/BioanayImagePaletteForm.Designer.cs +++ b/src/PBAnaly/UI/BioanayImagePaletteForm.Designer.cs @@ -30,9 +30,7 @@ { this.fb_fixSetting = new ReaLTaiizor.Controls.FoxButton(); this.foxLabel7 = new ReaLTaiizor.Controls.FoxLabel(); - this.ftb_h = new ReaLTaiizor.Controls.FoxTextBox(); this.foxLabel5 = new ReaLTaiizor.Controls.FoxLabel(); - this.ftb_w = new ReaLTaiizor.Controls.FoxTextBox(); this.foxLabel8 = new ReaLTaiizor.Controls.FoxLabel(); this.flb_act_mm = new ReaLTaiizor.Controls.FoxLabel(); this.foxLabel9 = new ReaLTaiizor.Controls.FoxLabel(); @@ -42,13 +40,16 @@ this.foxLabel1 = new ReaLTaiizor.Controls.FoxLabel(); this.foxLabel4 = new ReaLTaiizor.Controls.FoxLabel(); this.hpb_line = new ReaLTaiizor.Controls.HopePictureBox(); - this.ftb_r = new ReaLTaiizor.Controls.FoxTextBox(); this.tableLayoutPanel3 = new System.Windows.Forms.TableLayoutPanel(); this.hpb_wand = new AntdUI.Avatar(); this.hpb_xianduan = new AntdUI.Avatar(); this.hpb_circe = new AntdUI.Avatar(); this.hpb_rect = new AntdUI.Avatar(); this.panel2 = new AntdUI.Panel(); + this.dtb_r = new ReaLTaiizor.Controls.DreamTextBox(); + this.dtb_h = new ReaLTaiizor.Controls.DreamTextBox(); + this.dtb_w = new ReaLTaiizor.Controls.DreamTextBox(); + this.flb_info = new ReaLTaiizor.Controls.FoxLabel(); this.collapseItem2 = new AntdUI.CollapseItem(); this.cb_colortable = new System.Windows.Forms.ComboBox(); this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel(); @@ -65,7 +66,6 @@ this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); this.collapseItem1 = new AntdUI.CollapseItem(); this.cll_panel = new AntdUI.Collapse(); - this.collapseItem3 = new AntdUI.CollapseItem(); ((System.ComponentModel.ISupportInitialize)(this.hpb_line)).BeginInit(); this.tableLayoutPanel3.SuspendLayout(); this.panel2.SuspendLayout(); @@ -95,13 +95,12 @@ this.fb_fixSetting.EnabledCalc = true; this.fb_fixSetting.Font = new System.Drawing.Font("Segoe UI", 10F); this.fb_fixSetting.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(78)))), ((int)(((byte)(90))))); - this.fb_fixSetting.Location = new System.Drawing.Point(120, 30); + this.fb_fixSetting.Location = new System.Drawing.Point(137, 31); this.fb_fixSetting.Name = "fb_fixSetting"; this.fb_fixSetting.OverColor = System.Drawing.Color.FromArgb(((int)(((byte)(242)))), ((int)(((byte)(242)))), ((int)(((byte)(242))))); this.fb_fixSetting.Size = new System.Drawing.Size(59, 31); this.fb_fixSetting.TabIndex = 6; this.fb_fixSetting.Text = "修改"; - this.fb_fixSetting.Visible = false; // // foxLabel7 // @@ -114,24 +113,6 @@ this.foxLabel7.TabIndex = 4; this.foxLabel7.Text = "r="; // - // ftb_h - // - this.ftb_h.BackColor = System.Drawing.Color.Transparent; - this.ftb_h.Cursor = System.Windows.Forms.Cursors.Hand; - this.ftb_h.EnabledCalc = true; - this.ftb_h.Font = new System.Drawing.Font("Segoe UI", 10F); - this.ftb_h.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(78)))), ((int)(((byte)(90))))); - this.ftb_h.Location = new System.Drawing.Point(34, 28); - this.ftb_h.MaxLength = 32767; - this.ftb_h.MultiLine = false; - this.ftb_h.Name = "ftb_h"; - this.ftb_h.ReadOnly = false; - this.ftb_h.Size = new System.Drawing.Size(75, 22); - this.ftb_h.TabIndex = 3; - this.ftb_h.Text = "20"; - this.ftb_h.TextAlign = System.Windows.Forms.HorizontalAlignment.Left; - this.ftb_h.UseSystemPasswordChar = false; - // // foxLabel5 // this.foxLabel5.BackColor = System.Drawing.Color.Transparent; @@ -143,24 +124,6 @@ this.foxLabel5.TabIndex = 2; this.foxLabel5.Text = "h="; // - // ftb_w - // - this.ftb_w.BackColor = System.Drawing.Color.Transparent; - this.ftb_w.Cursor = System.Windows.Forms.Cursors.Hand; - this.ftb_w.EnabledCalc = true; - this.ftb_w.Font = new System.Drawing.Font("Segoe UI", 10F); - this.ftb_w.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(78)))), ((int)(((byte)(90))))); - this.ftb_w.Location = new System.Drawing.Point(34, 0); - this.ftb_w.MaxLength = 32767; - this.ftb_w.MultiLine = false; - this.ftb_w.Name = "ftb_w"; - this.ftb_w.ReadOnly = false; - this.ftb_w.Size = new System.Drawing.Size(75, 22); - this.ftb_w.TabIndex = 1; - this.ftb_w.Text = "20"; - this.ftb_w.TextAlign = System.Windows.Forms.HorizontalAlignment.Left; - this.ftb_w.UseSystemPasswordChar = false; - // // foxLabel8 // this.foxLabel8.BackColor = System.Drawing.Color.Transparent; @@ -177,12 +140,13 @@ // flb_act_mm // this.flb_act_mm.BackColor = System.Drawing.Color.Transparent; + this.tableLayoutPanel2.SetColumnSpan(this.flb_act_mm, 2); this.flb_act_mm.Dock = System.Windows.Forms.DockStyle.Fill; this.flb_act_mm.Font = new System.Drawing.Font("宋体", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.flb_act_mm.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(76)))), ((int)(((byte)(88)))), ((int)(((byte)(100))))); this.flb_act_mm.Location = new System.Drawing.Point(93, 137); this.flb_act_mm.Name = "flb_act_mm"; - this.flb_act_mm.Size = new System.Drawing.Size(114, 23); + this.flb_act_mm.Size = new System.Drawing.Size(164, 23); this.flb_act_mm.TabIndex = 30; this.flb_act_mm.Text = "0 mm"; // @@ -272,24 +236,6 @@ this.hpb_line.TabStop = false; this.hpb_line.TextRenderingType = System.Drawing.Text.TextRenderingHint.ClearTypeGridFit; // - // ftb_r - // - this.ftb_r.BackColor = System.Drawing.Color.Transparent; - this.ftb_r.Cursor = System.Windows.Forms.Cursors.Hand; - this.ftb_r.EnabledCalc = true; - this.ftb_r.Font = new System.Drawing.Font("Segoe UI", 10F); - this.ftb_r.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(66)))), ((int)(((byte)(78)))), ((int)(((byte)(90))))); - this.ftb_r.Location = new System.Drawing.Point(151, 2); - this.ftb_r.MaxLength = 32767; - this.ftb_r.MultiLine = false; - this.ftb_r.Name = "ftb_r"; - this.ftb_r.ReadOnly = false; - this.ftb_r.Size = new System.Drawing.Size(75, 22); - this.ftb_r.TabIndex = 5; - this.ftb_r.Text = "10"; - this.ftb_r.TextAlign = System.Windows.Forms.HorizontalAlignment.Left; - this.ftb_r.UseSystemPasswordChar = false; - // // tableLayoutPanel3 // this.tableLayoutPanel3.ColumnCount = 5; @@ -310,7 +256,7 @@ this.tableLayoutPanel3.RowCount = 2; this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 34F)); this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tableLayoutPanel3.Size = new System.Drawing.Size(266, 113); + this.tableLayoutPanel3.Size = new System.Drawing.Size(266, 182); this.tableLayoutPanel3.TabIndex = 0; // // hpb_wand @@ -326,6 +272,7 @@ // // hpb_xianduan // + this.hpb_xianduan.Cursor = System.Windows.Forms.Cursors.Hand; this.hpb_xianduan.Dock = System.Windows.Forms.DockStyle.Fill; this.hpb_xianduan.Image = global::PBAnaly.Properties.Resources.线段__1_; this.hpb_xianduan.ImageFit = AntdUI.TFit.Contain; @@ -337,6 +284,7 @@ // // hpb_circe // + this.hpb_circe.Cursor = System.Windows.Forms.Cursors.Hand; this.hpb_circe.Dock = System.Windows.Forms.DockStyle.Fill; this.hpb_circe.Image = global::PBAnaly.Properties.Resources.圆形; this.hpb_circe.ImageFit = AntdUI.TFit.Contain; @@ -348,6 +296,7 @@ // // hpb_rect // + this.hpb_rect.Cursor = System.Windows.Forms.Cursors.Hand; this.hpb_rect.Dock = System.Windows.Forms.DockStyle.Fill; this.hpb_rect.Image = global::PBAnaly.Properties.Resources._10矩形; this.hpb_rect.ImageFit = AntdUI.TFit.Contain; @@ -360,27 +309,89 @@ // panel2 // this.tableLayoutPanel3.SetColumnSpan(this.panel2, 5); + this.panel2.Controls.Add(this.dtb_r); + this.panel2.Controls.Add(this.dtb_h); + this.panel2.Controls.Add(this.dtb_w); + this.panel2.Controls.Add(this.flb_info); this.panel2.Controls.Add(this.fb_fixSetting); - this.panel2.Controls.Add(this.ftb_r); this.panel2.Controls.Add(this.foxLabel7); - this.panel2.Controls.Add(this.ftb_h); this.panel2.Controls.Add(this.foxLabel5); - this.panel2.Controls.Add(this.ftb_w); this.panel2.Controls.Add(this.foxLabel4); this.panel2.Dock = System.Windows.Forms.DockStyle.Fill; this.panel2.Location = new System.Drawing.Point(3, 37); this.panel2.Name = "panel2"; - this.panel2.Size = new System.Drawing.Size(260, 73); + this.panel2.Size = new System.Drawing.Size(260, 142); this.panel2.TabIndex = 14; this.panel2.Text = "panel2"; // + // dtb_r + // + this.dtb_r.BackColor = System.Drawing.Color.Silver; + this.dtb_r.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.dtb_r.ColorA = System.Drawing.Color.FromArgb(((int)(((byte)(31)))), ((int)(((byte)(31)))), ((int)(((byte)(31))))); + this.dtb_r.ColorB = System.Drawing.Color.FromArgb(((int)(((byte)(41)))), ((int)(((byte)(41)))), ((int)(((byte)(41))))); + this.dtb_r.ColorC = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(51)))), ((int)(((byte)(51))))); + this.dtb_r.ColorD = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0))))); + this.dtb_r.ColorE = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(255))))); + this.dtb_r.ColorF = System.Drawing.Color.Black; + this.dtb_r.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(128))))); + this.dtb_r.Location = new System.Drawing.Point(144, 5); + this.dtb_r.Name = "dtb_r"; + this.dtb_r.Size = new System.Drawing.Size(80, 21); + this.dtb_r.TabIndex = 10; + this.dtb_r.Text = "10"; + // + // dtb_h + // + this.dtb_h.BackColor = System.Drawing.Color.Silver; + this.dtb_h.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.dtb_h.ColorA = System.Drawing.Color.FromArgb(((int)(((byte)(31)))), ((int)(((byte)(31)))), ((int)(((byte)(31))))); + this.dtb_h.ColorB = System.Drawing.Color.FromArgb(((int)(((byte)(41)))), ((int)(((byte)(41)))), ((int)(((byte)(41))))); + this.dtb_h.ColorC = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(51)))), ((int)(((byte)(51))))); + this.dtb_h.ColorD = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0))))); + this.dtb_h.ColorE = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(255))))); + this.dtb_h.ColorF = System.Drawing.Color.Black; + this.dtb_h.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(128))))); + this.dtb_h.Location = new System.Drawing.Point(35, 34); + this.dtb_h.Name = "dtb_h"; + this.dtb_h.Size = new System.Drawing.Size(80, 21); + this.dtb_h.TabIndex = 9; + this.dtb_h.Text = "10"; + // + // dtb_w + // + this.dtb_w.BackColor = System.Drawing.Color.Silver; + this.dtb_w.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.dtb_w.ColorA = System.Drawing.Color.FromArgb(((int)(((byte)(31)))), ((int)(((byte)(31)))), ((int)(((byte)(31))))); + this.dtb_w.ColorB = System.Drawing.Color.FromArgb(((int)(((byte)(41)))), ((int)(((byte)(41)))), ((int)(((byte)(41))))); + this.dtb_w.ColorC = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(51)))), ((int)(((byte)(51))))); + this.dtb_w.ColorD = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(0))))); + this.dtb_w.ColorE = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(255))))); + this.dtb_w.ColorF = System.Drawing.Color.Black; + this.dtb_w.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(128))))); + this.dtb_w.Location = new System.Drawing.Point(34, 5); + this.dtb_w.Name = "dtb_w"; + this.dtb_w.Size = new System.Drawing.Size(80, 21); + this.dtb_w.TabIndex = 8; + this.dtb_w.Text = "10"; + // + // flb_info + // + this.flb_info.BackColor = System.Drawing.Color.Transparent; + this.flb_info.Font = new System.Drawing.Font("Segoe UI", 10F, System.Drawing.FontStyle.Bold); + this.flb_info.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(76)))), ((int)(((byte)(88)))), ((int)(((byte)(100))))); + this.flb_info.Location = new System.Drawing.Point(1, 101); + this.flb_info.Name = "flb_info"; + this.flb_info.Size = new System.Drawing.Size(223, 19); + this.flb_info.TabIndex = 7; + // // collapseItem2 // this.collapseItem2.Controls.Add(this.tableLayoutPanel3); this.collapseItem2.Expand = true; - this.collapseItem2.Location = new System.Drawing.Point(19, 99); + this.collapseItem2.Location = new System.Drawing.Point(19, 433); this.collapseItem2.Name = "collapseItem2"; - this.collapseItem2.Size = new System.Drawing.Size(266, 113); + this.collapseItem2.Size = new System.Drawing.Size(266, 182); this.collapseItem2.TabIndex = 1; this.collapseItem2.Text = "ROI工具"; // @@ -619,7 +630,8 @@ // collapseItem1 // this.collapseItem1.Controls.Add(this.tableLayoutPanel1); - this.collapseItem1.Location = new System.Drawing.Point(-266, -302); + this.collapseItem1.Expand = true; + this.collapseItem1.Location = new System.Drawing.Point(19, 59); this.collapseItem1.Name = "collapseItem1"; this.collapseItem1.Size = new System.Drawing.Size(266, 302); this.collapseItem1.TabIndex = 0; @@ -632,23 +644,12 @@ this.cll_panel.HeaderBg = System.Drawing.Color.FromArgb(((int)(((byte)(186)))), ((int)(((byte)(179)))), ((int)(((byte)(179))))); this.cll_panel.Items.Add(this.collapseItem1); this.cll_panel.Items.Add(this.collapseItem2); - this.cll_panel.Items.Add(this.collapseItem3); this.cll_panel.Location = new System.Drawing.Point(0, 0); this.cll_panel.Name = "cll_panel"; this.cll_panel.Size = new System.Drawing.Size(304, 495); this.cll_panel.TabIndex = 1; this.cll_panel.Text = "fed"; // - // collapseItem3 - // - this.collapseItem3.Expand = true; - this.collapseItem3.Location = new System.Drawing.Point(19, 284); - this.collapseItem3.Margin = new System.Windows.Forms.Padding(2); - this.collapseItem3.Name = "collapseItem3"; - this.collapseItem3.Size = new System.Drawing.Size(266, 154); - this.collapseItem3.TabIndex = 3; - this.collapseItem3.Text = "collapseItem3"; - // // BioanayImagePaletteForm // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F); @@ -662,6 +663,7 @@ ((System.ComponentModel.ISupportInitialize)(this.hpb_line)).EndInit(); this.tableLayoutPanel3.ResumeLayout(false); this.panel2.ResumeLayout(false); + this.panel2.PerformLayout(); this.collapseItem2.ResumeLayout(false); this.tableLayoutPanel2.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.nud_colorMax)).EndInit(); @@ -678,12 +680,8 @@ } #endregion - - private ReaLTaiizor.Controls.FoxButton fb_fixSetting; private ReaLTaiizor.Controls.FoxLabel foxLabel7; - private ReaLTaiizor.Controls.FoxTextBox ftb_h; private ReaLTaiizor.Controls.FoxLabel foxLabel5; - private ReaLTaiizor.Controls.FoxTextBox ftb_w; private ReaLTaiizor.Controls.FoxLabel foxLabel8; private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2; private ReaLTaiizor.Controls.FoxLabel foxLabel9; @@ -693,7 +691,6 @@ private ReaLTaiizor.Controls.FoxLabel foxLabel1; private System.Windows.Forms.PictureBox pb_bgimage; private ReaLTaiizor.Controls.FoxLabel foxLabel4; - private ReaLTaiizor.Controls.FoxTextBox ftb_r; private System.Windows.Forms.TableLayoutPanel tableLayoutPanel3; private AntdUI.Panel panel2; private AntdUI.CollapseItem collapseItem2; @@ -701,7 +698,6 @@ private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1; private AntdUI.CollapseItem collapseItem1; private AntdUI.Collapse cll_panel; - private AntdUI.CollapseItem collapseItem3; public ReaLTaiizor.Controls.DungeonTrackBar dtb_brightness; public ReaLTaiizor.Controls.DungeonTrackBar dtb_colorMax; public ReaLTaiizor.Controls.DungeonTrackBar dtb_colorMin; @@ -717,5 +713,10 @@ public AntdUI.Avatar hpb_rect; public AntdUI.Avatar hpb_xianduan; public AntdUI.Avatar hpb_wand; + private ReaLTaiizor.Controls.FoxLabel flb_info; + public ReaLTaiizor.Controls.FoxButton fb_fixSetting; + private ReaLTaiizor.Controls.DreamTextBox dtb_r; + private ReaLTaiizor.Controls.DreamTextBox dtb_h; + private ReaLTaiizor.Controls.DreamTextBox dtb_w; } } \ No newline at end of file diff --git a/src/PBAnaly/UI/BioanayImagePaletteForm.cs b/src/PBAnaly/UI/BioanayImagePaletteForm.cs index ca947dc..47d23a8 100644 --- a/src/PBAnaly/UI/BioanayImagePaletteForm.cs +++ b/src/PBAnaly/UI/BioanayImagePaletteForm.cs @@ -25,18 +25,32 @@ namespace PBAnaly.UI #region 对外接口 public int ROI_W { - get { return roi_w; } - set { roi_w = value; ftb_w.Text = roi_w.ToString(); } + get { + roi_w = Convert.ToInt32(dtb_w.Text.ToString()); + return roi_w; + } + set { roi_w = value; dtb_w.Text = roi_w.ToString(); } } public int ROI_H { - get { return roi_h; } - set { roi_h = value; ftb_h.Text = roi_h.ToString(); } + get { + roi_h = Convert.ToInt32(dtb_h.Text.ToString()); + return roi_h; + } + set { roi_h = value; dtb_h.Text = roi_h.ToString(); } } public int CIRCLE_R { - get { return circle_r; } - set { circle_r = value; ftb_r.Text = circle_r.ToString(); } + get { + circle_r = Convert.ToInt32(dtb_r.Text.ToString()); + return circle_r; + } + set { circle_r = value; dtb_r.Text = circle_r.ToString(); } + } + + public string SetInfo + { + set { flb_info.Text = value; flb_info.Refresh(); } } #endregion }