fix: v0.4.2 串口日志清空按钮并入标题行对齐;恢复光机命令快捷按钮排(开/关光机等7个, v0.4.0 重写时丢失);重打包
This commit is contained in:
@@ -162,6 +162,9 @@ python publish_gitea.py ../release/DLPilot-v<版本>-win64.zip --replace --insec
|
|||||||
- GUI 与 hdmi_source.ps1 各自独立实现显示器枚举,行为可能微差(GUI 与 `-List` 序号一致,
|
- GUI 与 hdmi_source.ps1 各自独立实现显示器枚举,行为可能微差(GUI 与 `-List` 序号一致,
|
||||||
但与"设置"面板序号无保证);多屏操作前先确认序号;
|
但与"设置"面板序号无保证);多屏操作前先确认序号;
|
||||||
- `pattern_slots.json` 兼容两种历史格式,写出只写新格式(详见 §3.11);
|
- `pattern_slots.json` 兼容两种历史格式,写出只写新格式(详见 §3.11);
|
||||||
|
- `--seconds` 冒烟在已有 DLPilot 实例(含用户开着的 exe)运行时会"挂起":run_gui
|
||||||
|
检测到单实例互斥后弹模态框等点击。无头验证改用直启 `App(5)` 的等效脚本,或先关实例;
|
||||||
|
重打包同理——build_exe.py 会 taskkill 同名进程,等于替用户关掉开着的实例;
|
||||||
- 旧版 `app_gui.py` 仅保留作历史对照,当前入口使用 `app_fluent.py`;新增或修改界面时
|
- 旧版 `app_gui.py` 仅保留作历史对照,当前入口使用 `app_fluent.py`;新增或修改界面时
|
||||||
应遵循 PySide6-Fluent-Widgets 的控件和 Qt 布局,不要把旧版 CustomTkinter 依赖带回入口。
|
应遵循 PySide6-Fluent-Widgets 的控件和 Qt 布局,不要把旧版 CustomTkinter 依赖带回入口。
|
||||||
|
|
||||||
@@ -218,3 +221,12 @@ python publish_gitea.py ../release/DLPilot-v<版本>-win64.zip --replace --insec
|
|||||||
验证:compileall / selftest_rs485 ALL PASS / 离屏断言(空串口提示、长文本下标签
|
验证:compileall / selftest_rs485 ALL PASS / 离屏断言(空串口提示、长文本下标签
|
||||||
最小宽度<300 可换行)/ GUI 冒烟 / 新 exe `--seconds 5` exit 0;v0.4.1 exe(15:05)
|
最小宽度<300 可换行)/ GUI 冒烟 / 新 exe `--seconds 5` exit 0;v0.4.1 exe(15:05)
|
||||||
与 zip 均已用该修复重打。
|
与 zip 均已用该修复重打。
|
||||||
|
- 2026-09-28 v0.4.2 两处 UI 小修:①"串口数据 · 收发日志"卡的"清空"按钮原本自占
|
||||||
|
一行(_card 的标题行是独立 row,按钮行加在其下),与标题错位且多占一行高度——
|
||||||
|
`_card()` 增加 `trailing` 参数把按钮并入标题行右端;②v0.4.0 fluent 重写把旧版
|
||||||
|
app_gui.py 光机命令卡首行的快捷按钮排(开光机/关光机/查版本/软件重启/开TEC/
|
||||||
|
关TEC/TEC33.0°C)整行丢失,开/关光机只能走预设下拉——本次按旧版排布原样恢复,
|
||||||
|
位于电流行与预设行之间(命令直发 `_dlpc_send`,无新增协议逻辑)。
|
||||||
|
验证:compileall / selftest_rs485 / selftest_theme ALL PASS;离屏渲染断言"清空"
|
||||||
|
与标题垂直中心差 0px、7 个快捷按钮齐全;真实桌面冒烟 exit 0。APP_VERSION → 0.4.2
|
||||||
|
并重打包。
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ import edid_parse
|
|||||||
import patterns
|
import patterns
|
||||||
|
|
||||||
APP_NAME = "DLPilot"
|
APP_NAME = "DLPilot"
|
||||||
APP_VERSION = "0.4.1"
|
APP_VERSION = "0.4.2"
|
||||||
REPO_URL = "https://gitea.hulk.wang/hulk/HW-Debug-Tools"
|
REPO_URL = "https://gitea.hulk.wang/hulk/HW-Debug-Tools"
|
||||||
MONO = QFont("Consolas", 10)
|
MONO = QFont("Consolas", 10)
|
||||||
CHIP_IDLE = "#666666"
|
CHIP_IDLE = "#666666"
|
||||||
@@ -210,7 +210,7 @@ class App(QMainWindow):
|
|||||||
button.clicked.connect(callback)
|
button.clicked.connect(callback)
|
||||||
return button
|
return button
|
||||||
|
|
||||||
def _card(self, title, parent):
|
def _card(self, title, parent, trailing=None):
|
||||||
card = CardWidget(parent)
|
card = CardWidget(parent)
|
||||||
layout = QVBoxLayout(card)
|
layout = QVBoxLayout(card)
|
||||||
layout.setContentsMargins(14, 12, 14, 14)
|
layout.setContentsMargins(14, 12, 14, 14)
|
||||||
@@ -218,6 +218,8 @@ class App(QMainWindow):
|
|||||||
row = QHBoxLayout()
|
row = QHBoxLayout()
|
||||||
row.addWidget(StrongBodyLabel(title, card))
|
row.addWidget(StrongBodyLabel(title, card))
|
||||||
row.addStretch(1)
|
row.addStretch(1)
|
||||||
|
if trailing is not None:
|
||||||
|
row.addWidget(trailing)
|
||||||
layout.addLayout(row)
|
layout.addLayout(row)
|
||||||
return card, layout
|
return card, layout
|
||||||
|
|
||||||
@@ -434,11 +436,8 @@ class App(QMainWindow):
|
|||||||
body.addLayout(params)
|
body.addLayout(params)
|
||||||
layout.addWidget(card)
|
layout.addWidget(card)
|
||||||
|
|
||||||
card, body = self._card("串口数据 · 收发日志(译码 + 原始 hex)", self)
|
card, body = self._card("串口数据 · 收发日志(译码 + 原始 hex)", self,
|
||||||
row = QHBoxLayout()
|
trailing=self._button("清空", self._dlpc_clear))
|
||||||
row.addStretch(1)
|
|
||||||
row.addWidget(self._button("清空", self._dlpc_clear))
|
|
||||||
body.addLayout(row)
|
|
||||||
self.txt_dlpc = self._text()
|
self.txt_dlpc = self._text()
|
||||||
self.txt_dlpc.setMinimumHeight(230)
|
self.txt_dlpc.setMinimumHeight(230)
|
||||||
body.addWidget(self.txt_dlpc)
|
body.addWidget(self.txt_dlpc)
|
||||||
@@ -472,6 +471,14 @@ class App(QMainWindow):
|
|||||||
row.addStretch(1)
|
row.addStretch(1)
|
||||||
row.addWidget(self._button("查电流", self._query_current))
|
row.addWidget(self._button("查电流", self._query_current))
|
||||||
body.addLayout(row)
|
body.addLayout(row)
|
||||||
|
# 快捷命令行: v0.4.0 重写时从旧版 app_gui.py 丢失, 开关光机等一发命令
|
||||||
|
# 不应只能走预设下拉
|
||||||
|
quick = QHBoxLayout()
|
||||||
|
for name, cmd in (("开光机", "M730S0"), ("关光机", "M730S1"), ("查版本", "M999"),
|
||||||
|
("软件重启", "M888"), ("开TEC", "M7S0"), ("关TEC", "M7S1"),
|
||||||
|
("TEC33.0°C", "M8S330")):
|
||||||
|
quick.addWidget(self._button(name, lambda checked=False, c=cmd: self._dlpc_send(c)))
|
||||||
|
body.addLayout(quick)
|
||||||
preset_row = QHBoxLayout()
|
preset_row = QHBoxLayout()
|
||||||
self._dlpc_presets = [(n, cmd) for n, cmd, _ in dlpc_rs485.PRESETS]
|
self._dlpc_presets = [(n, cmd) for n, cmd, _ in dlpc_rs485.PRESETS]
|
||||||
self.cbo_dlpc_cmd = ComboBox(card)
|
self.cbo_dlpc_cmd = ComboBox(card)
|
||||||
|
|||||||
Reference in New Issue
Block a user