[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/pyim dacaff5 3/3: * pyim.el (pyim-select-word:xingma):
From: |
ELPA Syncer |
Subject: |
[elpa] externals/pyim dacaff5 3/3: * pyim.el (pyim-select-word:xingma): 以词定字的时候,不调整词频。 |
Date: |
Sat, 18 Dec 2021 01:57:37 -0500 (EST) |
branch: externals/pyim
commit dacaff52f089931888c8f7de90cf075dffd7eb51
Author: Feng Shu <tumashu@163.com>
Commit: Feng Shu <tumashu@163.com>
* pyim.el (pyim-select-word:xingma): 以词定字的时候,不调整词频。
---
pyim.el | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/pyim.el b/pyim.el
index cd3115b..745c360 100644
--- a/pyim.el
+++ b/pyim.el
@@ -604,10 +604,11 @@ FILE 的格式与 `pyim-dcache-export' 生成的文件格式相同,
(delete-region (point-min) (point)))
(pyim-process-run))
;; 型码输入法,只考虑将词条保存到个人词库,用于调整词频,单字不保存。
- (when (> (length (pyim-process-get-outcome)) 1)
- (if (member (pyim-process-get-outcome) (pyim-process-get-candidates))
- (pyim-process-create-word (pyim-process-get-outcome) t)
- (pyim-process-create-word (pyim-process-get-outcome))))
+ (unless (pyim-process-select-subword-p) ;NOTE: 以词定字的时候,到底应不应该保存词条呢,需要进一步研究。
+ (when (> (length (pyim-process-get-outcome)) 1)
+ (if (member (pyim-process-get-outcome) (pyim-process-get-candidates))
+ (pyim-process-create-word (pyim-process-get-outcome) t)
+ (pyim-process-create-word (pyim-process-get-outcome)))))
(pyim-process-terminate)
;; pyim 使用这个 hook 来处理联想词。
(run-hooks 'pyim-select-finish-hook)))