Commit a2f307bf LN

形状和极性分开

1 个父辈 3ee55dd0
...@@ -227,7 +227,7 @@ namespace TSA_V.DeviceLibrary ...@@ -227,7 +227,7 @@ namespace TSA_V.DeviceLibrary
PositionY = 0; PositionY = 0;
} }
public SMTPointInfo(int num, string partNum, string name, double positionX, double positionY, string PositionNum,string showText, public SMTPointInfo(int num, string partNum, string name, double positionX, double positionY, string PositionNum,string showText,
int pointType=1,int pointSizex=1,int pointSizeY=1,int penWidth =2, int pointType=1,int pointSizex=1,int pointSizeY=1,int penWidth =2, int PolaritiesType=0,
bool needs = false, bool needc = false, int sTemp = 0, double sTime = 0) bool needs = false, bool needc = false, int sTemp = 0, double sTime = 0)
{ {
this.TagNo = partNum; this.TagNo = partNum;
...@@ -245,6 +245,7 @@ namespace TSA_V.DeviceLibrary ...@@ -245,6 +245,7 @@ namespace TSA_V.DeviceLibrary
this.PointSizeY = pointSizeY; this.PointSizeY = pointSizeY;
this.PenWidth = penWidth; this.PenWidth = penWidth;
this.ShowText = showText; this.ShowText = showText;
this.PolaritiesType = PolaritiesType;
//if (String.IsNullOrEmpty(this.ShowText)) //if (String.IsNullOrEmpty(this.ShowText))
//{ //{
// this.ShowText = name; // this.ShowText = name;
...@@ -378,6 +379,11 @@ namespace TSA_V.DeviceLibrary ...@@ -378,6 +379,11 @@ namespace TSA_V.DeviceLibrary
public bool IsEdit = false; public bool IsEdit = false;
/// <summary> /// <summary>
/// 极性,
/// </summary>
public int PolaritiesType = 0;
/// <summary>
/// 导出导入程序时使用 /// 导出导入程序时使用
/// </summary> /// </summary>
public ComponetInfo componet; public ComponetInfo componet;
......
...@@ -8,7 +8,7 @@ namespace TSA_V.DeviceLibrary ...@@ -8,7 +8,7 @@ namespace TSA_V.DeviceLibrary
{ {
public class ProjectorPInfo public class ProjectorPInfo
{ {
public ProjectorPInfo(int x, int y, int type=1, int sizeX=4, int sizeY=4,int lineWidth=2,string showText="",int color=-1) public ProjectorPInfo(int x, int y, int type=1,int polaritiesType=0, int sizeX=4, int sizeY=4,int lineWidth=2,string showText="",int color=-1)
{ {
this.PX = x; this.PX = x;
this.PY = y; this.PY = y;
...@@ -18,6 +18,7 @@ namespace TSA_V.DeviceLibrary ...@@ -18,6 +18,7 @@ namespace TSA_V.DeviceLibrary
this.PenWidth = lineWidth; this.PenWidth = lineWidth;
this.ShowText = showText; this.ShowText = showText;
this.showColor = color; this.showColor = color;
this.PolaritiesType= polaritiesType;
} }
public int PX = 2; public int PX = 2;
public int PY = 2; public int PY = 2;
...@@ -33,5 +34,10 @@ namespace TSA_V.DeviceLibrary ...@@ -33,5 +34,10 @@ namespace TSA_V.DeviceLibrary
public string ShowText = ""; public string ShowText = "";
public int showColor = -1; public int showColor = -1;
/// <summary>
/// 极性,
/// </summary>
public int PolaritiesType = 0;
} }
} }
...@@ -87,6 +87,13 @@ namespace TSA_V.DeviceLibrary ...@@ -87,6 +87,13 @@ namespace TSA_V.DeviceLibrary
needSave = true; needSave = true;
sm.PN = sm.pointName; ; sm.PN = sm.pointName; ;
} }
if (sm.PointType > 6)
{
//极性处理
needSave = true;
sm.PolaritiesType = sm.PointType - 6;
sm.PointType =5;
}
} }
if (board.boardId > MaxId) if (board.boardId > MaxId)
......
...@@ -331,9 +331,9 @@ namespace TSA_V.DeviceLibrary ...@@ -331,9 +331,9 @@ namespace TSA_V.DeviceLibrary
} }
public delegate bool ShowPointDelegate(ProjectorPInfo p ); public delegate bool ShowPointDelegate(ProjectorPInfo p );
public static event ShowPointDelegate ShowPointEvent; public static event ShowPointDelegate ShowPointEvent;
public static void ShowPoint(double x, double y, int type = 1, int sizex = 1, int sizey = 1, int penWidth = 2, string name = "",int color=-1) public static void ShowPoint(double x, double y, int type = 1,int polaritiesType=0, int sizex = 1, int sizey = 1, int penWidth = 2, string name = "",int color=-1)
{ {
ProjectorPInfo p = new ProjectorPInfo((int)x, (int)y, type, sizex, sizey, penWidth, name,color); ProjectorPInfo p = new ProjectorPInfo((int)x, (int)y, type, polaritiesType, sizex, sizey, penWidth, name,color);
ShowPointEvent?.Invoke(p); ShowPointEvent?.Invoke(p);
} }
......
...@@ -294,7 +294,7 @@ namespace TSA_V.DeviceLibrary ...@@ -294,7 +294,7 @@ namespace TSA_V.DeviceLibrary
if (TSAVBean.IsValidPosition(currPoint.NodePositionX, currPoint.NodePositionY)) if (TSAVBean.IsValidPosition(currPoint.NodePositionX, currPoint.NodePositionY))
{ {
//LogUtil.info(" 程序【" + currBoard.boardName + "】插件【" + currPoint.pointName + "】,X轴【" + currPoint.NodePositionX + "】,Y轴【" + currPoint.NodePositionY + "】"); //LogUtil.info(" 程序【" + currBoard.boardName + "】插件【" + currPoint.pointName + "】,X轴【" + currPoint.NodePositionX + "】,Y轴【" + currPoint.NodePositionY + "】");
TSAVBean.ShowPoint(currPoint.NodePositionX, currPoint.NodePositionY, currPoint.PointType, currPoint.PointSizeX, currPoint.PointSizeY, currPoint.PenWidth, currPoint.ShowText, currBoard.PointColor); TSAVBean.ShowPoint(currPoint.NodePositionX, currPoint.NodePositionY, currPoint.PointType,currPoint.PolaritiesType, currPoint.PointSizeX, currPoint.PointSizeY, currPoint.PenWidth, currPoint.ShowText, currBoard.PointColor);
waitList.Add(WaitResultInfo.WaitTime(1000)); waitList.Add(WaitResultInfo.WaitTime(1000));
} }
else else
......
...@@ -2657,4 +2657,6 @@ ...@@ -2657,4 +2657,6 @@
<data name = "FrmCalibrate_lblMsg_Text" xml:space = "preserve"> <value> Step 1: Move the projection cursor to the upper left corner of the board </value> </data> <data name = "FrmCalibrate_lblMsg_Text" xml:space = "preserve"> <value> Step 1: Move the projection cursor to the upper left corner of the board </value> </data>
<data name = "CalMsg2" xml:space = "preserve"> <value> Step 2: Move the projection cursor to the lower right corner of the board </value> </data> <data name = "CalMsg2" xml:space = "preserve"> <value> Step 2: Move the projection cursor to the lower right corner of the board </value> </data>
<data name = "CalMsg3" xml:space = "preserve"> <value> Step 3: Click the Start Calibration button </value> </data> <data name = "CalMsg3" xml:space = "preserve"> <value> Step 3: Click the Start Calibration button </value> </data>
<data name = "Type_None" xml:space = "preserve"> <value> None </value> </data>
<data name = "FrmPointInfo_lblPolarities_Text" xml:space = "preserve"> <value> Polarity </value> </data>
</root> </root>
\ No newline at end of file \ No newline at end of file
...@@ -2641,4 +2641,6 @@ ...@@ -2641,4 +2641,6 @@
<data name = "FrmCalibrate_lblMsg_Text" xml:space = "preserve"> <value> 第一步:请将光标移动至如图示电路板左上角位置,确认后点击设置按钮 </value> </data> <data name = "FrmCalibrate_lblMsg_Text" xml:space = "preserve"> <value> 第一步:请将光标移动至如图示电路板左上角位置,确认后点击设置按钮 </value> </data>
<data name = "CalMsg2" xml:space = "preserve"> <value> 第二步:请将光标移动至如图示电路板右下角位置,确认后点击设置按钮 </value> </data> <data name = "CalMsg2" xml:space = "preserve"> <value> 第二步:请将光标移动至如图示电路板右下角位置,确认后点击设置按钮 </value> </data>
<data name = "CalMsg3" xml:space = "preserve"> <value> 第三步:请点击开始校准按钮,自动计算投影坐标 </value> </data> <data name = "CalMsg3" xml:space = "preserve"> <value> 第三步:请点击开始校准按钮,自动计算投影坐标 </value> </data>
<data name = "Type_None" xml:space = "preserve"> <value> 无 </value> </data>
<data name = "FrmPointInfo_lblPolarities_Text" xml:space = "preserve"> <value> 极性 </value> </data>
</root> </root>
\ No newline at end of file \ No newline at end of file
...@@ -2656,4 +2656,6 @@ ...@@ -2656,4 +2656,6 @@
<data name = "FrmCalibrate_lblMsg_Text" xml:space = "preserve"> <value> 第一步:请将光标移动至如图示电路板左上角位置,确认后点击设置按钮 </value> </data> <data name = "FrmCalibrate_lblMsg_Text" xml:space = "preserve"> <value> 第一步:请将光标移动至如图示电路板左上角位置,确认后点击设置按钮 </value> </data>
<data name = "CalMsg2" xml:space = "preserve"> <value> 第二步:请将光标移动至如图示电路板右下角位置,确认后点击设置按钮 </value> </data> <data name = "CalMsg2" xml:space = "preserve"> <value> 第二步:请将光标移动至如图示电路板右下角位置,确认后点击设置按钮 </value> </data>
<data name = "CalMsg3" xml:space = "preserve"> <value> 第三步:请点击开始校准按钮,自动计算投影坐标 </value> </data> <data name = "CalMsg3" xml:space = "preserve"> <value> 第三步:请点击开始校准按钮,自动计算投影坐标 </value> </data>
<data name = "Type_None" xml:space = "preserve"> <value> 无 </value> </data>
<data name = "FrmPointInfo_lblPolarities_Text" xml:space = "preserve"> <value> 极性 </value> </data>
</root> </root>
\ No newline at end of file \ No newline at end of file
...@@ -168,6 +168,7 @@ namespace TSA_V ...@@ -168,6 +168,7 @@ namespace TSA_V
controlTextMap.Add("btnShowPoint_Text", ResourceCulture.GetString("FrmPointInfo_btnShowPoint_Text", "移动测试")); controlTextMap.Add("btnShowPoint_Text", ResourceCulture.GetString("FrmPointInfo_btnShowPoint_Text", "移动测试"));
controlTextMap.Add("btnLeft_Text", ResourceCulture.GetString("FrmPointInfo_btnLeft_Text", "左移")); controlTextMap.Add("btnLeft_Text", ResourceCulture.GetString("FrmPointInfo_btnLeft_Text", "左移"));
controlTextMap.Add("btnRight_Text", ResourceCulture.GetString("FrmPointInfo_btnRight_Text", "右移")); controlTextMap.Add("btnRight_Text", ResourceCulture.GetString("FrmPointInfo_btnRight_Text", "右移"));
controlTextMap.Add("lblPolarities_Text", ResourceCulture.GetString("FrmPointInfo_lblPolarities_Text", "极性"));
return controlTextMap; return controlTextMap;
} }
...@@ -188,14 +189,45 @@ namespace TSA_V ...@@ -188,14 +189,45 @@ namespace TSA_V
"4=━━", "4=━━",
"5=□", "5=□",
"6=○", "6=○",
"7="+str7, //"7="+str7,
"8="+str8, //"8="+str8,
"9="+str9, //"9="+str9,
"10="+str10, //"10="+str10,
"11="+str11, //"11="+str11,
"12="+str12, //"12="+str12,
"13="+str13, //"13="+str13,
"14="+str14 //"14="+str14
};
return typeList;
}
public static string[] GetDirTypes()
{
string str7 = ResourceCulture.GetString(ResourceCulture.Type7, "极性_上方");
string str8 = ResourceCulture.GetString(ResourceCulture.Type8, "极性_下方");
string str9 = ResourceCulture.GetString(ResourceCulture.Type9, "极性_左方");
string str10 = ResourceCulture.GetString(ResourceCulture.Type10, "极性_右方");
string str11 = ResourceCulture.GetString(ResourceCulture.Type11, "极性_左上方");
string str12 = ResourceCulture.GetString(ResourceCulture.Type12, "极性_右上方");
string str13 = ResourceCulture.GetString(ResourceCulture.Type13, "极性_左下方");
string str14 = ResourceCulture.GetString(ResourceCulture.Type14, "极性_右下方");
string wu = ResourceCulture.GetString(ResourceCulture.Type_None, "无");
string[] typeList = new string[] {
//"1=●",
//"2=✚",
//"3=┃",
//"4=━━",
//"5=□",
//"6=○",
"0="+wu,
"1="+str7,
"2="+str8,
"3="+str9,
"4="+str10,
"5="+str11,
"6="+str12,
"7="+str13,
"8="+str14
}; };
return typeList; return typeList;
...@@ -860,6 +892,10 @@ namespace TSA_V ...@@ -860,6 +892,10 @@ namespace TSA_V
/// 极性_右下方 /// 极性_右下方
/// </summary> /// </summary>
internal static readonly string Type14 = "Type14"; internal static readonly string Type14 = "Type14";
/// <summary>
/// 无
/// </summary>
internal static readonly string Type_None= "无";
internal static readonly string CreateNew = "CreateNew"; internal static readonly string CreateNew = "CreateNew";
} }
......
...@@ -120,6 +120,12 @@ ...@@ -120,6 +120,12 @@
<Reference Include="System.Xml" /> <Reference Include="System.Xml" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Compile Include="frmBoard\FrmBomUpload.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="frmBoard\FrmBomUpload.Designer.cs">
<DependentUpon>FrmBomUpload.cs</DependentUpon>
</Compile>
<Compile Include="frmBoard\FrmCalibrate.cs"> <Compile Include="frmBoard\FrmCalibrate.cs">
<SubType>Form</SubType> <SubType>Form</SubType>
</Compile> </Compile>
...@@ -362,6 +368,9 @@ ...@@ -362,6 +368,9 @@
<EmbeddedResource Include="frmBoard\FrmBoardList.resx"> <EmbeddedResource Include="frmBoard\FrmBoardList.resx">
<DependentUpon>FrmBoardList.cs</DependentUpon> <DependentUpon>FrmBoardList.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>
<EmbeddedResource Include="frmBoard\FrmBomUpload.resx">
<DependentUpon>FrmBomUpload.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="frmBoard\FrmCalibrate.resx"> <EmbeddedResource Include="frmBoard\FrmCalibrate.resx">
<DependentUpon>FrmCalibrate.cs</DependentUpon> <DependentUpon>FrmCalibrate.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>
......
...@@ -57,6 +57,7 @@ ...@@ -57,6 +57,7 @@
this.label9 = new System.Windows.Forms.Label(); this.label9 = new System.Windows.Forms.Label();
this.txtCsvFileName = new System.Windows.Forms.TextBox(); this.txtCsvFileName = new System.Windows.Forms.TextBox();
this.groupBoxSelCom = new System.Windows.Forms.GroupBox(); this.groupBoxSelCom = new System.Windows.Forms.GroupBox();
this.rbBom = new System.Windows.Forms.RadioButton();
this.likSelCsvFile = new System.Windows.Forms.LinkLabel(); this.likSelCsvFile = new System.Windows.Forms.LinkLabel();
this.likDownFile = new System.Windows.Forms.LinkLabel(); this.likDownFile = new System.Windows.Forms.LinkLabel();
this.rdbUpload = new System.Windows.Forms.RadioButton(); this.rdbUpload = new System.Windows.Forms.RadioButton();
...@@ -67,7 +68,6 @@ ...@@ -67,7 +68,6 @@
this.groupBox_new = new System.Windows.Forms.GroupBox(); this.groupBox_new = new System.Windows.Forms.GroupBox();
this.linkLabel3 = new System.Windows.Forms.LinkLabel(); this.linkLabel3 = new System.Windows.Forms.LinkLabel();
this.linkLabel2 = new System.Windows.Forms.LinkLabel(); this.linkLabel2 = new System.Windows.Forms.LinkLabel();
this.radioButton1 = new System.Windows.Forms.RadioButton();
this.groupBoxSelCom.SuspendLayout(); this.groupBoxSelCom.SuspendLayout();
this.groupBox_new.SuspendLayout(); this.groupBox_new.SuspendLayout();
this.SuspendLayout(); this.SuspendLayout();
...@@ -342,7 +342,7 @@ ...@@ -342,7 +342,7 @@
// //
// groupBoxSelCom // groupBoxSelCom
// //
this.groupBoxSelCom.Controls.Add(this.radioButton1); this.groupBoxSelCom.Controls.Add(this.rbBom);
this.groupBoxSelCom.Controls.Add(this.likSelCsvFile); this.groupBoxSelCom.Controls.Add(this.likSelCsvFile);
this.groupBoxSelCom.Controls.Add(this.likDownFile); this.groupBoxSelCom.Controls.Add(this.likDownFile);
this.groupBoxSelCom.Controls.Add(this.rdbUpload); this.groupBoxSelCom.Controls.Add(this.rdbUpload);
...@@ -350,13 +350,25 @@ ...@@ -350,13 +350,25 @@
this.groupBoxSelCom.Controls.Add(this.cmbBomList); this.groupBoxSelCom.Controls.Add(this.cmbBomList);
this.groupBoxSelCom.Controls.Add(this.txtCsvFileName); this.groupBoxSelCom.Controls.Add(this.txtCsvFileName);
this.groupBoxSelCom.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.groupBoxSelCom.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.groupBoxSelCom.Location = new System.Drawing.Point(390, 12); this.groupBoxSelCom.Location = new System.Drawing.Point(390, 6);
this.groupBoxSelCom.Name = "groupBoxSelCom"; this.groupBoxSelCom.Name = "groupBoxSelCom";
this.groupBoxSelCom.Size = new System.Drawing.Size(273, 317); this.groupBoxSelCom.Size = new System.Drawing.Size(273, 317);
this.groupBoxSelCom.TabIndex = 298; this.groupBoxSelCom.TabIndex = 298;
this.groupBoxSelCom.TabStop = false; this.groupBoxSelCom.TabStop = false;
this.groupBoxSelCom.Text = "请选择元器件库"; this.groupBoxSelCom.Text = "请选择元器件库";
// //
// rbBom
//
this.rbBom.AutoSize = true;
this.rbBom.Location = new System.Drawing.Point(7, 271);
this.rbBom.Name = "rbBom";
this.rbBom.Size = new System.Drawing.Size(80, 21);
this.rbBom.TabIndex = 302;
this.rbBom.TabStop = true;
this.rbBom.Text = "BOM上传";
this.rbBom.UseVisualStyleBackColor = true;
this.rbBom.CheckedChanged += new System.EventHandler(this.rbBom_CheckedChanged);
//
// likSelCsvFile // likSelCsvFile
// //
this.likSelCsvFile.AutoSize = true; this.likSelCsvFile.AutoSize = true;
...@@ -419,16 +431,18 @@ ...@@ -419,16 +431,18 @@
// xyMoveControl1 // xyMoveControl1
// //
this.xyMoveControl1.BackColor = System.Drawing.Color.White; this.xyMoveControl1.BackColor = System.Drawing.Color.White;
this.xyMoveControl1.Cursor = System.Windows.Forms.Cursors.Default;
this.xyMoveControl1.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.xyMoveControl1.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.xyMoveControl1.GroupName = "坐标"; this.xyMoveControl1.GroupName = "坐标";
this.xyMoveControl1.Location = new System.Drawing.Point(16, 335); this.xyMoveControl1.Location = new System.Drawing.Point(16, 325);
this.xyMoveControl1.Name = "xyMoveControl1"; this.xyMoveControl1.Name = "xyMoveControl1";
this.xyMoveControl1.PenWidth = 2; this.xyMoveControl1.PenWidth = 2;
this.xyMoveControl1.PointSizeX = 5; this.xyMoveControl1.PointSizeX = 5;
this.xyMoveControl1.PointSizeY = 5; this.xyMoveControl1.PointSizeY = 5;
this.xyMoveControl1.PointType = 1; this.xyMoveControl1.PointType = 1;
this.xyMoveControl1.PolaritiesType = 0;
this.xyMoveControl1.ShowText = ""; this.xyMoveControl1.ShowText = "";
this.xyMoveControl1.Size = new System.Drawing.Size(654, 303); this.xyMoveControl1.Size = new System.Drawing.Size(654, 316);
this.xyMoveControl1.TabIndex = 287; this.xyMoveControl1.TabIndex = 287;
this.xyMoveControl1.XValue = 1D; this.xyMoveControl1.XValue = 1D;
this.xyMoveControl1.YValue = 1D; this.xyMoveControl1.YValue = 1D;
...@@ -455,7 +469,7 @@ ...@@ -455,7 +469,7 @@
this.groupBox_new.Controls.Add(this.txtBoardL); this.groupBox_new.Controls.Add(this.txtBoardL);
this.groupBox_new.Controls.Add(this.label5); this.groupBox_new.Controls.Add(this.label5);
this.groupBox_new.Controls.Add(this.label4); this.groupBox_new.Controls.Add(this.label4);
this.groupBox_new.Location = new System.Drawing.Point(21, 12); this.groupBox_new.Location = new System.Drawing.Point(21, 6);
this.groupBox_new.Name = "groupBox_new"; this.groupBox_new.Name = "groupBox_new";
this.groupBox_new.Size = new System.Drawing.Size(363, 317); this.groupBox_new.Size = new System.Drawing.Size(363, 317);
this.groupBox_new.TabIndex = 303; this.groupBox_new.TabIndex = 303;
...@@ -485,21 +499,10 @@ ...@@ -485,21 +499,10 @@
this.linkLabel2.Text = "选择Gerber文件"; this.linkLabel2.Text = "选择Gerber文件";
this.linkLabel2.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabel2_LinkClicked); this.linkLabel2.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabel2_LinkClicked);
// //
// radioButton1
//
this.radioButton1.AutoSize = true;
this.radioButton1.Location = new System.Drawing.Point(7, 271);
this.radioButton1.Name = "radioButton1";
this.radioButton1.Size = new System.Drawing.Size(80, 21);
this.radioButton1.TabIndex = 302;
this.radioButton1.TabStop = true;
this.radioButton1.Text = "BOM上传";
this.radioButton1.UseVisualStyleBackColor = true;
//
// FrmAddBoard // FrmAddBoard
// //
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.ClientSize = new System.Drawing.Size(688, 778); this.ClientSize = new System.Drawing.Size(688, 740);
this.Controls.Add(this.groupBox_new); this.Controls.Add(this.groupBox_new);
this.Controls.Add(this.groupBoxSelCom); this.Controls.Add(this.groupBoxSelCom);
this.Controls.Add(this.chbSort); this.Controls.Add(this.chbSort);
...@@ -561,6 +564,6 @@ ...@@ -561,6 +564,6 @@
private System.Windows.Forms.GroupBox groupBox_new; private System.Windows.Forms.GroupBox groupBox_new;
private System.Windows.Forms.LinkLabel linkLabel2; private System.Windows.Forms.LinkLabel linkLabel2;
private System.Windows.Forms.LinkLabel linkLabel3; private System.Windows.Forms.LinkLabel linkLabel3;
private System.Windows.Forms.RadioButton radioButton1; private System.Windows.Forms.RadioButton rbBom;
} }
} }
\ No newline at end of file \ No newline at end of file
...@@ -12,6 +12,7 @@ using System.Threading.Tasks; ...@@ -12,6 +12,7 @@ using System.Threading.Tasks;
using System.Windows.Forms; using System.Windows.Forms;
using TSA_V.Common; using TSA_V.Common;
using TSA_V.DeviceLibrary; using TSA_V.DeviceLibrary;
using TSA_V.frmBoard;
using TSA_V.LoadCSVLibrary; using TSA_V.LoadCSVLibrary;
using UserFromControl; using UserFromControl;
...@@ -40,7 +41,7 @@ namespace TSA_V ...@@ -40,7 +41,7 @@ namespace TSA_V
//"10="+str10 //"10="+str10
//}; //};
xyMoveControl1.loadTypeList(ResourceCulture.GetPTypes(), ResourceCulture.GetXYControlMap()); xyMoveControl1.loadTypeList(ResourceCulture.GetPTypes(), ResourceCulture.GetDirTypes(), ResourceCulture.GetXYControlMap());
} }
private void btnCancel_Click(object sender, EventArgs e) private void btnCancel_Click(object sender, EventArgs e)
...@@ -175,6 +176,7 @@ namespace TSA_V ...@@ -175,6 +176,7 @@ namespace TSA_V
int pointSizeY = xyMoveControl1.PointSizeY; int pointSizeY = xyMoveControl1.PointSizeY;
int pointType = xyMoveControl1.PointType; int pointType = xyMoveControl1.PointType;
int penWidth = xyMoveControl1.PenWidth; int penWidth = xyMoveControl1.PenWidth;
int PolaritiesType = xyMoveControl1.PolaritiesType;
foreach (ComponetInfo com in comList) foreach (ComponetInfo com in comList)
{ {
double x =com.PositionX+ pianYiX; double x =com.PositionX+ pianYiX;
...@@ -195,7 +197,7 @@ namespace TSA_V ...@@ -195,7 +197,7 @@ namespace TSA_V
y = board.boardLength - y; y = board.boardLength - y;
x = board.boardWidth - x; x = board.boardWidth - x;
} }
SMTPointInfo point = new SMTPointInfo(i, com.TagNo, com.PN, x, y, com.PositionNum,com.Text, pointType,pointSizeX,pointSizeY,penWidth); SMTPointInfo point = new SMTPointInfo(i, com.TagNo, com.PN, x, y, com.PositionNum,com.Text, pointType,pointSizeX,pointSizeY,penWidth, PolaritiesType);
y = board.boardLength - y; y = board.boardLength - y;
...@@ -323,7 +325,7 @@ namespace TSA_V ...@@ -323,7 +325,7 @@ namespace TSA_V
xyMoveControl1.ShowText = ""; xyMoveControl1.ShowText = "";
rdbUpload.Checked = true; rdbUpload.Checked = true;
ComChange(true); ComChange( );
if (IOBase.NoLine) if (IOBase.NoLine)
{ {
...@@ -357,23 +359,40 @@ namespace TSA_V ...@@ -357,23 +359,40 @@ namespace TSA_V
xyMoveControl1.UpdateStatus(); xyMoveControl1.UpdateStatus();
} }
private void ComChange(bool isUploadSel) private void ComChange( )
{ {
txtCsvFileName.Visible = isUploadSel; if (rdbUpload.Checked) {
likDownFile.Visible = isUploadSel; txtCsvFileName.Visible = true ;
likSelCsvFile.Visible = isUploadSel; likDownFile.Visible = true ;
likSelCsvFile.Visible = true;
cmbBomList.Visible = false ;
}
else if (rdbSelCom.Checked)
{
txtCsvFileName.Visible = false ;
likDownFile.Visible = false ;
likSelCsvFile.Visible = false ;
cmbBomList.Visible = true ;
}
else if (rbBom.Checked)
{
FrmBomUpload frm = new FrmBomUpload();
DialogResult resut= frm.ShowDialog();
if(resut.Equals(DialogResult.OK) )
{
cmbBomList.Visible = !isUploadSel;
}
}
} }
private void rdbUpload_CheckedChanged(object sender, EventArgs e) private void rdbUpload_CheckedChanged(object sender, EventArgs e)
{ {
ComChange(rdbUpload.Checked); ComChange( );
} }
private void rdbSelCom_CheckedChanged(object sender, EventArgs e) private void rdbSelCom_CheckedChanged(object sender, EventArgs e)
{ {
ComChange(!rdbSelCom.Checked); ComChange( );
} }
private void btnOpenFile_Click(object sender, LinkLabelLinkClickedEventArgs e) private void btnOpenFile_Click(object sender, LinkLabelLinkClickedEventArgs e)
...@@ -552,5 +571,10 @@ namespace TSA_V ...@@ -552,5 +571,10 @@ namespace TSA_V
{ {
} }
private void rbBom_CheckedChanged(object sender, EventArgs e)
{
ComChange();
}
} }
} }
...@@ -28,15 +28,14 @@ ...@@ -28,15 +28,14 @@
/// </summary> /// </summary>
private void InitializeComponent() private void InitializeComponent()
{ {
this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmBoardInfo)); System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmBoardInfo));
this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip(this.components); this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip();
this.记录为组装坐标ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.记录为组装坐标ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.更新为组装坐标ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.更新为组装坐标ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.新增ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.新增ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.openFileDialog1 = new System.Windows.Forms.OpenFileDialog(); this.openFileDialog1 = new System.Windows.Forms.OpenFileDialog();
this.toolTip1 = new System.Windows.Forms.ToolTip(this.components); this.toolTip1 = new System.Windows.Forms.ToolTip();
this.contextMenuStrip2 = new System.Windows.Forms.ContextMenuStrip(this.components); this.contextMenuStrip2 = new System.Windows.Forms.ContextMenuStrip();
this.测试位置ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.测试位置ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.详情ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.详情ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.删除ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.删除ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
...@@ -47,7 +46,7 @@ ...@@ -47,7 +46,7 @@
this.全部启用ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.全部启用ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.全部禁用ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.全部禁用ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.自动排序ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.自动排序ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.timer1 = new System.Windows.Forms.Timer(this.components); this.timer1 = new System.Windows.Forms.Timer();
this.backgroundWorker1 = new System.ComponentModel.BackgroundWorker(); this.backgroundWorker1 = new System.ComponentModel.BackgroundWorker();
this.dataGridViewImageColumn1 = new System.Windows.Forms.DataGridViewImageColumn(); this.dataGridViewImageColumn1 = new System.Windows.Forms.DataGridViewImageColumn();
this.dataGridViewImageColumn2 = new System.Windows.Forms.DataGridViewImageColumn(); this.dataGridViewImageColumn2 = new System.Windows.Forms.DataGridViewImageColumn();
...@@ -115,6 +114,7 @@ ...@@ -115,6 +114,7 @@
this.Column_disable = new System.Windows.Forms.DataGridViewCheckBoxColumn(); this.Column_disable = new System.Windows.Forms.DataGridViewCheckBoxColumn();
this.Column_Notes = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column_Notes = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.col_IsEdit = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.col_IsEdit = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.col_Polarities = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column_getPosition = new System.Windows.Forms.DataGridViewLinkColumn(); this.Column_getPosition = new System.Windows.Forms.DataGridViewLinkColumn();
this.Column_MoveTest = new System.Windows.Forms.DataGridViewLinkColumn(); this.Column_MoveTest = new System.Windows.Forms.DataGridViewLinkColumn();
this.Column_btnDetail = new System.Windows.Forms.DataGridViewLinkColumn(); this.Column_btnDetail = new System.Windows.Forms.DataGridViewLinkColumn();
...@@ -594,6 +594,7 @@ ...@@ -594,6 +594,7 @@
this.Column_disable, this.Column_disable,
this.Column_Notes, this.Column_Notes,
this.col_IsEdit, this.col_IsEdit,
this.col_Polarities,
this.Column_getPosition, this.Column_getPosition,
this.Column_MoveTest, this.Column_MoveTest,
this.Column_btnDetail, this.Column_btnDetail,
...@@ -979,6 +980,12 @@ ...@@ -979,6 +980,12 @@
this.col_IsEdit.ReadOnly = true; this.col_IsEdit.ReadOnly = true;
this.col_IsEdit.Visible = false; this.col_IsEdit.Visible = false;
// //
// col_Polarities
//
this.col_Polarities.HeaderText = "极性";
this.col_Polarities.Name = "col_Polarities";
this.col_Polarities.Visible = false;
//
// Column_getPosition // Column_getPosition
// //
this.Column_getPosition.HeaderText = "更新坐标"; this.Column_getPosition.HeaderText = "更新坐标";
...@@ -1164,6 +1171,7 @@ ...@@ -1164,6 +1171,7 @@
private System.Windows.Forms.DataGridViewCheckBoxColumn Column_disable; private System.Windows.Forms.DataGridViewCheckBoxColumn Column_disable;
private System.Windows.Forms.DataGridViewTextBoxColumn Column_Notes; private System.Windows.Forms.DataGridViewTextBoxColumn Column_Notes;
private System.Windows.Forms.DataGridViewTextBoxColumn col_IsEdit; private System.Windows.Forms.DataGridViewTextBoxColumn col_IsEdit;
private System.Windows.Forms.DataGridViewTextBoxColumn col_Polarities;
private System.Windows.Forms.DataGridViewLinkColumn Column_getPosition; private System.Windows.Forms.DataGridViewLinkColumn Column_getPosition;
private System.Windows.Forms.DataGridViewLinkColumn Column_MoveTest; private System.Windows.Forms.DataGridViewLinkColumn Column_MoveTest;
private System.Windows.Forms.DataGridViewLinkColumn Column_btnDetail; private System.Windows.Forms.DataGridViewLinkColumn Column_btnDetail;
......
...@@ -314,6 +314,7 @@ namespace TSA_V ...@@ -314,6 +314,7 @@ namespace TSA_V
view.Cells[Column_ShowText.Index].Value = point.ShowText; view.Cells[Column_ShowText.Index].Value = point.ShowText;
view.Cells[Column_disable.Index].Value = point.Disable; view.Cells[Column_disable.Index].Value = point.Disable;
view.Cells[col_IsEdit.Index].Value=point.IsEdit; view.Cells[col_IsEdit.Index].Value=point.IsEdit;
view.Cells[col_Polarities.Index].Value = point.PolaritiesType;
if (updateBoardInfo != null) if (updateBoardInfo != null)
{ {
...@@ -492,6 +493,7 @@ namespace TSA_V ...@@ -492,6 +493,7 @@ namespace TSA_V
int penWidth = Int32.Parse(dgvList.Rows[rowIndex].Cells[this.Column_PenWidth.Name].Value.ToString()); int penWidth = Int32.Parse(dgvList.Rows[rowIndex].Cells[this.Column_PenWidth.Name].Value.ToString());
string name = dgvList.Rows[rowIndex].Cells[this.Column_Name.Name].Value.ToString(); string name = dgvList.Rows[rowIndex].Cells[this.Column_Name.Name].Value.ToString();
string showText = dgvList.Rows[rowIndex].Cells[this.Column_ShowText.Name].Value.ToString(); string showText = dgvList.Rows[rowIndex].Cells[this.Column_ShowText.Name].Value.ToString();
int polaritiesType = Int32.Parse( dgvList.Rows[rowIndex].Cells[this.col_Polarities.Name].Value.ToString());
//判断位置是否超出范围 //判断位置是否超出范围
if (!TSAVBean.IsValidPosition(x, y)) if (!TSAVBean.IsValidPosition(x, y))
{ {
...@@ -501,7 +503,7 @@ namespace TSA_V ...@@ -501,7 +503,7 @@ namespace TSA_V
else else
{ {
FrmProjectorScreen.instance.ClearPoint(); FrmProjectorScreen.instance.ClearPoint();
FrmProjectorScreen.instance.ShowPoint(new ProjectorPInfo((int)x, (int)y, type, sizeX, sizeY, penWidth, showText,btnColorChange.BackColor.ToArgb())); FrmProjectorScreen.instance.ShowPoint(new ProjectorPInfo((int)x, (int)y, type, polaritiesType, sizeX, sizeY, penWidth, showText,btnColorChange.BackColor.ToArgb()));
} }
} }
...@@ -722,6 +724,7 @@ namespace TSA_V ...@@ -722,6 +724,7 @@ namespace TSA_V
point.ShowText = (row.Cells[this.Column_ShowText.Name].Value.ToString()); point.ShowText = (row.Cells[this.Column_ShowText.Name].Value.ToString());
point.Disable = Convert.ToBoolean(row.Cells[this.Column_disable.Name].Value.ToString()); point.Disable = Convert.ToBoolean(row.Cells[this.Column_disable.Name].Value.ToString());
point.IsEdit = Convert.ToBoolean(row.Cells[this.col_IsEdit.Name].Value.ToString()); point.IsEdit = Convert.ToBoolean(row.Cells[this.col_IsEdit.Name].Value.ToString());
point.PolaritiesType = Convert.ToInt32(row.Cells[this.col_Polarities.Name].Value.ToString());
} }
catch (Exception ex) catch (Exception ex)
{ {
......
...@@ -216,6 +216,9 @@ ...@@ -216,6 +216,9 @@
<metadata name="col_IsEdit.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="col_IsEdit.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="col_Polarities.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Column_getPosition.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column_getPosition.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
......
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace TSA_V.frmBoard
{
public partial class FrmBomUpload : FrmBase
{
public FrmBomUpload()
{
InitializeComponent();
}
private void linkSelBom_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
openFileDialog1.DefaultExt = "csv|xls|xlsx";
openFileDialog1.Filter = "csv|*.csv|xls|*.xls|xlsx|*.xlsx";
string directory = Environment.GetFolderPath(Environment.SpecialFolder.DesktopDirectory);//桌面路径
openFileDialog1.InitialDirectory = directory;
if (openFileDialog1.ShowDialog() == DialogResult.OK)
{
openFileDialog1.Tag = true;
txtBomFile.Text=openFileDialog1.FileName;
ReadBomFile(openFileDialog1.FileName);
}
else
{
openFileDialog1.FileName = "";
}
}
private void ReadBomFile(string fileName)
{
}
private void ReadXyFile(string fileName)
{
}
private void linkSelXy_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
openFileDialog1.DefaultExt = "csv|xls|xlsx";
openFileDialog1.Filter = "csv|*.csv|xls|*.xls|xlsx|*.xlsx";
string directory = Environment.GetFolderPath(Environment.SpecialFolder.DesktopDirectory);//桌面路径
openFileDialog1.InitialDirectory = directory;
if (openFileDialog1.ShowDialog() == DialogResult.OK)
{
openFileDialog1.Tag = true;
txtXyFile.Text = openFileDialog1.FileName;
ReadXyFile(openFileDialog1.FileName);
}
else
{
openFileDialog1.FileName = "";
}
}
private void btnUpload_Click(object sender, EventArgs e)
{
}
private void btnCancel_Click(object sender, EventArgs e)
{
this.Close();
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="openFileDialog1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
</root>
\ No newline at end of file \ No newline at end of file
...@@ -49,16 +49,18 @@ ...@@ -49,16 +49,18 @@
// xyMoveControl1 // xyMoveControl1
// //
this.xyMoveControl1.BackColor = System.Drawing.Color.White; this.xyMoveControl1.BackColor = System.Drawing.Color.White;
this.xyMoveControl1.Cursor = System.Windows.Forms.Cursors.Default;
this.xyMoveControl1.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.xyMoveControl1.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.xyMoveControl1.GroupName = "坐标"; this.xyMoveControl1.GroupName = "坐标";
this.xyMoveControl1.Location = new System.Drawing.Point(22, 20); this.xyMoveControl1.Location = new System.Drawing.Point(22, 12);
this.xyMoveControl1.Name = "xyMoveControl1"; this.xyMoveControl1.Name = "xyMoveControl1";
this.xyMoveControl1.PenWidth = 2; this.xyMoveControl1.PenWidth = 2;
this.xyMoveControl1.PointSizeX = 5; this.xyMoveControl1.PointSizeX = 5;
this.xyMoveControl1.PointSizeY = 5; this.xyMoveControl1.PointSizeY = 5;
this.xyMoveControl1.PointType = 1; this.xyMoveControl1.PointType = 1;
this.xyMoveControl1.PolaritiesType = 0;
this.xyMoveControl1.ShowText = ""; this.xyMoveControl1.ShowText = "";
this.xyMoveControl1.Size = new System.Drawing.Size(510, 303); this.xyMoveControl1.Size = new System.Drawing.Size(510, 320);
this.xyMoveControl1.TabIndex = 288; this.xyMoveControl1.TabIndex = 288;
this.xyMoveControl1.XValue = 1D; this.xyMoveControl1.XValue = 1D;
this.xyMoveControl1.YValue = 1D; this.xyMoveControl1.YValue = 1D;
...@@ -71,9 +73,9 @@ ...@@ -71,9 +73,9 @@
this.groupBox1.Controls.Add(this.btnLeftUp); this.groupBox1.Controls.Add(this.btnLeftUp);
this.groupBox1.Controls.Add(this.lblMsg); this.groupBox1.Controls.Add(this.lblMsg);
this.groupBox1.Controls.Add(this.xyMoveControl1); this.groupBox1.Controls.Add(this.xyMoveControl1);
this.groupBox1.Location = new System.Drawing.Point(12, 12); this.groupBox1.Location = new System.Drawing.Point(12, 2);
this.groupBox1.Name = "groupBox1"; this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(776, 368); this.groupBox1.Size = new System.Drawing.Size(776, 376);
this.groupBox1.TabIndex = 289; this.groupBox1.TabIndex = 289;
this.groupBox1.TabStop = false; this.groupBox1.TabStop = false;
this.groupBox1.Text = "投影标定"; this.groupBox1.Text = "投影标定";
...@@ -83,7 +85,7 @@ ...@@ -83,7 +85,7 @@
this.btnExit.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); this.btnExit.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.btnExit.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnExit.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnExit.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnExit.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnExit.Location = new System.Drawing.Point(559, 245); this.btnExit.Location = new System.Drawing.Point(559, 253);
this.btnExit.Name = "btnExit"; this.btnExit.Name = "btnExit";
this.btnExit.Size = new System.Drawing.Size(180, 45); this.btnExit.Size = new System.Drawing.Size(180, 45);
this.btnExit.TabIndex = 295; this.btnExit.TabIndex = 295;
...@@ -96,7 +98,7 @@ ...@@ -96,7 +98,7 @@
this.btnCal.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); this.btnCal.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.btnCal.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnCal.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnCal.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnCal.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnCal.Location = new System.Drawing.Point(559, 180); this.btnCal.Location = new System.Drawing.Point(559, 188);
this.btnCal.Name = "btnCal"; this.btnCal.Name = "btnCal";
this.btnCal.Size = new System.Drawing.Size(180, 45); this.btnCal.Size = new System.Drawing.Size(180, 45);
this.btnCal.TabIndex = 294; this.btnCal.TabIndex = 294;
...@@ -109,7 +111,7 @@ ...@@ -109,7 +111,7 @@
this.btnRightBottom.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); this.btnRightBottom.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.btnRightBottom.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnRightBottom.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnRightBottom.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnRightBottom.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnRightBottom.Location = new System.Drawing.Point(559, 115); this.btnRightBottom.Location = new System.Drawing.Point(559, 123);
this.btnRightBottom.Name = "btnRightBottom"; this.btnRightBottom.Name = "btnRightBottom";
this.btnRightBottom.Size = new System.Drawing.Size(180, 45); this.btnRightBottom.Size = new System.Drawing.Size(180, 45);
this.btnRightBottom.TabIndex = 293; this.btnRightBottom.TabIndex = 293;
...@@ -122,7 +124,7 @@ ...@@ -122,7 +124,7 @@
this.btnLeftUp.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); this.btnLeftUp.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.btnLeftUp.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnLeftUp.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnLeftUp.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnLeftUp.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnLeftUp.Location = new System.Drawing.Point(559, 50); this.btnLeftUp.Location = new System.Drawing.Point(559, 58);
this.btnLeftUp.Name = "btnLeftUp"; this.btnLeftUp.Name = "btnLeftUp";
this.btnLeftUp.Size = new System.Drawing.Size(180, 45); this.btnLeftUp.Size = new System.Drawing.Size(180, 45);
this.btnLeftUp.TabIndex = 292; this.btnLeftUp.TabIndex = 292;
...@@ -135,7 +137,7 @@ ...@@ -135,7 +137,7 @@
this.lblMsg.AutoSize = true; this.lblMsg.AutoSize = true;
this.lblMsg.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.lblMsg.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblMsg.ForeColor = System.Drawing.Color.Red; this.lblMsg.ForeColor = System.Drawing.Color.Red;
this.lblMsg.Location = new System.Drawing.Point(32, 339); this.lblMsg.Location = new System.Drawing.Point(32, 343);
this.lblMsg.Name = "lblMsg"; this.lblMsg.Name = "lblMsg";
this.lblMsg.Size = new System.Drawing.Size(522, 22); this.lblMsg.Size = new System.Drawing.Size(522, 22);
this.lblMsg.TabIndex = 289; this.lblMsg.TabIndex = 289;
...@@ -147,9 +149,9 @@ ...@@ -147,9 +149,9 @@
| System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right))); | System.Windows.Forms.AnchorStyles.Right)));
this.groupBox2.Controls.Add(this.panBoard); this.groupBox2.Controls.Add(this.panBoard);
this.groupBox2.Location = new System.Drawing.Point(13, 387); this.groupBox2.Location = new System.Drawing.Point(13, 381);
this.groupBox2.Name = "groupBox2"; this.groupBox2.Name = "groupBox2";
this.groupBox2.Size = new System.Drawing.Size(775, 318); this.groupBox2.Size = new System.Drawing.Size(775, 343);
this.groupBox2.TabIndex = 290; this.groupBox2.TabIndex = 290;
this.groupBox2.TabStop = false; this.groupBox2.TabStop = false;
this.groupBox2.Text = "图示"; this.groupBox2.Text = "图示";
...@@ -160,15 +162,15 @@ ...@@ -160,15 +162,15 @@
this.panBoard.Dock = System.Windows.Forms.DockStyle.Fill; this.panBoard.Dock = System.Windows.Forms.DockStyle.Fill;
this.panBoard.Location = new System.Drawing.Point(3, 17); this.panBoard.Location = new System.Drawing.Point(3, 17);
this.panBoard.Name = "panBoard"; this.panBoard.Name = "panBoard";
this.panBoard.Size = new System.Drawing.Size(769, 298); this.panBoard.Size = new System.Drawing.Size(769, 323);
this.panBoard.TabIndex = 1; this.panBoard.TabIndex = 1;
// //
// picBoard // picBoard
// //
this.picBoard.Image = global::TSA_V.Properties.Resources._202403181014; this.picBoard.Image = global::TSA_V.Properties.Resources._202403181014;
this.picBoard.Location = new System.Drawing.Point(32, 27); this.picBoard.Location = new System.Drawing.Point(32, 24);
this.picBoard.Name = "picBoard"; this.picBoard.Name = "picBoard";
this.picBoard.Size = new System.Drawing.Size(686, 242); this.picBoard.Size = new System.Drawing.Size(686, 269);
this.picBoard.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom; this.picBoard.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
this.picBoard.TabIndex = 0; this.picBoard.TabIndex = 0;
this.picBoard.TabStop = false; this.picBoard.TabStop = false;
......
...@@ -30,9 +30,10 @@ namespace TSA_V.frmBoard ...@@ -30,9 +30,10 @@ namespace TSA_V.frmBoard
SetPicSize(); SetPicSize();
LoadPoint(); LoadPoint();
timer1.Start(); timer1.Start();
xyMoveControl1.loadTypeList(ResourceCulture.GetPTypes(),ResourceCulture.GetXYControlMap()); xyMoveControl1.loadTypeList(ResourceCulture.GetPTypes(), ResourceCulture.GetDirTypes(), ResourceCulture.GetXYControlMap());
xyMoveControl1.ShowPointEvent += XyMoveControl1_ShowPointEvent; xyMoveControl1.ShowPointEvent += XyMoveControl1_ShowPointEvent;
xyMoveControl1.PointType = 2; xyMoveControl1.PointType = 2;
xyMoveControl1.PolaritiesType = 0;
xyMoveControl1.PointSizeX = 20; xyMoveControl1.PointSizeX = 20;
xyMoveControl1.PointSizeY = 20; xyMoveControl1.PointSizeY = 20;
xyMoveControl1.PenWidth = 4; xyMoveControl1.PenWidth = 4;
......
...@@ -319,6 +319,7 @@ ...@@ -319,6 +319,7 @@
this.xyMoveControl1.PointSizeX = 4; this.xyMoveControl1.PointSizeX = 4;
this.xyMoveControl1.PointSizeY = 1; this.xyMoveControl1.PointSizeY = 1;
this.xyMoveControl1.PointType = 1; this.xyMoveControl1.PointType = 1;
this.xyMoveControl1.PolaritiesType = 0;
this.xyMoveControl1.ShowText = ""; this.xyMoveControl1.ShowText = "";
this.xyMoveControl1.Size = new System.Drawing.Size(506, 315); this.xyMoveControl1.Size = new System.Drawing.Size(506, 315);
this.xyMoveControl1.TabIndex = 63; this.xyMoveControl1.TabIndex = 63;
......
...@@ -48,7 +48,7 @@ namespace TSA_V ...@@ -48,7 +48,7 @@ namespace TSA_V
this.txtX.Text = x.ToString(); this.txtX.Text = x.ToString();
this.txtY.Text = y.ToString(); this.txtY.Text = y.ToString();
xyMoveControl1.loadTypeList(ResourceCulture.GetPTypes(), ResourceCulture.GetXYControlMap()); xyMoveControl1.loadTypeList(ResourceCulture.GetPTypes(), ResourceCulture.GetDirTypes(), ResourceCulture.GetXYControlMap());
xyMoveControl1.ShowColor = boardInfo.PointColor; xyMoveControl1.ShowColor = boardInfo.PointColor;
} }
...@@ -113,7 +113,7 @@ namespace TSA_V ...@@ -113,7 +113,7 @@ namespace TSA_V
ShowPoint(null); ShowPoint(null);
xyMoveControl1.ShowColor = boardInfo.PointColor; xyMoveControl1.ShowColor = boardInfo.PointColor;
xyMoveControl1.loadTypeList(ResourceCulture.GetPTypes(), ResourceCulture.GetXYControlMap()); xyMoveControl1.loadTypeList(ResourceCulture.GetPTypes(), ResourceCulture.GetDirTypes(), ResourceCulture.GetXYControlMap());
} }
private void ShowPoint(SMTPointInfo prePoint) private void ShowPoint(SMTPointInfo prePoint)
...@@ -131,6 +131,7 @@ namespace TSA_V ...@@ -131,6 +131,7 @@ namespace TSA_V
xyMoveControl1.XValue = smtPointInfo.NodePositionX; xyMoveControl1.XValue = smtPointInfo.NodePositionX;
xyMoveControl1.YValue = smtPointInfo.NodePositionY; xyMoveControl1.YValue = smtPointInfo.NodePositionY;
xyMoveControl1.PointType = smtPointInfo.PointType; xyMoveControl1.PointType = smtPointInfo.PointType;
xyMoveControl1.PolaritiesType= smtPointInfo.PolaritiesType;
xyMoveControl1.PointSizeX = smtPointInfo.PointSizeX; xyMoveControl1.PointSizeX = smtPointInfo.PointSizeX;
xyMoveControl1.PointSizeY = smtPointInfo.PointSizeY; xyMoveControl1.PointSizeY = smtPointInfo.PointSizeY;
xyMoveControl1.PenWidth = smtPointInfo.PenWidth; xyMoveControl1.PenWidth = smtPointInfo.PenWidth;
...@@ -144,6 +145,7 @@ namespace TSA_V ...@@ -144,6 +145,7 @@ namespace TSA_V
xyMoveControl1.PointSizeX = prePoint.PointSizeX; xyMoveControl1.PointSizeX = prePoint.PointSizeX;
xyMoveControl1.PointSizeY = prePoint.PointSizeY; xyMoveControl1.PointSizeY = prePoint.PointSizeY;
xyMoveControl1.PenWidth = prePoint.PenWidth; xyMoveControl1.PenWidth = prePoint.PenWidth;
xyMoveControl1.PolaritiesType = prePoint.PolaritiesType;
} }
} }
xyMoveControl1.ShowCurrPoint(); xyMoveControl1.ShowCurrPoint();
...@@ -248,6 +250,7 @@ namespace TSA_V ...@@ -248,6 +250,7 @@ namespace TSA_V
smtPointInfo.PointSizeY = xyMoveControl1.PointSizeY; smtPointInfo.PointSizeY = xyMoveControl1.PointSizeY;
smtPointInfo.PenWidth = xyMoveControl1.PenWidth; smtPointInfo.PenWidth = xyMoveControl1.PenWidth;
smtPointInfo.ShowText = xyMoveControl1.ShowText; smtPointInfo.ShowText = xyMoveControl1.ShowText;
smtPointInfo.PolaritiesType= xyMoveControl1.PolaritiesType;
smtPointInfo.NeedSoldering = chbNeedSoldering.Checked; smtPointInfo.NeedSoldering = chbNeedSoldering.Checked;
smtPointInfo.NeedCheck = chbNeedCheck.Checked; smtPointInfo.NeedCheck = chbNeedCheck.Checked;
smtPointInfo.WeldTime = FormUtil.getDoubleValue(txtWeldTime); smtPointInfo.WeldTime = FormUtil.getDoubleValue(txtWeldTime);
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!