feat(chinese): add +childframe for pyim candidates

Close: #6482
Co-authored-by: merrickluo <merrickluo@users.noreply.github.com>
This commit is contained in:
Henrik Lissner 2023-02-23 02:34:11 -05:00
parent 4594aaa7cd
commit 5d69d48943
No known key found for this signature in database
GPG key ID: B60957CA074D39A3
3 changed files with 8 additions and 0 deletions

View file

@ -13,6 +13,8 @@ methods: Pinyin and Wubi.
** Module flags
- +rime ::
Enables the [[https://rime.im/][rime]] backend for pyim.
- +childframe ::
Display pyim candidates in a [[https://www.gnu.org/software/emacs/manual/html_node/elisp/Child-Frames.html][child frame]] rather than overlay or tooltip.
** Packages
- [[doom-package:ace-pinyin]]
@ -21,6 +23,7 @@ methods: Pinyin and Wubi.
- [[doom-package:fcitx]]
- [[doom-package:liberime]] if [[doom-module:+rime]]
- [[doom-package:pangu-spacing]]
- [[doom-package:posframe]] if [[doom-module:+childframe]]
- [[doom-package:pyim]] unless [[doom-module:+wubi]]
** Hacks

View file

@ -13,6 +13,9 @@
current-input-method)
(add-to-list 'evil-escape-inhibit-functions #'+chinese--input-method-p))
(when (modulep! +childframe)
(setq pyim-page-tooltip 'posframe))
;; allow vertico/selectrum search with pinyin
(cond ((modulep! :completion vertico)
(advice-add #'orderless-regexp

View file

@ -7,5 +7,7 @@
(package! pangu-spacing :pin "2303013e5cd7852136f1429162fea0e1c8cb0221")
(when (modulep! +rime)
(package! liberime :pin "8291e22cd0990a99cb2f88ca67a9065a157f39af"))
(when (modulep! +childframe)
(package! posframe :pin "0d23bc5f7cfac00277d83ae7ba52c48685bcbc68"))
(when (modulep! :editor evil +everywhere)
(package! evil-pinyin :pin "3e9e501ded86f88e01a4edec5d526ab0fab879d7"))