wok-current diff emacs-pkg-text-translator/stuff/90-text-translator-init.el @ rev 23004
updated libassuan and libassuan-dev (2.5.1 -> 2.5.3)
author | Hans-G?nter Theisgen |
---|---|
date | Mon Mar 02 17:29:40 2020 +0100 (2020-03-02) |
parents | |
children |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/emacs-pkg-text-translator/stuff/90-text-translator-init.el Mon Mar 02 17:29:40 2020 +0100 1.3 @@ -0,0 +1,30 @@ 1.4 +;; Register 1.5 + 1.6 +(require 'text-translator) 1.7 + 1.8 + 1.9 +;; set global key 1.10 + 1.11 +(global-set-key "\C-x\M-t" 'text-translator) 1.12 +(global-set-key "\C-x\M-T" 'text-translator-translate-last-string) 1.13 +;; translate all sites. 1.14 +;; for example, if you specify "enja", text-translator use google.com_enja, yahoo.com_enja, ... . 1.15 +(global-set-key "\C-x\M-a" 'text-translator-all) 1.16 + 1.17 + 1.18 +;; add keys to major-mode 1.19 + 1.20 +(add-hook 1.21 + 'text-translator-mode-hook 1.22 + (lambda() 1.23 + ;; if you do not change prefix-key, it is executed by C-c M-a 1.24 + (define-key text-translator-mode-pkey-map "\M-a" 'text-translator-translate-recent-type))) 1.25 + 1.26 + 1.27 +;; use proxy 1.28 + 1.29 +;; ;; if you are setting environment variables HTTP_PROXY, 1.30 +;; ;; you have not to set this. 1.31 +;; (setq text-translator-proxy-server "proxy.hogehoge.com") 1.32 +;; (setq text-translator-proxy-port 8080) 1.33 +