branch: externals/pyim
commit 95c2ccf11ed36cb6f7f596db12b3980fb2293c76
Author: Feng Shu <[email protected]>
Commit: Feng Shu <[email protected]>

    Fix: % 字符触发 Not enough arguments for format string (Issue #491)
---
 pyim-page.el | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/pyim-page.el b/pyim-page.el
index 9bbdf56aa6..fab3f3736b 100644
--- a/pyim-page.el
+++ b/pyim-page.el
@@ -311,7 +311,8 @@ pyim-page 的核心的功能,为此增加代码的复杂度和测试的难度
 (cl-defmethod pyim-page-show (string _position (_tooltip (eql minibuffer)))
   "使用 minibuffer 来显示 STRING。"
   (let ((max-mini-window-height (+ pyim-page-length 2))
-        (message-log-max nil))
+        (message-log-max nil)
+        (string (replace-regexp-in-string "%" "%%" string)))
     (if (not (eq (selected-window) (minibuffer-window)))
         (message string)
       (message nil)

Reply via email to