File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -217,7 +217,8 @@ func (ui *TestUI) addLogTab() {
217217 ui .LogViewer = widget .NewMultiLineEntry ()
218218 ui .LogViewer .SetPlaceHolder ("日志内容将在测试运行时显示..." )
219219 ui .LogViewer .Wrapping = fyne .TextWrapWord
220- ui .LogViewer .Disable () // 只读
220+ // 不使用 Disable(),让文字颜色保持正常
221+ // ui.LogViewer.Disable() // 只读
221222
222223 // 刷新日志按钮
223224 refreshButton := widget .NewButton ("刷新日志" , func () {
Original file line number Diff line number Diff line change @@ -26,7 +26,8 @@ func NewTerminalOutput() *TerminalOutput {
2626 terminal .ExtendBaseWidget (terminal )
2727 terminal .MultiLine = true
2828 terminal .Wrapping = fyne .TextWrapWord
29- terminal .Disable () // 禁用编辑
29+ // 使用 ReadOnly 而不是 Disable,这样文字颜色正常
30+ // terminal.Disable() // 禁用编辑
3031 return terminal
3132}
3233
You can’t perform that action at this time.
0 commit comments