钻带解析顺序与格式优化,界面信息增强

本次更新聚焦于钻带文件解析顺序与格式的准确还原,提升了界面基础信息展示,并优化了相关数据结构和辅助方法。主要包括:
- 钻带孔位逐行顺序解析,完整保留原始坐标字符串格式,避免顺序错乱和格式丢失。
- 界面新增基础信息分组,自动统计并展示最小钻咀、槽刀、EA刀直径。
- 数据结构如Point2D等增加运算符重载和构造函数,便于几何计算。
- 机台码(0.499刀具)坐标行顺序提取及正则健壮性提升。
- 移除强制编码指定,提升跨平台兼容性。
- 清理冗余测试代码,更新示例/测试钻带文件内容。
- 新增《必读.md》,明确AI开发不需编写测试单元。
本次无其他功能或逻辑变动的占位diff。
This commit is contained in:
2025-12-22 16:50:42 +08:00
parent 44de1cb982
commit 0eab0f42ee
13 changed files with 30955 additions and 10232 deletions

View File

@@ -195,16 +195,6 @@ namespace DrillTools
// 保存原始文件路径
ViewModel.OriginalFilePath = files[0];
Encoding ansiEncoding;
try
{
ansiEncoding = Encoding.GetEncoding(936); // 936是GB2312的代码页
}
catch
{
ansiEncoding = Encoding.Default; // 如果获取失败,使用系统默认编码
}
var process = new Process
{
StartInfo = new ProcessStartInfo
@@ -213,8 +203,7 @@ namespace DrillTools
Arguments = $"/c type \"{files[0]}\"",
RedirectStandardOutput = true,
UseShellExecute = false,
CreateNoWindow = true,
StandardOutputEncoding = ansiEncoding
CreateNoWindow = true
}
};