|
@@ -294,10 +294,10 @@ namespace OTSMeasureApp
|
|
|
break;
|
|
break;
|
|
|
case "SlopFocusMenuItem":
|
|
case "SlopFocusMenuItem":
|
|
|
|
|
|
|
|
- if (slopFocus == null)
|
|
|
|
|
- {
|
|
|
|
|
|
|
+ //if (slopFocus == null)
|
|
|
|
|
+ //{
|
|
|
slopFocus = new SlopFocus(this);
|
|
slopFocus = new SlopFocus(this);
|
|
|
- }
|
|
|
|
|
|
|
+ //}
|
|
|
|
|
|
|
|
slopFocus.Show();
|
|
slopFocus.Show();
|
|
|
|
|
|
|
@@ -460,7 +460,9 @@ namespace OTSMeasureApp
|
|
|
var para = m_visualStage.GetSampleMeasurePara(sam.GetMeasureGDIObject());
|
|
var para = m_visualStage.GetSampleMeasurePara(sam.GetMeasureGDIObject());
|
|
|
|
|
|
|
|
SetWorkSampleMeasureArea(para);
|
|
SetWorkSampleMeasureArea(para);
|
|
|
- if(frmInput.IsInclinedPlaneFocus) m_MeasureAppForm.m_ProjParam.GetWorkSample().GetMsrParams().SlopParam = frmInput.GetCSlopFocusParam();
|
|
|
|
|
|
|
+ if (frmInput.IsInclinedPlaneFocus)
|
|
|
|
|
+ {
|
|
|
|
|
+ m_MeasureAppForm.m_ProjParam.GetWorkSample().GetMsrParams().SlopParam = frmInput.GetCSlopFocusParam(); }
|
|
|
CSEMFieldData semdata = m_MeasureAppForm.m_ProjParam.GetResultData().GetWorkingSample().GetSEMDataMsr();
|
|
CSEMFieldData semdata = m_MeasureAppForm.m_ProjParam.GetResultData().GetWorkingSample().GetSEMDataMsr();
|
|
|
semdata.SetMagnification(frmInput.GetMagnification());
|
|
semdata.SetMagnification(frmInput.GetMagnification());
|
|
|
PrepareVisualMeasureField(GetWorkingVisualSample());
|
|
PrepareVisualMeasureField(GetWorkingVisualSample());
|
|
@@ -497,6 +499,16 @@ namespace OTSMeasureApp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
public void DrawCircleByFixedpoint()
|
|
public void DrawCircleByFixedpoint()
|
|
|
{
|
|
{
|
|
|
frmInitializeImageboundary frmInput = new frmInitializeImageboundary();
|
|
frmInitializeImageboundary frmInput = new frmInitializeImageboundary();
|
|
@@ -515,17 +527,10 @@ namespace OTSMeasureApp
|
|
|
float r;
|
|
float r;
|
|
|
PointF Centerpoint;
|
|
PointF Centerpoint;
|
|
|
GetTriangleExcenterRadius(otsfir, otssec, otsthi, out r, out Centerpoint);
|
|
GetTriangleExcenterRadius(otsfir, otssec, otsthi, out r, out Centerpoint);
|
|
|
|
|
+ PointF lt = new PointF(Centerpoint.X - r, Centerpoint.Y - r);
|
|
|
|
|
+ PointF rb=new PointF(Centerpoint.X + r, Centerpoint.Y + r);
|
|
|
|
|
+ RectangleF rectangleThree = m_visualStage.GetCtrlCoordRectF(lt, rb);
|
|
|
|
|
|
|
|
- RectangleF rectangleThree = new RectangleF(new PointF(Centerpoint.X - r, Centerpoint.Y - r), new SizeF(r * 2, r * 2));
|
|
|
|
|
- //if (m_visualStage.CheckMeasureAreaIsBeyondStageArea(rectangleThree))
|
|
|
|
|
- //{
|
|
|
|
|
- // m_IsDrawMeasure = true;
|
|
|
|
|
- //}
|
|
|
|
|
- //else
|
|
|
|
|
- //{
|
|
|
|
|
- // m_IsDrawMeasure = false;
|
|
|
|
|
- // return;
|
|
|
|
|
- //}
|
|
|
|
|
Color MeasureColor = Color.Red;
|
|
Color MeasureColor = Color.Red;
|
|
|
CMeasureArea newGDI = new CMeasureArea(rectangleThree, ShapeType.CIRCLE, "", sam.GetSampleName(), MeasureColor);
|
|
CMeasureArea newGDI = new CMeasureArea(rectangleThree, ShapeType.CIRCLE, "", sam.GetSampleName(), MeasureColor);
|
|
|
|
|
|
|
@@ -538,8 +543,13 @@ namespace OTSMeasureApp
|
|
|
var para = m_visualStage.GetSampleMeasurePara(sam.GetMeasureGDIObject());
|
|
var para = m_visualStage.GetSampleMeasurePara(sam.GetMeasureGDIObject());
|
|
|
|
|
|
|
|
SetWorkSampleMeasureArea(para);
|
|
SetWorkSampleMeasureArea(para);
|
|
|
- if (frmInput.IsInclinedPlaneFocus) m_MeasureAppForm.m_ProjParam.GetWorkSample().GetMsrParams().SlopParam = frmInput.GetCSlopFocusParam();
|
|
|
|
|
- CSEMFieldData semdata = m_MeasureAppForm.m_ProjParam.GetResultData().GetWorkingSample().GetSEMDataMsr();
|
|
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ if (frmInput.IsInclinedPlaneFocus) {
|
|
|
|
|
+ m_MeasureAppForm.m_ProjParam.GetWorkSample().GetMsrParams().SlopParam = frmInput.GetCSlopFocusParam();
|
|
|
|
|
+ }
|
|
|
|
|
+ CSEMFieldData semdata = m_MeasureAppForm.m_ProjParam.GetWorkSample().GetSEMDataMsr();
|
|
|
semdata.SetMagnification(frmInput.GetMagnification());
|
|
semdata.SetMagnification(frmInput.GetMagnification());
|
|
|
PrepareVisualMeasureField(GetWorkingVisualSample());
|
|
PrepareVisualMeasureField(GetWorkingVisualSample());
|
|
|
}
|
|
}
|
|
@@ -579,7 +589,6 @@ namespace OTSMeasureApp
|
|
|
{
|
|
{
|
|
|
return s;
|
|
return s;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
}
|
|
}
|
|
|
return null;
|
|
return null;
|
|
|
}
|
|
}
|
|
@@ -2613,7 +2622,11 @@ namespace OTSMeasureApp
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+ public CSlopFocusParam getSlopFocusParam()
|
|
|
|
|
+ {
|
|
|
|
|
+ CSlopFocusParam cSlopFocusParam = m_MeasureAppForm.m_ProjParam.GetWorkSample().GetMsrParams().SlopParam;
|
|
|
|
|
+ return cSlopFocusParam;
|
|
|
|
|
+ }
|
|
|
protected override bool ProcessDialogKey(Keys keyData)
|
|
protected override bool ProcessDialogKey(Keys keyData)
|
|
|
{
|
|
{
|
|
|
|
|
|