diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2005-12-27 14:27:51 +0000 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2005-12-27 14:27:51 +0000 |
commit | efc9f13db9700c95a1145e049db5a787fe693017 (patch) | |
tree | fdcef0f07499f266db82cbc09c53d37bb6e4311d /elisp | |
parent | 518c320c2785b8b8a6f6a4b5f17e52bcaab33428 (diff) | |
download | gsc-efc9f13db9700c95a1145e049db5a787fe693017.tar.gz gsc-efc9f13db9700c95a1145e049db5a787fe693017.tar.bz2 |
(gray-po-subedit-mode-hook): Set
ispell-local-dictionary.
(gray-po-subedit-exit-hook): New hook.
git-svn-id: file:///svnroot/gsc/trunk@176 d2de0444-eb31-0410-8365-af798a554d48
Diffstat (limited to 'elisp')
-rw-r--r-- | elisp/po.el | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/elisp/po.el b/elisp/po.el index 45a3aa7..82131ea 100644 --- a/elisp/po.el +++ b/elisp/po.el @@ -120,8 +120,24 @@ translation strings." (defun gray-po-subedit-mode-hook () "Enable the input method in subedit buffer" - (let ((method (assoc 'default-input-method (buffer-local-variables buffer)))) - (if method + (let ((method (assoc 'default-input-method (buffer-local-variables buffer))) + (local-dictionary (assoc 'ispell-local-dictionary + (buffer-local-variables buffer)))) + (when local-dictionary + (make-variable-buffer-local 'ispell-local-dictionary) + (setq ispell-local-dictionary (cdr local-dictionary))) + + (when method (set-input-method (cdr method))))) +(defun gray-po-subedit-exit-hook () + (let ((po-is-format t) ;; FIXME + (ispell-skip-region-alist '(("%" process-format))) + (ispell-extra-args (append ispell-extra-args + (list (concat + "--encoding=" + (symbol-name + buffer-file-coding-system)))))) + (ispell-buffer))) + ;;;; End of po.el |