22
22
; ;
23
23
; ;; Hack
24
24
; ;;
25
- (defadvice! +chinese-- org-html-paragraph-a (args)
26
- " Join consecutive Chinese lines into a single long line without)
25
+ (define-advice org-html-paragraph ( :filter-args (args) chinese-a )
26
+ " Join consecutive Chinese lines into a single long line without
27
27
unwanted space when exporting org-mode to html."
28
- :filter-args #'org-html-paragraph
29
28
(++chinese--org-paragraph args))
30
29
31
- (defadvice! +chinese-- org-hugo-paragraph-a (args)
30
+ (define-advice org-hugo-paragraph ( :filter-args (args) chinese-a )
32
31
" Join consecutive Chinese lines into a single long line without
33
32
unwanted space when exporting org-mode to hugo markdown."
34
- :filter-args #'org-hugo-paragraph
35
33
(++chinese--org-paragraph args))
36
34
37
35
(defun ++chinese--org-paragraph (args)
@@ -58,21 +56,17 @@ unwanted space when exporting org-mode to hugo markdown."
58
56
:bind
59
57
(" C-S-s-j" . #'+rime-convert-string-at-point )
60
58
(:map rime-active-mode-map
61
- (" C-S-s-j" . #'rime-inline-ascii )
62
- (" C-M-S-s-j" . #'rime-inline-ascii ))
59
+ (" C-S-s-j" . #'rime-inline-ascii )
60
+ (" C-M-S-s-j" . #'rime-inline-ascii ))
63
61
(:map rime-mode-map
64
- (" C-M-S-s-j" . #'rime-force-enable )
65
- (" C-." . #'rime-send-keybinding )
66
- (" S-SPC" . #'rime-send-keybinding )
67
- (" C-`" . #'rime-send-keybinding )
68
- (" C-~" . #'rime-send-keybinding )
69
- (" C-S-`" . #'rime-send-keybinding ))
62
+ (" C-M-S-s-j" . #'rime-force-enable )
63
+ (" C-." . #'rime-send-keybinding )
64
+ (" S-SPC" . #'rime-send-keybinding )
65
+ (" C-`" . #'rime-send-keybinding )
66
+ (" C-~" . #'rime-send-keybinding )
67
+ (" C-S-`" . #'rime-send-keybinding ))
70
68
:custom
71
69
(default-input-method " rime" )
72
- ; ; (rime-librime-root (cond (IS-MAC (let ((dir (expand-file-name "~/repos/librime/dist")))
73
- ; ; (when (file-directory-p dir)
74
- ; ; dir)))
75
- ; ; (t rime-librime-root)))
76
70
(rime-share-data-dir
77
71
(cl-some (lambda (dir )
78
72
(let ((abs-dir (expand-file-name dir)))
@@ -147,17 +141,17 @@ input scheme to convert to Chinese."
147
141
148
142
(unless (fboundp 'rime--posframe-display-content )
149
143
(error " Function `rime--posframe-display-content' is not available. " ))
150
- (defadvice! + rime--posframe-display-content-a (args)
144
+ (define-advice rime--posframe-display-content ( :filter-args (args) resolve-posframe-issue-a )
151
145
" 给 `rime--posframe-display-content' 传入的字符串加一个全角空
152
146
格,以解决 `posframe' 偶尔吃字的问题。"
153
- :filter-args #'rime--posframe-display-content
154
147
(cl-destructuring-bind (content) args
155
148
(let ((newresult (if (string-blank-p content)
156
149
content
157
150
(concat content " " ))))
158
151
(list newresult))))
152
+
159
153
(when (featurep! +rime-predicates)
160
- (load! " +rime-predicates" )))
154
+ (load! " +rime-predicates" )))
161
155
162
156
163
157
; ; Support pinyin in Ivy
0 commit comments