Skip to content

[0833] 绘图区进入时背景不填充为淡蓝色 - #3940

Merged
AXeonV merged 1 commit into
mainfrom
ty/0833
Jul 14, 2026
Merged

[0833] 绘图区进入时背景不填充为淡蓝色#3940
AXeonV merged 1 commit into
mainfrom
ty/0833

Conversation

@AXeonV

@AXeonV AXeonV commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

[0833] 绘图区进入时背景不填充为淡蓝色

1 相关文档

  • 213_22.md - Replace focus border with translucent background

2 任务相关的代码文件

  • src/Edit/Interface/edit_interface.cpp — 聚焦矩形 foc_rects 计算时增加 !inside_graphics(false) 特判

3 如何测试

3.1 确定性测试(单元测试)

xmake b stem
xmake r stem

3.2 非确定性测试(交互验证)

  1. 打开软件,插入一个绘图区(graphics)并把光标置于绘图区中。
  2. 观察绘图区背景,应当保持默认底色,不应被填充为淡蓝色
  3. 退出绘图区后,聚焦在表格或数学公式等聚焦环境时,其背景仍应正确高亮显示为半透明淡蓝色。

4 What

在之前的任务(PR #2888 / 213_22.md)中,聚焦指示由高亮边框改为了半透明淡蓝色背景填充。

这导致在进入绘图区(graphics)时,整个画布区域被识别为聚焦环境,导致整个绘图画布全部变成淡蓝色。

5 How

edit_interface.cppapply_changes 函数计算 foc_rects 中,追加 !inside_graphics(false) 判定条件:

当位于绘图区内部时,跳过 foc_rects 的计算(使其保持为空矩形),从而避免整个绘图画布在重绘时被填充聚焦色。

Copilot AI review requested due to automatic review settings July 14, 2026 01:56

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@MoonL79 MoonL79 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@AXeonV
AXeonV merged commit 541018a into main Jul 14, 2026
6 checks passed
@AXeonV
AXeonV deleted the ty/0833 branch July 14, 2026 02:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants