241 Commits

Author SHA1 Message Date
yinzw 20f618881c 合入2个最新pull请求后,代码做部分调整 2026-10-16 13:00:43 +08:00
爬山虎 0d7d499efc !108 feat: 在「工具」菜单中增加 Markdown 预览
Merge pull request !108 from wushuzhilu/feat/markdown_preview
2026-10-16 04:34:12 +00:00
爬山虎 4d9a711583 !110 修复 Linux 下单实例逻辑 kill(0, SIGUSR1) 导致桌面会话被注销
Merge pull request !110 from yang37/fix/linux-single-instance-kill-pid0
2026-10-16 03:44:10 +00:00
yang37 6bec50e49c fix(linux): validate pid before signaling existing instance
The single-instance check reads the pid of the running instance from
the "notepad--" shared memory and sends SIGUSR1 to it without any
validation. When the segment is left over from an abnormal exit the
stored pid can be 0, and kill(0, SIGUSR1) delivers SIGUSR1 (default
action: terminate) to the whole process group. Launched from the
desktop this kills the session processes and logs the user out. A
recycled pid may also cause an unrelated process to be killed.

Only signal the pid when it is > 1 and /proc/<pid>/comm matches our
own, otherwise start as a new instance. Also check the return value
of nppShared.attach() before dereferencing data().
2026-10-16 10:48:36 +08:00
wushuzhilu a009aabf2a fix: renderer hangs when a block is followed by a non-blank line
The paragraph fallback checked the *previous* line before consuming the first line of a new paragraph. When renderQuote returned with i pointing right after a quote, the next line's prev started with '>', so the paragraph broke immediately without advancing i, and the outer loop spun on the same line forever -- freezing the whole UI.

Minimal repro (verified with a standalone harness, 3s watchdog per case): "> y\n<p>" -> HANG. The same trigger applies to headings / horizontal rules / fences followed directly by a non-blank line, e.g. "# T\ntext".

Fix: remember where the paragraph starts and only run the prev-based checks when continuing an existing paragraph (i > paraStart). A fresh paragraph always consumes its first line, so i always advances.

Also fixes a placeholder collision found while investigating: the hard line break marker was U+E001, inside the private-use range the inline stash allocates (0xE000..), so a hard break plus two inline code spans made the break marker get restored as a wrong stash slot (corrupted output, not a hang). Moved to U+0001, which escapeHtml passes through and which is replaced back before the HTML reaches setHtml.

Verified: standalone harness, 68 cases (HTML-heavy + regressions), all pass; previously-hanging inputs now render correctly.
2026-10-12 16:15:39 +08:00
wushuzhilu f8167e4405 feat: add Markdown preview to Tools menu
Add a "Markdown Preview" action under the Tools menu that renders the current editor content and shows it in a separate window.

- src/mdrenderer.{h,cpp}: self-contained Markdown renderer (headings, nested lists, GFM tables, task lists, fenced code, blockquotes, links, images, hr). No third-party dependency.

- src/markdownview.{h,cpp}: add viewHtml() plus a style sheet applied via QTextDocument::setDefaultStyleSheet() so the preview is actually readable (heading hierarchy, code block background, table borders, quote blocks, document margin).

- src/cceditor/ccnotepad.{h,cpp}: add the menu action and the slot. The slot reads the current editor through ui.editTabWidget->currentWidget() and passes the text to MarkdownView.

- src/realcompare_zh.ts/.qm: Chinese translation so the menu reads "Markdown" when the UI language is Chinese.

Implemented inside the application rather than as a plugin: ScintillaEditView is defined in this module and ui.editTabWidget is a private member, so a plugin cannot obtain the current editor reliably across module boundaries.
2026-10-09 16:05:22 +08:00
爬山虎 91105f68b7 删除文件 ndd-v3.1-说明书.pdf v3.8.3 v3.9.0 v3.9.1 2026-07-22 06:05:58 +00:00
爬山虎 67e1ec4de5 更新说明书 2026-07-22 14:01:50 +08:00
aaasjm 7d491ccb10 提交3.7.3说明书 v3.8.0 v3.8.2 2026-05-30 11:53:48 +08:00
爬山虎 3c365faa83 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
v3.7.1 v3.7.2 v3.7.3
2026-03-30 12:44:45 +00:00
爬山虎 42f11ca1f1 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
2026-03-29 06:24:53 +00:00
爬山虎 8d83300942 update README.md.
更新主页信息

Signed-off-by: 爬山虎 <aaasjm@126.com>
2026-03-29 06:22:53 +00:00
爬山虎 1b5ed5df09 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
v3.6.4 v3.7
2026-01-06 07:48:26 +00:00
爬山虎 574ed1a0a0 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
v3.6.1 v3.6.2 v3.6.3
2025-10-21 05:04:01 +00:00
爬山虎 31ce23741d update README.md.
更新

Signed-off-by: 爬山虎 <aaasjm@126.com>
2025-10-21 05:02:05 +00:00
爬山虎 1d69aee7c0 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
v3.6
2025-08-27 07:33:19 +00:00
爬山虎 b745707ecf update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
2025-08-27 07:31:34 +00:00
爬山虎 fc3a9b3e16 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
2025-08-27 07:29:34 +00:00
爬山虎 dddb7e3e96 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
v3.5 v3.5.1
2025-07-25 01:54:00 +00:00
爬山虎 3222134afb update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
v3.4
2025-05-13 06:52:58 +00:00
爬山虎 ffd84243c5 update README.md.
提交公众号,方便用户留言提交bug或需求。

Signed-off-by: 爬山虎 <aaasjm@126.com>
2025-05-13 06:45:50 +00:00
爬山虎 a32ed938d0 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
2025-05-13 06:34:46 +00:00
爬山虎 57b8327736 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
2025-05-13 06:33:59 +00:00
爬山虎 990bd0d03c 提交3.1手册,删除过时文档 v3.2.1 v3.3 2025-03-13 10:11:00 +08:00
爬山虎 31effe4020 update src/RealCompare.pro.
Signed-off-by: 爬山虎 <aaasjm@126.com>
2025-03-13 01:52:08 +00:00
爬山虎 ee35169ac4 更新手册 v2.18 v2.19 v2.20 v2.20.1 v3.0 v3.1 v3.2 2024-07-23 16:29:07 +08:00
爬山虎 a25c215bec update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
2024-07-21 06:51:59 +00:00
爬山虎 8d115ee553 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
2024-06-30 03:12:27 +00:00
爬山虎 3703787975 !102 修正笔误
Merge pull request !102 from 高乐喆/master
v2.16 v2.17
2024-05-09 04:26:33 +00:00
高乐喆 541dbd8b39 update README.md.
Signed-off-by: 高乐喆 <gaolezhe@outlook.com>
2024-05-08 12:16:26 +00:00
爬山虎 335b72ce6e update README.md.
增加新群

Signed-off-by: 爬山虎 <aaasjm@126.com>
v2.15
2024-03-11 06:31:58 +00:00
爬山虎 a89e9c6953 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
v2.13 v2.14
2024-01-05 04:59:50 +00:00
爬山虎 e525304794 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
2024-01-05 04:50:53 +00:00
爬山虎 6efbf07ea1 update README.md.
更新2.12效果图

Signed-off-by: 爬山虎 <aaasjm@126.com>
2024-01-05 04:48:47 +00:00
爬山虎 161dfc0c30 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
2024-01-05 04:46:24 +00:00
爬山虎 1fcad1d731 update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
2024-01-05 04:44:26 +00:00
爬山虎 1045cfe99e 提交使用手册。
Signed-off-by: 爬山虎 <aaasjm@126.com>
v2.12
2023-12-01 08:51:22 +00:00
爬山虎 686d36d2d8 !92 支持高清屏
Merge pull request !92 from xdongwong/master
2023-11-17 13:23:02 +00:00
wangxd 7ea8d7a5ba support high dpi 2023-11-17 15:13:17 +08:00
爬山虎 ea55d37104 核心编辑器组件升级到2.11 2023-11-16 17:52:25 +08:00
爬山虎 e39e6014ee Merge branch 'master' of https://gitee.com/cxasm/notepad-- v2.11 2023-11-03 23:30:07 +08:00
爬山虎 7fcfa6191a 更新2.8以后新插件接口开发说明 2023-11-03 23:29:31 +08:00
爬山虎 ab5b978b7d update README.md.
上传银河麒麟效果图。

Signed-off-by: 爬山虎 <aaasjm@126.com>
2023-11-01 06:46:47 +00:00
爬山虎 b068a25f48 更新代码到2.0,更新接口到2.0新接口,让插件可以和最新ndd兼容 2023-10-26 23:16:48 +08:00
爬山虎 7df65181a0 update README.md.
更新macos 2.9 效果图。

Signed-off-by: 爬山虎 <aaasjm@126.com>
v2.10
2023-10-06 03:26:32 +00:00
爬山虎 a8d6e79bfe update README.md.
更新mac效果图

Signed-off-by: 爬山虎 <aaasjm@126.com>
v2.9
2023-09-26 01:33:40 +00:00
爬山虎 f121bcb86b !88 Fix build error and the shortcut problem under Ubuntu
Merge pull request !88 from tangramor/master
2023-09-11 08:01:14 +00:00
tangramor 2fcb3763e1 Fix build error under Ubuntu and the shortcut problem 2023-09-10 16:21:40 +08:00
爬山虎 55fab57c3c update README.md.
Signed-off-by: 爬山虎 <aaasjm@126.com>
2023-09-05 06:58:06 +00:00
爬山虎 62dc6a8d41 提交使用手册。
Signed-off-by: 爬山虎 <aaasjm@126.com>
2023-09-05 06:57:07 +00:00