添加BGA空隙测量按钮到测量工具组

This commit is contained in:
李伟
2026-04-24 15:58:59 +08:00
parent de21e462e7
commit ef2ef5cb83
3 changed files with 21 additions and 1 deletions
+2 -1
View File
@@ -11,7 +11,8 @@ namespace XplorePlane.Events
PointDistance, PointDistance,
PointLineDistance, PointLineDistance,
Angle, Angle,
ThroughHoleFillRate ThroughHoleFillRate,
BgaVoid
} }
/// <summary> /// <summary>
@@ -87,6 +87,7 @@ namespace XplorePlane.ViewModels
public DelegateCommand PointLineDistanceMeasureCommand { get; } public DelegateCommand PointLineDistanceMeasureCommand { get; }
public DelegateCommand AngleMeasureCommand { get; } public DelegateCommand AngleMeasureCommand { get; }
public DelegateCommand ThroughHoleFillRateMeasureCommand { get; } public DelegateCommand ThroughHoleFillRateMeasureCommand { get; }
public DelegateCommand BgaVoidMeasureCommand { get; }
// 辅助线命令 // 辅助线命令
public DelegateCommand ToggleCrosshairCommand { get; } public DelegateCommand ToggleCrosshairCommand { get; }
@@ -173,6 +174,7 @@ namespace XplorePlane.ViewModels
PointLineDistanceMeasureCommand = new DelegateCommand(ExecutePointLineDistanceMeasure); PointLineDistanceMeasureCommand = new DelegateCommand(ExecutePointLineDistanceMeasure);
AngleMeasureCommand = new DelegateCommand(ExecuteAngleMeasure); AngleMeasureCommand = new DelegateCommand(ExecuteAngleMeasure);
ThroughHoleFillRateMeasureCommand = new DelegateCommand(ExecuteThroughHoleFillRateMeasure); ThroughHoleFillRateMeasureCommand = new DelegateCommand(ExecuteThroughHoleFillRateMeasure);
BgaVoidMeasureCommand = new DelegateCommand(ExecuteBgaVoidMeasure);
// 辅助线命令 // 辅助线命令
ToggleCrosshairCommand = new DelegateCommand(() => ToggleCrosshairCommand = new DelegateCommand(() =>
@@ -471,6 +473,12 @@ namespace XplorePlane.ViewModels
_eventAggregator.GetEvent<MeasurementToolEvent>().Publish(MeasurementToolMode.ThroughHoleFillRate); _eventAggregator.GetEvent<MeasurementToolEvent>().Publish(MeasurementToolMode.ThroughHoleFillRate);
} }
private void ExecuteBgaVoidMeasure()
{
_logger.Info("BGA空隙测量功能已触发");
_eventAggregator.GetEvent<MeasurementToolEvent>().Publish(MeasurementToolMode.BgaVoid);
}
#endregion #endregion
#region #region
+11
View File
@@ -442,6 +442,17 @@
SmallImage="/Assets/Icons/pores.png" SmallImage="/Assets/Icons/pores.png"
Text="通孔填锡率" /> Text="通孔填锡率" />
</StackPanel> </StackPanel>
<!-- 第三列: BGA空隙测量 -->
<StackPanel>
<telerik:RadRibbonButton
telerik:ScreenTip.Description="BGA焊球空隙率检测"
telerik:ScreenTip.Title="BGA空隙测量"
Command="{Binding BgaVoidMeasureCommand}"
Size="Medium"
SmallImage="/Assets/Icons/bga.png"
Text="BGA空隙" />
</StackPanel>
</telerik:RadRibbonGroup> </telerik:RadRibbonGroup>
<!-- <!--
<telerik:RadRibbonGroup Header="图像处理"> <telerik:RadRibbonGroup Header="图像处理">